diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-30 11:44:35 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-30 11:44:35 -0700 |
commit | 4ac08d36aa9c556556c7b150caee263c6d542645 (patch) | |
tree | 52fb22d3230665237109d5e886609199c0e6f22c /sound/core | |
parent | 0b54968f667585aa4b98a7225f4d4df63917703c (diff) | |
parent | 71c21b4cf62177a9d1ea46ff4c6073c907122226 (diff) | |
download | linux-4ac08d36aa9c556556c7b150caee263c6d542645.tar.gz linux-4ac08d36aa9c556556c7b150caee263c6d542645.tar.bz2 linux-4ac08d36aa9c556556c7b150caee263c6d542645.zip |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
ALSA: ASoC: Fix WM9713 ALC Decay Time name
ALSA: ASoC: Fix some minor errors in mpc5200 psc i2s driver
ALSA: ASoC: Fix mono controls after conversion to support full int masks
ALSA: sound/ice1712: indentation & braces disagree - add braces
ALSA: usb - Add quirk for Edirol UA-25EX advanced modes
sound: struct device - replace bus_id with dev_name(), dev_set_name()
ALSA: hda - Add reboot notifier
ALSA: Warn when control names are truncated
ALSA: intel8x0 - add Dell Optiplex GX620 (AD1981B) to AC97 clock whitelist
ALSA: hda - Fix SPDIF mute on IDT/STAC codecs
ALSA: hda: Add HDA vendor ID for Wolfson Microelectronics
ALSA: hda - Add another HP model for AD1884A
Diffstat (limited to 'sound/core')
-rw-r--r-- | sound/core/control.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sound/core/control.c b/sound/core/control.c index 6d71f9a7ccbb..b0bf42691047 100644 --- a/sound/core/control.c +++ b/sound/core/control.c @@ -225,8 +225,13 @@ struct snd_kcontrol *snd_ctl_new1(const struct snd_kcontrol_new *ncontrol, kctl.id.iface = ncontrol->iface; kctl.id.device = ncontrol->device; kctl.id.subdevice = ncontrol->subdevice; - if (ncontrol->name) + if (ncontrol->name) { strlcpy(kctl.id.name, ncontrol->name, sizeof(kctl.id.name)); + if (strcmp(ncontrol->name, kctl.id.name) != 0) + snd_printk(KERN_WARNING + "Control name '%s' truncated to '%s'\n", + ncontrol->name, kctl.id.name); + } kctl.id.index = ncontrol->index; kctl.count = ncontrol->count ? ncontrol->count : 1; access = ncontrol->access == 0 ? SNDRV_CTL_ELEM_ACCESS_READWRITE : |