From: Greg Kroah-Hartman Date: Thu, 18 Oct 2012 20:09:58 +0000 (-0700) Subject: 3.4-stable patches X-Git-Tag: v3.0.47~4 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=80a891bd5894b678c652c66ba210ce41c04f762c;p=thirdparty%2Fkernel%2Fstable-queue.git 3.4-stable patches added patches: alsa-ac97-fix-missing-null-check-in-snd_ac97_cvol_new.patch alsa-emu10k1-add-chip-details-for-e-mu-1010-pcie-card.patch alsa-hda-always-check-array-bounds-in-alc_get_line_out_pfx.patch asoc-fsi-don-t-reschedule-dma-from-an-atomic-context.patch asoc-omap-abe-twl6040-fix-typo-of-vibrator.patch asoc-wm2200-fix-non-inverted-out2-mute-control.patch asoc-wm2200-use-rev-a-register-patches-on-rev-b.patch --- diff --git a/queue-3.4/alsa-ac97-fix-missing-null-check-in-snd_ac97_cvol_new.patch b/queue-3.4/alsa-ac97-fix-missing-null-check-in-snd_ac97_cvol_new.patch new file mode 100644 index 00000000000..aa62ea713a8 --- /dev/null +++ b/queue-3.4/alsa-ac97-fix-missing-null-check-in-snd_ac97_cvol_new.patch @@ -0,0 +1,29 @@ +From 733a48e5ae5bf28b046fad984d458c747cbb8c21 Mon Sep 17 00:00:00 2001 +From: Takashi Iwai +Date: Thu, 11 Oct 2012 16:43:40 +0200 +Subject: ALSA: ac97 - Fix missing NULL check in snd_ac97_cvol_new() + +From: Takashi Iwai + +commit 733a48e5ae5bf28b046fad984d458c747cbb8c21 upstream. + +Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=44721 + +Signed-off-by: Takashi Iwai +Signed-off-by: Greg Kroah-Hartman + +--- + sound/pci/ac97/ac97_codec.c | 2 ++ + 1 file changed, 2 insertions(+) + +--- a/sound/pci/ac97/ac97_codec.c ++++ b/sound/pci/ac97/ac97_codec.c +@@ -1271,6 +1271,8 @@ static int snd_ac97_cvol_new(struct snd_ + tmp.index = ac97->num; + kctl = snd_ctl_new1(&tmp, ac97); + } ++ if (!kctl) ++ return -ENOMEM; + if (reg >= AC97_PHONE && reg <= AC97_PCM) + set_tlv_db_scale(kctl, db_scale_5bit_12db_max); + else diff --git a/queue-3.4/alsa-emu10k1-add-chip-details-for-e-mu-1010-pcie-card.patch b/queue-3.4/alsa-emu10k1-add-chip-details-for-e-mu-1010-pcie-card.patch new file mode 100644 index 00000000000..20fda683cd8 --- /dev/null +++ b/queue-3.4/alsa-emu10k1-add-chip-details-for-e-mu-1010-pcie-card.patch @@ -0,0 +1,38 @@ +From 10f571d09106c3eb85951896522c9650596eff2e Mon Sep 17 00:00:00 2001 +From: Maxim Kachur +Date: Wed, 17 Oct 2012 18:18:10 +0200 +Subject: ALSA: emu10k1: add chip details for E-mu 1010 PCIe card + +From: Maxim Kachur + +commit 10f571d09106c3eb85951896522c9650596eff2e upstream. + +Add chip details for E-mu 1010 PCIe card. It has the same +chip as found in E-mu 1010b but it uses different PCI id. + +Signed-off-by: Maxim Kachur +Signed-off-by: Takashi Iwai +Signed-off-by: Greg Kroah-Hartman + +--- + sound/pci/emu10k1/emu10k1_main.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +--- a/sound/pci/emu10k1/emu10k1_main.c ++++ b/sound/pci/emu10k1/emu10k1_main.c +@@ -1416,6 +1416,15 @@ static struct snd_emu_chip_details emu_c + .ca0108_chip = 1, + .spk71 = 1, + .emu_model = EMU_MODEL_EMU1010B}, /* EMU 1010 new revision */ ++ /* Tested by Maxim Kachur 17th Oct 2012. */ ++ /* This is MAEM8986, 0202 is MAEM8980 */ ++ {.vendor = 0x1102, .device = 0x0008, .subsystem = 0x40071102, ++ .driver = "Audigy2", .name = "E-mu 1010 PCIe [MAEM8986]", ++ .id = "EMU1010", ++ .emu10k2_chip = 1, ++ .ca0108_chip = 1, ++ .spk71 = 1, ++ .emu_model = EMU_MODEL_EMU1010B}, /* EMU 1010 PCIe */ + /* Tested by James@superbug.co.uk 8th July 2005. */ + /* This is MAEM8810, 0202 is MAEM8820 */ + {.vendor = 0x1102, .device = 0x0004, .subsystem = 0x40011102, diff --git a/queue-3.4/alsa-hda-always-check-array-bounds-in-alc_get_line_out_pfx.patch b/queue-3.4/alsa-hda-always-check-array-bounds-in-alc_get_line_out_pfx.patch new file mode 100644 index 00000000000..a465c7fca9b --- /dev/null +++ b/queue-3.4/alsa-hda-always-check-array-bounds-in-alc_get_line_out_pfx.patch @@ -0,0 +1,35 @@ +From 71aa5ebe36a4e936eff281b375a4707b6a8320f2 Mon Sep 17 00:00:00 2001 +From: David Henningsson +Date: Wed, 17 Oct 2012 12:43:44 +0200 +Subject: ALSA: hda - Always check array bounds in alc_get_line_out_pfx + +From: David Henningsson + +commit 71aa5ebe36a4e936eff281b375a4707b6a8320f2 upstream. + +Even when CONFIG_SND_DEBUG is not enabled, we don't want to +return an arbitrary memory location when the channel count is +larger than we expected. + +Signed-off-by: David Henningsson +Signed-off-by: Takashi Iwai +Signed-off-by: Greg Kroah-Hartman + +--- + sound/pci/hda/patch_realtek.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +--- a/sound/pci/hda/patch_realtek.c ++++ b/sound/pci/hda/patch_realtek.c +@@ -2665,8 +2665,10 @@ static const char *alc_get_line_out_pfx( + return "PCM"; + break; + } +- if (snd_BUG_ON(ch >= ARRAY_SIZE(channel_name))) ++ if (ch >= ARRAY_SIZE(channel_name)) { ++ snd_BUG(); + return "PCM"; ++ } + + return channel_name[ch]; + } diff --git a/queue-3.4/asoc-fsi-don-t-reschedule-dma-from-an-atomic-context.patch b/queue-3.4/asoc-fsi-don-t-reschedule-dma-from-an-atomic-context.patch new file mode 100644 index 00000000000..40aa41507de --- /dev/null +++ b/queue-3.4/asoc-fsi-don-t-reschedule-dma-from-an-atomic-context.patch @@ -0,0 +1,89 @@ +From 57451e437796548d658d03c2c4aab659eafcd799 Mon Sep 17 00:00:00 2001 +From: Guennadi Liakhovetski +Date: Wed, 3 Oct 2012 14:33:50 +0200 +Subject: ASoC: fsi: don't reschedule DMA from an atomic context + +From: Guennadi Liakhovetski + +commit 57451e437796548d658d03c2c4aab659eafcd799 upstream. + +shdma doesn't support transfer re-scheduling or triggering from callbacks +or from atomic context. The fsi driver issues DMA transfers from a tasklet +context, which is a bug. To fix it convert tasklet to a work. + +Reported-by: Do Q.Thang +Tested-by: Do Q.Thang +Signed-off-by: Guennadi Liakhovetski +Signed-off-by: Mark Brown +Signed-off-by: Greg Kroah-Hartman + +--- + sound/soc/sh/fsi.c | 15 ++++++++------- + 1 file changed, 8 insertions(+), 7 deletions(-) + +--- a/sound/soc/sh/fsi.c ++++ b/sound/soc/sh/fsi.c +@@ -20,6 +20,7 @@ + #include + #include + #include ++#include + #include + #include + +@@ -199,7 +200,7 @@ struct fsi_stream { + */ + struct dma_chan *chan; + struct sh_dmae_slave slave; /* see fsi_handler_init() */ +- struct tasklet_struct tasklet; ++ struct work_struct work; + dma_addr_t dma; + }; + +@@ -968,9 +969,9 @@ static dma_addr_t fsi_dma_get_area(struc + return io->dma + samples_to_bytes(runtime, io->buff_sample_pos); + } + +-static void fsi_dma_do_tasklet(unsigned long data) ++static void fsi_dma_do_work(struct work_struct *work) + { +- struct fsi_stream *io = (struct fsi_stream *)data; ++ struct fsi_stream *io = container_of(work, struct fsi_stream, work); + struct fsi_priv *fsi = fsi_stream_to_priv(io); + struct dma_chan *chan; + struct snd_soc_dai *dai; +@@ -1023,7 +1024,7 @@ static void fsi_dma_do_tasklet(unsigned + * FIXME + * + * In DMAEngine case, codec and FSI cannot be started simultaneously +- * since FSI is using tasklet. ++ * since FSI is using the scheduler work queue. + * Therefore, in capture case, probably FSI FIFO will have got + * overflow error in this point. + * in that case, DMA cannot start transfer until error was cleared. +@@ -1047,7 +1048,7 @@ static bool fsi_dma_filter(struct dma_ch + + static int fsi_dma_transfer(struct fsi_priv *fsi, struct fsi_stream *io) + { +- tasklet_schedule(&io->tasklet); ++ schedule_work(&io->work); + + return 0; + } +@@ -1087,14 +1088,14 @@ static int fsi_dma_probe(struct fsi_priv + if (!io->chan) + return -EIO; + +- tasklet_init(&io->tasklet, fsi_dma_do_tasklet, (unsigned long)io); ++ INIT_WORK(&io->work, fsi_dma_do_work); + + return 0; + } + + static int fsi_dma_remove(struct fsi_priv *fsi, struct fsi_stream *io) + { +- tasklet_kill(&io->tasklet); ++ cancel_work_sync(&io->work); + + fsi_stream_stop(fsi, io); + diff --git a/queue-3.4/asoc-omap-abe-twl6040-fix-typo-of-vibrator.patch b/queue-3.4/asoc-omap-abe-twl6040-fix-typo-of-vibrator.patch new file mode 100644 index 00000000000..50bb9ee37b2 --- /dev/null +++ b/queue-3.4/asoc-omap-abe-twl6040-fix-typo-of-vibrator.patch @@ -0,0 +1,30 @@ +From 034940a6b3afbe79022ab6922dd9d2982b78e6d5 Mon Sep 17 00:00:00 2001 +From: Peter Ujfalusi +Date: Tue, 2 Oct 2012 15:31:16 +0300 +Subject: ASoC: omap-abe-twl6040: Fix typo of Vibrator + +From: Peter Ujfalusi + +commit 034940a6b3afbe79022ab6922dd9d2982b78e6d5 upstream. + +It is not Vinrator but Vibrator. + +Signed-off-by: Peter Ujfalusi +Signed-off-by: Mark Brown +Signed-off-by: Greg Kroah-Hartman + +--- + sound/soc/omap/omap-abe-twl6040.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/sound/soc/omap/omap-abe-twl6040.c ++++ b/sound/soc/omap/omap-abe-twl6040.c +@@ -181,7 +181,7 @@ static int omap_abe_twl6040_init(struct + twl6040_disconnect_pin(dapm, pdata->has_hf, "Ext Spk"); + twl6040_disconnect_pin(dapm, pdata->has_ep, "Earphone Spk"); + twl6040_disconnect_pin(dapm, pdata->has_aux, "Line Out"); +- twl6040_disconnect_pin(dapm, pdata->has_vibra, "Vinrator"); ++ twl6040_disconnect_pin(dapm, pdata->has_vibra, "Vibrator"); + twl6040_disconnect_pin(dapm, pdata->has_hsmic, "Headset Mic"); + twl6040_disconnect_pin(dapm, pdata->has_mainmic, "Main Handset Mic"); + twl6040_disconnect_pin(dapm, pdata->has_submic, "Sub Handset Mic"); diff --git a/queue-3.4/asoc-wm2200-fix-non-inverted-out2-mute-control.patch b/queue-3.4/asoc-wm2200-fix-non-inverted-out2-mute-control.patch new file mode 100644 index 00000000000..fa1c74d0aca --- /dev/null +++ b/queue-3.4/asoc-wm2200-fix-non-inverted-out2-mute-control.patch @@ -0,0 +1,27 @@ +From a1b98e12b7f8fad2f0aa3c08a3302bcac7ae1ec7 Mon Sep 17 00:00:00 2001 +From: Mark Brown +Date: Tue, 2 Oct 2012 19:10:43 +0100 +Subject: ASoC: wm2200: Fix non-inverted OUT2 mute control + +From: Mark Brown + +commit a1b98e12b7f8fad2f0aa3c08a3302bcac7ae1ec7 upstream. + +Signed-off-by: Mark Brown +Signed-off-by: Greg Kroah-Hartman + +--- + sound/soc/codecs/wm2200.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/sound/soc/codecs/wm2200.c ++++ b/sound/soc/codecs/wm2200.c +@@ -1028,7 +1028,7 @@ SOC_DOUBLE_R_TLV("OUT2 Digital Volume", + WM2200_DAC_DIGITAL_VOLUME_2R, WM2200_OUT2L_VOL_SHIFT, 0x9f, 0, + digital_tlv), + SOC_DOUBLE("OUT2 Switch", WM2200_PDM_1, WM2200_SPK1L_MUTE_SHIFT, +- WM2200_SPK1R_MUTE_SHIFT, 1, 0), ++ WM2200_SPK1R_MUTE_SHIFT, 1, 1), + }; + + WM2200_MIXER_ENUMS(OUT1L, WM2200_OUT1LMIX_INPUT_1_SOURCE); diff --git a/queue-3.4/asoc-wm2200-use-rev-a-register-patches-on-rev-b.patch b/queue-3.4/asoc-wm2200-use-rev-a-register-patches-on-rev-b.patch new file mode 100644 index 00000000000..7816ad672c2 --- /dev/null +++ b/queue-3.4/asoc-wm2200-use-rev-a-register-patches-on-rev-b.patch @@ -0,0 +1,26 @@ +From 5ae9eb4cbdfd640269dbd66aa3c92ea8e11cc838 Mon Sep 17 00:00:00 2001 +From: Mark Brown +Date: Tue, 2 Oct 2012 12:02:48 +0100 +Subject: ASoC: wm2200: Use rev A register patches on rev B + +From: Mark Brown + +commit 5ae9eb4cbdfd640269dbd66aa3c92ea8e11cc838 upstream. + +Signed-off-by: Mark Brown +Signed-off-by: Greg Kroah-Hartman + +--- + sound/soc/codecs/wm2200.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/sound/soc/codecs/wm2200.c ++++ b/sound/soc/codecs/wm2200.c +@@ -2091,6 +2091,7 @@ static __devinit int wm2200_i2c_probe(st + + switch (wm2200->rev) { + case 0: ++ case 1: + ret = regmap_register_patch(wm2200->regmap, wm2200_reva_patch, + ARRAY_SIZE(wm2200_reva_patch)); + if (ret != 0) { diff --git a/queue-3.4/series b/queue-3.4/series index 1a6fa04be15..4b15f125232 100644 --- a/queue-3.4/series +++ b/queue-3.4/series @@ -53,3 +53,10 @@ ecryptfs-revert-to-a-writethrough-cache-model.patch ecryptfs-write-out-all-dirty-pages-just-before-releasing-the-lower-file.patch ecryptfs-call-lower-flush-from-ecryptfs_flush.patch usb-gadget-at91_udc-fix-dt-support.patch +alsa-hda-always-check-array-bounds-in-alc_get_line_out_pfx.patch +asoc-fsi-don-t-reschedule-dma-from-an-atomic-context.patch +asoc-wm2200-use-rev-a-register-patches-on-rev-b.patch +asoc-wm2200-fix-non-inverted-out2-mute-control.patch +asoc-omap-abe-twl6040-fix-typo-of-vibrator.patch +alsa-ac97-fix-missing-null-check-in-snd_ac97_cvol_new.patch +alsa-emu10k1-add-chip-details-for-e-mu-1010-pcie-card.patch