| From 8cf55c09a70824af860b3fd6e384425f07a2247e Mon Sep 17 00:00:00 2001 |
| From: Sasha Levin <sashal@kernel.org> |
| Date: Fri, 18 Oct 2024 13:53:24 +0800 |
| Subject: ALSA: hda/realtek: Limit internal Mic boost on Dell platform |
| |
| From: Kailang Yang <kailang@realtek.com> |
| |
| [ Upstream commit 78e7be018784934081afec77f96d49a2483f9188 ] |
| |
| Dell want to limit internal Mic boost on all Dell platform. |
| |
| Signed-off-by: Kailang Yang <kailang@realtek.com> |
| Cc: <stable@vger.kernel.org> |
| Link: https://lore.kernel.org/561fc5f5eff04b6cbd79ed173cd1c1db@realtek.com |
| Signed-off-by: Takashi Iwai <tiwai@suse.de> |
| Signed-off-by: Sasha Levin <sashal@kernel.org> |
| --- |
| sound/pci/hda/patch_realtek.c | 21 ++++++++++++++++++--- |
| 1 file changed, 18 insertions(+), 3 deletions(-) |
| |
| diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c |
| index 9be5a5c509f09..bf504744ae2a3 100644 |
| --- a/sound/pci/hda/patch_realtek.c |
| +++ b/sound/pci/hda/patch_realtek.c |
| @@ -7234,6 +7234,7 @@ enum { |
| ALC286_FIXUP_SONY_MIC_NO_PRESENCE, |
| ALC269_FIXUP_PINCFG_NO_HP_TO_LINEOUT, |
| ALC269_FIXUP_DELL1_MIC_NO_PRESENCE, |
| + ALC269_FIXUP_DELL1_LIMIT_INT_MIC_BOOST, |
| ALC269_FIXUP_DELL2_MIC_NO_PRESENCE, |
| ALC269_FIXUP_DELL3_MIC_NO_PRESENCE, |
| ALC269_FIXUP_DELL4_MIC_NO_PRESENCE, |
| @@ -7268,6 +7269,7 @@ enum { |
| ALC255_FIXUP_ACER_MIC_NO_PRESENCE, |
| ALC255_FIXUP_ASUS_MIC_NO_PRESENCE, |
| ALC255_FIXUP_DELL1_MIC_NO_PRESENCE, |
| + ALC255_FIXUP_DELL1_LIMIT_INT_MIC_BOOST, |
| ALC255_FIXUP_DELL2_MIC_NO_PRESENCE, |
| ALC255_FIXUP_HEADSET_MODE, |
| ALC255_FIXUP_HEADSET_MODE_NO_HP_MIC, |
| @@ -7760,6 +7762,12 @@ static const struct hda_fixup alc269_fixups[] = { |
| .chained = true, |
| .chain_id = ALC269_FIXUP_HEADSET_MODE |
| }, |
| + [ALC269_FIXUP_DELL1_LIMIT_INT_MIC_BOOST] = { |
| + .type = HDA_FIXUP_FUNC, |
| + .v.func = alc269_fixup_limit_int_mic_boost, |
| + .chained = true, |
| + .chain_id = ALC269_FIXUP_DELL1_MIC_NO_PRESENCE |
| + }, |
| [ALC269_FIXUP_DELL2_MIC_NO_PRESENCE] = { |
| .type = HDA_FIXUP_PINS, |
| .v.pins = (const struct hda_pintbl[]) { |
| @@ -8040,6 +8048,12 @@ static const struct hda_fixup alc269_fixups[] = { |
| .chained = true, |
| .chain_id = ALC255_FIXUP_HEADSET_MODE |
| }, |
| + [ALC255_FIXUP_DELL1_LIMIT_INT_MIC_BOOST] = { |
| + .type = HDA_FIXUP_FUNC, |
| + .v.func = alc269_fixup_limit_int_mic_boost, |
| + .chained = true, |
| + .chain_id = ALC255_FIXUP_DELL1_MIC_NO_PRESENCE |
| + }, |
| [ALC255_FIXUP_DELL2_MIC_NO_PRESENCE] = { |
| .type = HDA_FIXUP_PINS, |
| .v.pins = (const struct hda_pintbl[]) { |
| @@ -10482,6 +10496,7 @@ static const struct hda_model_fixup alc269_fixup_models[] = { |
| {.id = ALC269_FIXUP_DELL2_MIC_NO_PRESENCE, .name = "dell-headset-dock"}, |
| {.id = ALC269_FIXUP_DELL3_MIC_NO_PRESENCE, .name = "dell-headset3"}, |
| {.id = ALC269_FIXUP_DELL4_MIC_NO_PRESENCE, .name = "dell-headset4"}, |
| + {.id = ALC269_FIXUP_DELL4_MIC_NO_PRESENCE_QUIET, .name = "dell-headset4-quiet"}, |
| {.id = ALC283_FIXUP_CHROME_BOOK, .name = "alc283-dac-wcaps"}, |
| {.id = ALC283_FIXUP_SENSE_COMBO_JACK, .name = "alc283-sense-combo"}, |
| {.id = ALC292_FIXUP_TPT440_DOCK, .name = "tpt440-dock"}, |
| @@ -11033,16 +11048,16 @@ static const struct snd_hda_pin_quirk alc269_fallback_pin_fixup_tbl[] = { |
| SND_HDA_PIN_QUIRK(0x10ec0289, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE, |
| {0x19, 0x40000000}, |
| {0x1b, 0x40000000}), |
| - SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE, |
| + SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE_QUIET, |
| {0x19, 0x40000000}, |
| {0x1b, 0x40000000}), |
| SND_HDA_PIN_QUIRK(0x10ec0256, 0x1028, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE, |
| {0x19, 0x40000000}, |
| {0x1a, 0x40000000}), |
| - SND_HDA_PIN_QUIRK(0x10ec0236, 0x1028, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE, |
| + SND_HDA_PIN_QUIRK(0x10ec0236, 0x1028, "Dell", ALC255_FIXUP_DELL1_LIMIT_INT_MIC_BOOST, |
| {0x19, 0x40000000}, |
| {0x1a, 0x40000000}), |
| - SND_HDA_PIN_QUIRK(0x10ec0274, 0x1028, "Dell", ALC274_FIXUP_DELL_AIO_LINEOUT_VERB, |
| + SND_HDA_PIN_QUIRK(0x10ec0274, 0x1028, "Dell", ALC269_FIXUP_DELL1_LIMIT_INT_MIC_BOOST, |
| {0x19, 0x40000000}, |
| {0x1a, 0x40000000}), |
| SND_HDA_PIN_QUIRK(0x10ec0256, 0x1043, "ASUS", ALC2XX_FIXUP_HEADSET_MIC, |
| -- |
| 2.43.0 |
| |