diff options
Diffstat (limited to 'sound/pci/hda/patch_analog.c')
-rw-r--r-- | sound/pci/hda/patch_analog.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/sound/pci/hda/patch_analog.c b/sound/pci/hda/patch_analog.c index 0cbdd87dde6d..2aa2f579b4d6 100644 --- a/sound/pci/hda/patch_analog.c +++ b/sound/pci/hda/patch_analog.c | |||
@@ -968,6 +968,15 @@ static void ad1884_fixup_hp_eapd(struct hda_codec *codec, | |||
968 | } | 968 | } |
969 | } | 969 | } |
970 | 970 | ||
971 | static void ad1884_fixup_thinkpad(struct hda_codec *codec, | ||
972 | const struct hda_fixup *fix, int action) | ||
973 | { | ||
974 | struct ad198x_spec *spec = codec->spec; | ||
975 | |||
976 | if (action == HDA_FIXUP_ACT_PRE_PROBE) | ||
977 | spec->gen.keep_eapd_on = 1; | ||
978 | } | ||
979 | |||
971 | /* set magic COEFs for dmic */ | 980 | /* set magic COEFs for dmic */ |
972 | static const struct hda_verb ad1884_dmic_init_verbs[] = { | 981 | static const struct hda_verb ad1884_dmic_init_verbs[] = { |
973 | {0x01, AC_VERB_SET_COEF_INDEX, 0x13f7}, | 982 | {0x01, AC_VERB_SET_COEF_INDEX, 0x13f7}, |
@@ -979,6 +988,7 @@ enum { | |||
979 | AD1884_FIXUP_AMP_OVERRIDE, | 988 | AD1884_FIXUP_AMP_OVERRIDE, |
980 | AD1884_FIXUP_HP_EAPD, | 989 | AD1884_FIXUP_HP_EAPD, |
981 | AD1884_FIXUP_DMIC_COEF, | 990 | AD1884_FIXUP_DMIC_COEF, |
991 | AD1884_FIXUP_THINKPAD, | ||
982 | AD1884_FIXUP_HP_TOUCHSMART, | 992 | AD1884_FIXUP_HP_TOUCHSMART, |
983 | }; | 993 | }; |
984 | 994 | ||
@@ -997,6 +1007,12 @@ static const struct hda_fixup ad1884_fixups[] = { | |||
997 | .type = HDA_FIXUP_VERBS, | 1007 | .type = HDA_FIXUP_VERBS, |
998 | .v.verbs = ad1884_dmic_init_verbs, | 1008 | .v.verbs = ad1884_dmic_init_verbs, |
999 | }, | 1009 | }, |
1010 | [AD1884_FIXUP_THINKPAD] = { | ||
1011 | .type = HDA_FIXUP_FUNC, | ||
1012 | .v.func = ad1884_fixup_thinkpad, | ||
1013 | .chained = true, | ||
1014 | .chain_id = AD1884_FIXUP_DMIC_COEF, | ||
1015 | }, | ||
1000 | [AD1884_FIXUP_HP_TOUCHSMART] = { | 1016 | [AD1884_FIXUP_HP_TOUCHSMART] = { |
1001 | .type = HDA_FIXUP_VERBS, | 1017 | .type = HDA_FIXUP_VERBS, |
1002 | .v.verbs = ad1884_dmic_init_verbs, | 1018 | .v.verbs = ad1884_dmic_init_verbs, |
@@ -1008,7 +1024,7 @@ static const struct hda_fixup ad1884_fixups[] = { | |||
1008 | static const struct snd_pci_quirk ad1884_fixup_tbl[] = { | 1024 | static const struct snd_pci_quirk ad1884_fixup_tbl[] = { |
1009 | SND_PCI_QUIRK(0x103c, 0x2a82, "HP Touchsmart", AD1884_FIXUP_HP_TOUCHSMART), | 1025 | SND_PCI_QUIRK(0x103c, 0x2a82, "HP Touchsmart", AD1884_FIXUP_HP_TOUCHSMART), |
1010 | SND_PCI_QUIRK_VENDOR(0x103c, "HP", AD1884_FIXUP_HP_EAPD), | 1026 | SND_PCI_QUIRK_VENDOR(0x103c, "HP", AD1884_FIXUP_HP_EAPD), |
1011 | SND_PCI_QUIRK_VENDOR(0x17aa, "Lenovo Thinkpad", AD1884_FIXUP_DMIC_COEF), | 1027 | SND_PCI_QUIRK_VENDOR(0x17aa, "Lenovo Thinkpad", AD1884_FIXUP_THINKPAD), |
1012 | {} | 1028 | {} |
1013 | }; | 1029 | }; |
1014 | 1030 | ||