[alsa-devel] [PATCH] ALSA: hda - Cirrus: Correctly clear line_out_pins when moving to speaker
If this array is not cleared, the jack related code later might fail to create "Internal Speaker Phantom Jack" on Dell Inspiron 3420 and Dell Vostro 2420.
BugLink: https://bugs.launchpad.net/bugs/1076840 Cc: stable@vger.kernel.org (3.6+) Signed-off-by: David Henningsson david.henningsson@canonical.com --- sound/pci/hda/patch_cirrus.c | 1 + 1 file changed, 1 insertion(+)
Notes: 1) AlsaInfo at https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1076840/+attachment/342... 2) The phantom jack feature was added in Linux 3.6, but was backported to Ubuntu's 3.5 kernel, so should be applied there as well.
diff --git a/sound/pci/hda/patch_cirrus.c b/sound/pci/hda/patch_cirrus.c index f99cbf9..ed98172 100644 --- a/sound/pci/hda/patch_cirrus.c +++ b/sound/pci/hda/patch_cirrus.c @@ -473,6 +473,7 @@ static int parse_output(struct hda_codec *codec) memcpy(cfg->speaker_pins, cfg->line_out_pins, sizeof(cfg->speaker_pins)); cfg->line_outs = 0; + memset(cfg->line_out_pins, 0, sizeof(cfg->line_out_pins)); }
return 0;
At Wed, 21 Nov 2012 10:03:10 +0100, David Henningsson wrote:
If this array is not cleared, the jack related code later might fail to create "Internal Speaker Phantom Jack" on Dell Inspiron 3420 and Dell Vostro 2420.
BugLink: https://bugs.launchpad.net/bugs/1076840 Cc: stable@vger.kernel.org (3.6+) Signed-off-by: David Henningsson david.henningsson@canonical.com
Thanks, applied.
Takashi
sound/pci/hda/patch_cirrus.c | 1 + 1 file changed, 1 insertion(+)
Notes:
- AlsaInfo at https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1076840/+attachment/342...
- The phantom jack feature was added in Linux 3.6, but was backported to Ubuntu's 3.5 kernel, so should be applied there as well.
diff --git a/sound/pci/hda/patch_cirrus.c b/sound/pci/hda/patch_cirrus.c index f99cbf9..ed98172 100644 --- a/sound/pci/hda/patch_cirrus.c +++ b/sound/pci/hda/patch_cirrus.c @@ -473,6 +473,7 @@ static int parse_output(struct hda_codec *codec) memcpy(cfg->speaker_pins, cfg->line_out_pins, sizeof(cfg->speaker_pins)); cfg->line_outs = 0;
memset(cfg->line_out_pins, 0, sizeof(cfg->line_out_pins));
}
return 0;
-- 1.7.9.5
participants (2)
-
David Henningsson
-
Takashi Iwai