From dbbcbc073ad3132bfbc410b11546b2fb4bdf2568 Mon Sep 17 00:00:00 2001 From: David Henningsson Date: Mon, 23 Aug 2010 08:14:35 +0200 Subject: ALSA: hda - Add Sony VAIO quirk for ALC269 The attached patch enables playback on a Sony VAIO machine. BugLink: http://launchpad.net/bugs/618271 Signed-off-by: David Henningsson Cc: Signed-off-by: Takashi Iwai --- sound/pci/hda/patch_realtek.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index a4dd04524e4..627bf996336 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -14467,6 +14467,7 @@ static const struct alc_fixup alc269_fixups[] = { static struct snd_pci_quirk alc269_fixup_tbl[] = { SND_PCI_QUIRK(0x104d, 0x9071, "Sony VAIO", ALC269_FIXUP_SONY_VAIO), + SND_PCI_QUIRK(0x104d, 0x9077, "Sony VAIO", ALC269_FIXUP_SONY_VAIO), {} }; -- cgit v1.2.3 From 708fafb3c54039caa5dadc8e9d2dfd999f88f190 Mon Sep 17 00:00:00 2001 From: Axel Lin Date: Fri, 27 Aug 2010 10:34:27 +0800 Subject: ASoC: soc-core: fix debugfs_pop_time file permissions I think this is a typo, debugfs_pop_time should not be executable. Signed-off-by: Axel Lin Acked-by: Liam Girdwood Signed-off-by: Mark Brown --- sound/soc/soc-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 844ae8221a3..acc91daa1c5 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -251,7 +251,7 @@ static void soc_init_codec_debugfs(struct snd_soc_codec *codec) printk(KERN_WARNING "ASoC: Failed to create codec register debugfs file\n"); - codec->debugfs_pop_time = debugfs_create_u32("dapm_pop_time", 0744, + codec->debugfs_pop_time = debugfs_create_u32("dapm_pop_time", 0644, codec->debugfs_codec_root, &codec->pop_time); if (!codec->debugfs_pop_time) -- cgit v1.2.3 From 60f1deb595c08687a96157a6a3ce08ef34142362 Mon Sep 17 00:00:00 2001 From: Eliot Blennerhassett Date: Sat, 28 Aug 2010 19:52:24 +1200 Subject: ALSA: asihpi - Return hw error directly from oustream_write. If hw error is ignored, status is updated with invalid info. Signed-off-by: Eliot Blennerhassett Signed-off-by: Takashi Iwai --- sound/pci/asihpi/hpi6205.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sound/pci/asihpi/hpi6205.c b/sound/pci/asihpi/hpi6205.c index 3b441344822..22c5fc62553 100644 --- a/sound/pci/asihpi/hpi6205.c +++ b/sound/pci/asihpi/hpi6205.c @@ -941,8 +941,7 @@ static void outstream_host_buffer_free(struct hpi_adapter_obj *pao, } -static u32 outstream_get_space_available(struct hpi_hostbuffer_status - *status) +static u32 outstream_get_space_available(struct hpi_hostbuffer_status *status) { return status->size_in_bytes - (status->host_index - status->dSP_index); @@ -987,6 +986,10 @@ static void outstream_write(struct hpi_adapter_obj *pao, /* write it */ phm->function = HPI_OSTREAM_WRITE; hw_message(pao, phm, phr); + + if (phr->error) + return; + /* update status information that the DSP would typically * update (and will update next time the DSP * buffer update task reads data from the host BBM buffer) -- cgit v1.2.3 From 3182c8a72b31414e043184a97b0d5d3c0d590168 Mon Sep 17 00:00:00 2001 From: Akinobu Mita Date: Sat, 28 Aug 2010 13:25:33 +0900 Subject: sound: oss: fix uninitialized spinlock The spinlock lock in sound_timer.c is used without initialization. Signed-off-by: Akinobu Mita Signed-off-by: Takashi Iwai --- sound/oss/sound_timer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/oss/sound_timer.c b/sound/oss/sound_timer.c index f0f0c19fbff..48cda6c4c25 100644 --- a/sound/oss/sound_timer.c +++ b/sound/oss/sound_timer.c @@ -26,7 +26,7 @@ static unsigned long prev_event_time; static volatile unsigned long usecs_per_tmr; /* Length of the current interval */ static struct sound_lowlev_timer *tmr; -static spinlock_t lock; +static DEFINE_SPINLOCK(lock); static unsigned long tmr2ticks(int tmr_value) { -- cgit v1.2.3 From 7a28826ac73d31a379d93785d8fbd24ab492b0bd Mon Sep 17 00:00:00 2001 From: Dan Carpenter Date: Fri, 27 Aug 2010 22:02:15 +0200 Subject: ALSA: pcm: add more format names There were some new formats added in commit 15c0cee6c809 "ALSA: pcm: Define G723 3-bit and 5-bit formats". That commit increased SNDRV_PCM_FORMAT_LAST as well. My concern is that there are a couple places which do: for (i = 0; i < SNDRV_PCM_FORMAT_LAST; i++) { if (dummy->pcm_hw.formats & (1ULL << i)) snd_iprintf(buffer, " %s", snd_pcm_format_name(i)); } I haven't tested these but it looks like if "i" were equal to SNDRV_PCM_FORMAT_G723_24 or higher then we might read past the end of the array. Signed-off-by: Dan Carpenter Signed-off-by: Takashi Iwai --- sound/core/pcm.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sound/core/pcm.c b/sound/core/pcm.c index cbe815dfbdc..204af48c5cc 100644 --- a/sound/core/pcm.c +++ b/sound/core/pcm.c @@ -203,10 +203,16 @@ static char *snd_pcm_format_names[] = { FORMAT(S18_3BE), FORMAT(U18_3LE), FORMAT(U18_3BE), + FORMAT(G723_24), + FORMAT(G723_24_1B), + FORMAT(G723_40), + FORMAT(G723_40_1B), }; const char *snd_pcm_format_name(snd_pcm_format_t format) { + if (format >= ARRAY_SIZE(snd_pcm_format_names)) + return "Unknown"; return snd_pcm_format_names[format]; } EXPORT_SYMBOL_GPL(snd_pcm_format_name); -- cgit v1.2.3