ALSA: hda/realtek - Add auto-mute quirk for HP Spectre x360 laptop
authorGirija Kumar Kasinadhuni <gkumar@neverware.com>
Mon, 26 Nov 2018 18:40:46 +0000 (13:40 -0500)
committerTakashi Iwai <tiwai@suse.de>
Tue, 27 Nov 2018 11:18:23 +0000 (12:18 +0100)
This device makes a loud buzzing sound when a headphone is inserted while
playing audio at full volume through the speaker.

Fixes: bbf8ff6b1d2a ("ALSA: hda/realtek - Fixup for HP x360 laptops with B&O speakers")
Signed-off-by: Girija Kumar Kasinadhuni <gkumar@neverware.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/hda/patch_realtek.c

index e66da22272fdfe76375296024f16db3a38850a1b..7d16dbb18e416f5e2b693149684caa736840b91a 100644 (file)
@@ -5506,6 +5506,7 @@ enum {
        ALC295_FIXUP_HP_X360,
        ALC221_FIXUP_HP_HEADSET_MIC,
        ALC285_FIXUP_LENOVO_HEADPHONE_NOISE,
+       ALC295_FIXUP_HP_AUTO_MUTE,
 };
 
 static const struct hda_fixup alc269_fixups[] = {
@@ -5670,6 +5671,8 @@ static const struct hda_fixup alc269_fixups[] = {
        [ALC269_FIXUP_HP_MUTE_LED_MIC3] = {
                .type = HDA_FIXUP_FUNC,
                .v.func = alc269_fixup_hp_mute_led_mic3,
+               .chained = true,
+               .chain_id = ALC295_FIXUP_HP_AUTO_MUTE
        },
        [ALC269_FIXUP_HP_GPIO_LED] = {
                .type = HDA_FIXUP_FUNC,
@@ -6377,6 +6380,10 @@ static const struct hda_fixup alc269_fixups[] = {
                .type = HDA_FIXUP_FUNC,
                .v.func = alc285_fixup_invalidate_dacs,
        },
+       [ALC295_FIXUP_HP_AUTO_MUTE] = {
+               .type = HDA_FIXUP_FUNC,
+               .v.func = alc_fixup_auto_mute_via_amp,
+       },
 };
 
 static const struct snd_pci_quirk alc269_fixup_tbl[] = {