From dd930188fb0f0f35ca88ec8933cdb32203c522e6 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Thu, 18 Oct 2012 13:10:25 -0700 Subject: [PATCH] 3.6-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 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 --- ...sing-null-check-in-snd_ac97_cvol_new.patch | 29 ++++++ ...chip-details-for-e-mu-1010-pcie-card.patch | 38 ++++++++ ...eschedule-dma-from-an-atomic-context.patch | 89 +++++++++++++++++++ ...map-abe-twl6040-fix-typo-of-vibrator.patch | 30 +++++++ ...0-fix-non-inverted-out2-mute-control.patch | 27 ++++++ ...-use-rev-a-register-patches-on-rev-b.patch | 26 ++++++ queue-3.6/series | 6 ++ 7 files changed, 245 insertions(+) create mode 100644 queue-3.6/alsa-ac97-fix-missing-null-check-in-snd_ac97_cvol_new.patch create mode 100644 queue-3.6/alsa-emu10k1-add-chip-details-for-e-mu-1010-pcie-card.patch create mode 100644 queue-3.6/asoc-fsi-don-t-reschedule-dma-from-an-atomic-context.patch create mode 100644 queue-3.6/asoc-omap-abe-twl6040-fix-typo-of-vibrator.patch create mode 100644 queue-3.6/asoc-wm2200-fix-non-inverted-out2-mute-control.patch create mode 100644 queue-3.6/asoc-wm2200-use-rev-a-register-patches-on-rev-b.patch diff --git a/queue-3.6/alsa-ac97-fix-missing-null-check-in-snd_ac97_cvol_new.patch b/queue-3.6/alsa-ac97-fix-missing-null-check-in-snd_ac97_cvol_new.patch new file mode 100644 index 00000000000..aa62ea713a8 --- /dev/null +++ b/queue-3.6/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.6/alsa-emu10k1-add-chip-details-for-e-mu-1010-pcie-card.patch b/queue-3.6/alsa-emu10k1-add-chip-details-for-e-mu-1010-pcie-card.patch new file mode 100644 index 00000000000..20fda683cd8 --- /dev/null +++ b/queue-3.6/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.6/asoc-fsi-don-t-reschedule-dma-from-an-atomic-context.patch b/queue-3.6/asoc-fsi-don-t-reschedule-dma-from-an-atomic-context.patch new file mode 100644 index 00000000000..d5d4a908224 --- /dev/null +++ b/queue-3.6/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 + +@@ -223,7 +224,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; + }; + +@@ -1085,9 +1086,9 @@ static void fsi_dma_complete(void *data) + snd_pcm_period_elapsed(io->substream); + } + +-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 snd_soc_dai *dai; + struct dma_async_tx_descriptor *desc; +@@ -1129,7 +1130,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. +@@ -1153,7 +1154,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; + } +@@ -1195,14 +1196,14 @@ static int fsi_dma_probe(struct fsi_priv + return fsi_stream_probe(fsi, dev); + } + +- 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.6/asoc-omap-abe-twl6040-fix-typo-of-vibrator.patch b/queue-3.6/asoc-omap-abe-twl6040-fix-typo-of-vibrator.patch new file mode 100644 index 00000000000..e394926c567 --- /dev/null +++ b/queue-3.6/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 +@@ -190,7 +190,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.6/asoc-wm2200-fix-non-inverted-out2-mute-control.patch b/queue-3.6/asoc-wm2200-fix-non-inverted-out2-mute-control.patch new file mode 100644 index 00000000000..fa1c74d0aca --- /dev/null +++ b/queue-3.6/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.6/asoc-wm2200-use-rev-a-register-patches-on-rev-b.patch b/queue-3.6/asoc-wm2200-use-rev-a-register-patches-on-rev-b.patch new file mode 100644 index 00000000000..7816ad672c2 --- /dev/null +++ b/queue-3.6/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.6/series b/queue-3.6/series index ee6ea2f3092..79132c081af 100644 --- a/queue-3.6/series +++ b/queue-3.6/series @@ -68,3 +68,9 @@ usb-gadget-at91_udc-fix-dt-support.patch alsa-hda-fix-registration-race-of-vga-switcheroo.patch alsa-hda-stop-lpib-delay-counting-on-broken-hardware.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 -- 2.47.3