sound fixes
Subsystems (3)
Linus,
please pull sound fixes for v2.6.36-rc6 from:
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6.git for-linus
All small and local fixes as below.
Thanks!
Takashi
===
Dan Rosenberg (1):
ALSA: sound/pci/rme9652: prevent reading uninitialized stack memory
Dimitris Papastamos (1):
ASoC: Fix soc-cache buffer overflow bug
Erik J. Staab (1):
ALSA: oxygen: fix analog capture on Claro halo cards
Guennadi Liakhovetski (1):
ASoC: fix clkdev API usage in sh/migor.c
Luke Yelavich (1):
ALSA: hda - Add Dell Latitude E6400 model quirk
Mark Brown (1):
ASoC: Fix multi-componentism
Takashi Iwai (1):
ALSA: hda - Fix auto-parse of SPDIF input of Realtek codecs
--- sound/pci/hda/patch_analog.c | 1 + sound/pci/hda/patch_realtek.c | 22 ++++++++++++++++------ sound/pci/oxygen/oxygen.c | 4 ++++ sound/pci/rme9652/hdsp.c | 1 + sound/pci/rme9652/hdspm.c | 1 + sound/soc/sh/migor.c | 15 +++++++++++++-- sound/soc/soc-cache.c | 5 +++-- 7 files changed, 39 insertions(+), 10 deletions(-)
sound/pci/hda/patch_analog.c +1 -0
@@ -3641,6 +3641,7 @@ static struct snd_pci_quirk ad1984_cfg_tbl[] = {/* Lenovo Thinkpad T61/X61 */ SND_PCI_QUIRK_VENDOR (0x17aa ,"Lenovo Thinkpad" ,AD1984_THINKPAD ),SND_PCI_QUIRK (0x1028 ,0x0214 ,"Dell T3400" ,AD1984_DELL_DESKTOP ), + SND_PCI_QUIRK(0x1028, 0x0233, "Dell Latitude E6400", AD1984_DELL_DESKTOP), {} };
sound/pci/hda/patch_realtek.c +16 -6
@@ -1594,12 +1594,22 @@ static void alc_auto_parse_digital(struct hda_codec *codec) }if (spec->autocfg.dig_in_pin) { -hda_nid_t dig_nid; - err =snd_hda_get_connections (codec, - spec->autocfg.dig_in_pin, - &dig_nid,1 ); -if (err >0 ) - spec->dig_in_nid = dig_nid; + dig_nid = codec->start_nid; +for (i =0 ; i < codec->num_nodes; i++, dig_nid++) { +unsigned int wcaps =get_wcaps (codec, dig_nid); +if (get_wcaps_type (wcaps) !=AC_WID_AUD_IN ) +continue ; +if (!(wcaps &AC_WCAP_DIGITAL )) +continue ; +if (!(wcaps &AC_WCAP_CONN_LIST )) +continue ; + err =get_connection_index (codec, dig_nid, + spec->autocfg.dig_in_pin); +if (err >=0 ) { + spec->dig_in_nid = dig_nid; +break ; + } + } } }
sound/pci/oxygen/oxygen.c +4 -0
@@ -543,6 +543,10 @@ static int __devinit get_oxygen_model(struct oxygen *chip, chip->model.suspend = claro_suspend; chip->model.resume = claro_resume; chip->model.set_adc_params = set_ak5385_params; + chip->model.device_config =PLAYBACK_0_TO_I2S | +PLAYBACK_1_TO_SPDIF | +CAPTURE_0_FROM_I2S_2 | +CAPTURE_1_FROM_SPDIF ;break ; } if (id->driver_data == MODEL_MERIDIAN ||
sound/pci/rme9652/hdsp.c +1 -0
@@ -4609,6 +4609,7 @@ static int snd_hdsp_hwdep_ioctl(struct snd_hwdep *hw, struct file *file, unsigneif (err <0 )return err; +memset (&info,0 ,sizeof (info));spin_lock_irqsave (&hdsp->lock, flags); info.pref_sync_ref = (unsigned char )hdsp_pref_sync_ref (hdsp); info.wordclock_sync_check = (unsigned char )hdsp_wc_sync_check (hdsp);
sound/pci/rme9652/hdspm.c +1 -0
@@ -4127,6 +4127,7 @@ static int snd_hdspm_hwdep_ioctl(struct snd_hwdep * hw, struct file *file,case SNDRV_HDSPM_IOCTL_GET_CONFIG_INFO : +memset (&info,0 ,sizeof (info));spin_lock_irq (&hdspm->lock); info.pref_sync_ref =hdspm_pref_sync_ref (hdspm); info.wordclock_sync_check =hdspm_wc_sync_check (hdspm);
sound/soc/sh/migor.c +13 -2
@@ -12,6 +12,7 @@#include <linux/firmware.h> #include <linux/module.h> +#include <asm/clkdev.h> #include <asm/clock.h> #include <cpu/sh7722.h>
@@ -40,12 +41,12 @@ static struct clk_ops siumckb_clk_ops = { };static struct clk siumckb_clk = { - .name ="siumckb_clk" , - .id =-1 , .ops = &siumckb_clk_ops, .rate =0 ,/* initialised at run-time */ }; +static struct clk_lookup *siumckb_lookup; +static int migor_hw_params (struct snd_pcm_substream *substream,struct snd_pcm_hw_params *params) {
@@ -180,6 +181,13 @@ static int __init migor_init(void)if (ret <0 )return ret; + siumckb_lookup =clkdev_alloc (&siumckb_clk,"siumckb_clk" ,NULL ); +if (!siumckb_lookup) { + ret = -ENOMEM ; + goto eclkdevalloc; + } +clkdev_add (siumckb_lookup); +/* Port number used on this machine: port B */ migor_snd_device =platform_device_alloc ("soc-audio" ,1 );if (!migor_snd_device) {
@@ -200,12 +208,15 @@ static int __init migor_init(void) epdevadd:platform_device_put (migor_snd_device); epdevalloc: +clkdev_drop (siumckb_lookup); +eclkdevalloc:clk_unregister (&siumckb_clk);return ret; } static void __exit migor_exit(void) { +clkdev_drop (siumckb_lookup);clk_unregister (&siumckb_clk);platform_device_unregister (migor_snd_device); }
sound/soc/soc-cache.c +3 -2
@@ -203,8 +203,9 @@ static int snd_soc_8_16_write(struct snd_soc_codec *codec, unsigned int reg, data[1 ] = (value >>8 ) &0xff ; data[2 ] = value &0xff ; -if (!snd_soc_codec_volatile_register (codec, reg)) - reg_cache[reg] = value; +if (!snd_soc_codec_volatile_register (codec, reg) + && reg < codec->reg_cache_size) + reg_cache[reg] = value;if (codec->cache_only) { codec->cache_sync =1 ;