From 851b0db38cfbbbad13127935f11d8e337e35144b Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Tue, 3 Dec 2024 11:31:41 +0100 Subject: [PATCH] 5.4-stable patches added patches: alsa-hda-realtek-apply-quirk-for-medion-e15433.patch alsa-hda-realtek-fix-internal-speaker-and-mic-boost-of-infinix-y4-max.patch alsa-hda-realtek-set-pcbeep-to-default-value-for-alc274.patch alsa-hda-realtek-update-alc225-depop-procedure.patch --- ...ealtek-apply-quirk-for-medion-e15433.patch | 31 ++++ ...aker-and-mic-boost-of-infinix-y4-max.patch | 59 +++++++ ...t-pcbeep-to-default-value-for-alc274.patch | 32 ++++ ...ealtek-update-alc225-depop-procedure.patch | 147 ++++++++++++++++++ queue-5.4/series | 4 + 5 files changed, 273 insertions(+) create mode 100644 queue-5.4/alsa-hda-realtek-apply-quirk-for-medion-e15433.patch create mode 100644 queue-5.4/alsa-hda-realtek-fix-internal-speaker-and-mic-boost-of-infinix-y4-max.patch create mode 100644 queue-5.4/alsa-hda-realtek-set-pcbeep-to-default-value-for-alc274.patch create mode 100644 queue-5.4/alsa-hda-realtek-update-alc225-depop-procedure.patch diff --git a/queue-5.4/alsa-hda-realtek-apply-quirk-for-medion-e15433.patch b/queue-5.4/alsa-hda-realtek-apply-quirk-for-medion-e15433.patch new file mode 100644 index 00000000000..727182e2542 --- /dev/null +++ b/queue-5.4/alsa-hda-realtek-apply-quirk-for-medion-e15433.patch @@ -0,0 +1,31 @@ +From ca0f79f0286046f6a91c099dc941cf7afae198d6 Mon Sep 17 00:00:00 2001 +From: Takashi Iwai +Date: Thu, 28 Nov 2024 08:26:45 +0100 +Subject: ALSA: hda/realtek: Apply quirk for Medion E15433 + +From: Takashi Iwai + +commit ca0f79f0286046f6a91c099dc941cf7afae198d6 upstream. + +Medion E15433 laptop wich ALC269VC (SSID 2782:1705) needs the same +workaround for the missing speaker as another model. + +Link: https://bugzilla.suse.com/show_bug.cgi?id=1233298 +Cc: +Link: https://patch.msgid.link/20241128072646.15659-1-tiwai@suse.de +Signed-off-by: Takashi Iwai +Signed-off-by: Greg Kroah-Hartman +--- + sound/pci/hda/patch_realtek.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/sound/pci/hda/patch_realtek.c ++++ b/sound/pci/hda/patch_realtek.c +@@ -8550,6 +8550,7 @@ static const struct snd_pci_quirk alc269 + SND_PCI_QUIRK(0x2782, 0x0228, "Infinix ZERO BOOK 13", ALC269VB_FIXUP_INFINIX_ZERO_BOOK_13), + SND_PCI_QUIRK(0x2782, 0x0232, "CHUWI CoreBook XPro", ALC269VB_FIXUP_CHUWI_COREBOOK_XPRO), + SND_PCI_QUIRK(0x2782, 0x1701, "Infinix Y4 Max", ALC269VC_FIXUP_INFINIX_Y4_MAX), ++ SND_PCI_QUIRK(0x2782, 0x1705, "MEDION E15433", ALC269VC_FIXUP_INFINIX_Y4_MAX), + SND_PCI_QUIRK(0x2782, 0x1707, "Vaio VJFE-ADL", ALC298_FIXUP_SPK_VOLUME), + SND_PCI_QUIRK(0x8086, 0x2074, "Intel NUC 8", ALC233_FIXUP_INTEL_NUC8_DMIC), + SND_PCI_QUIRK(0x8086, 0x2080, "Intel NUC 8 Rugged", ALC256_FIXUP_INTEL_NUC8_RUGGED), diff --git a/queue-5.4/alsa-hda-realtek-fix-internal-speaker-and-mic-boost-of-infinix-y4-max.patch b/queue-5.4/alsa-hda-realtek-fix-internal-speaker-and-mic-boost-of-infinix-y4-max.patch new file mode 100644 index 00000000000..41714116104 --- /dev/null +++ b/queue-5.4/alsa-hda-realtek-fix-internal-speaker-and-mic-boost-of-infinix-y4-max.patch @@ -0,0 +1,59 @@ +From 5ebe792a5139f1ce6e4aed22bef12e7e2660df96 Mon Sep 17 00:00:00 2001 +From: Dinesh Kumar +Date: Mon, 25 Nov 2024 14:58:42 +0530 +Subject: ALSA: hda/realtek: Fix Internal Speaker and Mic boost of Infinix Y4 Max + +From: Dinesh Kumar + +commit 5ebe792a5139f1ce6e4aed22bef12e7e2660df96 upstream. + +Internal Speaker of Infinix Y4 Max remains muted due to incorrect +Pin configuration, and the Internal Mic records high noise. This patch +corrects the Pin configuration for the Internal Speaker and limits +the Internal Mic boost. +HW Probe for device: https://linux-hardware.org/?probe=6d4386c347 +Test: Internal Speaker works fine, Mic has low noise. + +Signed-off-by: Dinesh Kumar +Cc: +Link: https://patch.msgid.link/20241125092842.13208-1-desikumar81@gmail.com +Signed-off-by: Takashi Iwai +Signed-off-by: Greg Kroah-Hartman +--- + sound/pci/hda/patch_realtek.c | 11 +++++++++++ + 1 file changed, 11 insertions(+) + +--- a/sound/pci/hda/patch_realtek.c ++++ b/sound/pci/hda/patch_realtek.c +@@ -6422,6 +6422,7 @@ enum { + ALC269_FIXUP_THINKPAD_ACPI, + ALC269_FIXUP_DMIC_THINKPAD_ACPI, + ALC269VB_FIXUP_INFINIX_ZERO_BOOK_13, ++ ALC269VC_FIXUP_INFINIX_Y4_MAX, + ALC269VB_FIXUP_CHUWI_COREBOOK_XPRO, + ALC255_FIXUP_ACER_MIC_NO_PRESENCE, + ALC255_FIXUP_ASUS_MIC_NO_PRESENCE, +@@ -6681,6 +6682,15 @@ static const struct hda_fixup alc269_fix + .chained = true, + .chain_id = ALC269_FIXUP_LIMIT_INT_MIC_BOOST + }, ++ [ALC269VC_FIXUP_INFINIX_Y4_MAX] = { ++ .type = HDA_FIXUP_PINS, ++ .v.pins = (const struct hda_pintbl[]) { ++ { 0x1b, 0x90170150 }, /* use as internal speaker */ ++ { } ++ }, ++ .chained = true, ++ .chain_id = ALC269_FIXUP_LIMIT_INT_MIC_BOOST ++ }, + [ALC269VB_FIXUP_CHUWI_COREBOOK_XPRO] = { + .type = HDA_FIXUP_PINS, + .v.pins = (const struct hda_pintbl[]) { +@@ -8539,6 +8549,7 @@ static const struct snd_pci_quirk alc269 + SND_PCI_QUIRK(0x2782, 0x0214, "VAIO VJFE-CL", ALC269_FIXUP_LIMIT_INT_MIC_BOOST), + SND_PCI_QUIRK(0x2782, 0x0228, "Infinix ZERO BOOK 13", ALC269VB_FIXUP_INFINIX_ZERO_BOOK_13), + SND_PCI_QUIRK(0x2782, 0x0232, "CHUWI CoreBook XPro", ALC269VB_FIXUP_CHUWI_COREBOOK_XPRO), ++ SND_PCI_QUIRK(0x2782, 0x1701, "Infinix Y4 Max", ALC269VC_FIXUP_INFINIX_Y4_MAX), + SND_PCI_QUIRK(0x2782, 0x1707, "Vaio VJFE-ADL", ALC298_FIXUP_SPK_VOLUME), + SND_PCI_QUIRK(0x8086, 0x2074, "Intel NUC 8", ALC233_FIXUP_INTEL_NUC8_DMIC), + SND_PCI_QUIRK(0x8086, 0x2080, "Intel NUC 8 Rugged", ALC256_FIXUP_INTEL_NUC8_RUGGED), diff --git a/queue-5.4/alsa-hda-realtek-set-pcbeep-to-default-value-for-alc274.patch b/queue-5.4/alsa-hda-realtek-set-pcbeep-to-default-value-for-alc274.patch new file mode 100644 index 00000000000..12a44068e2e --- /dev/null +++ b/queue-5.4/alsa-hda-realtek-set-pcbeep-to-default-value-for-alc274.patch @@ -0,0 +1,32 @@ +From 155699ccab7c78cbba69798242b68bc8ac66d5d2 Mon Sep 17 00:00:00 2001 +From: Kailang Yang +Date: Thu, 21 Nov 2024 16:16:26 +0800 +Subject: ALSA: hda/realtek: Set PCBeep to default value for ALC274 + +From: Kailang Yang + +commit 155699ccab7c78cbba69798242b68bc8ac66d5d2 upstream. + +BIOS Enable PC beep path cause pop noise via speaker during boot time. +Set to default value from driver will solve the issue. + +Signed-off-by: Kailang Yang +Cc: +Link: https://lore.kernel.org/2721bb57e20a44c3826c473e933f9105@realtek.com +Signed-off-by: Takashi Iwai +Signed-off-by: Greg Kroah-Hartman +--- + sound/pci/hda/patch_realtek.c | 2 ++ + 1 file changed, 2 insertions(+) + +--- a/sound/pci/hda/patch_realtek.c ++++ b/sound/pci/hda/patch_realtek.c +@@ -406,6 +406,8 @@ static void alc_fill_eapd_coef(struct hd + break; + case 0x10ec0234: + case 0x10ec0274: ++ alc_write_coef_idx(codec, 0x6e, 0x0c25); ++ fallthrough; + case 0x10ec0294: + case 0x10ec0700: + case 0x10ec0701: diff --git a/queue-5.4/alsa-hda-realtek-update-alc225-depop-procedure.patch b/queue-5.4/alsa-hda-realtek-update-alc225-depop-procedure.patch new file mode 100644 index 00000000000..f52cca948e0 --- /dev/null +++ b/queue-5.4/alsa-hda-realtek-update-alc225-depop-procedure.patch @@ -0,0 +1,147 @@ +From 1fd50509fe14a9adc9329e0454b986157a4c155a Mon Sep 17 00:00:00 2001 +From: Kailang Yang +Date: Thu, 14 Nov 2024 15:08:07 +0800 +Subject: ALSA: hda/realtek: Update ALC225 depop procedure + +From: Kailang Yang + +commit 1fd50509fe14a9adc9329e0454b986157a4c155a upstream. + +Old procedure has a chance to meet Headphone no output. + +Fixes: da911b1f5e98 ("ALSA: hda/realtek - update ALC225 depop optimize") +Signed-off-by: Kailang Yang +Cc: +Link: https://lore.kernel.org/5a27b016ba9d42b4a4e6dadce50a3ba4@realtek.com +Signed-off-by: Takashi Iwai +Signed-off-by: Greg Kroah-Hartman +--- + sound/pci/hda/patch_realtek.c | 95 +++++++++++++++++++----------------------- + 1 file changed, 43 insertions(+), 52 deletions(-) + +--- a/sound/pci/hda/patch_realtek.c ++++ b/sound/pci/hda/patch_realtek.c +@@ -3634,33 +3634,28 @@ static void alc225_init(struct hda_codec + hp1_pin_sense = snd_hda_jack_detect(codec, hp_pin); + hp2_pin_sense = snd_hda_jack_detect(codec, 0x16); + +- if (hp1_pin_sense || hp2_pin_sense) ++ if (hp1_pin_sense || hp2_pin_sense) { + msleep(2); ++ alc_update_coefex_idx(codec, 0x57, 0x04, 0x0007, 0x1); /* Low power */ + +- alc_update_coefex_idx(codec, 0x57, 0x04, 0x0007, 0x1); /* Low power */ ++ if (hp1_pin_sense) ++ snd_hda_codec_write(codec, hp_pin, 0, ++ AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT); ++ if (hp2_pin_sense) ++ snd_hda_codec_write(codec, 0x16, 0, ++ AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT); ++ msleep(75); ++ ++ if (hp1_pin_sense) ++ snd_hda_codec_write(codec, hp_pin, 0, ++ AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE); ++ if (hp2_pin_sense) ++ snd_hda_codec_write(codec, 0x16, 0, ++ AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE); + +- if (hp1_pin_sense || spec->ultra_low_power) +- snd_hda_codec_write(codec, hp_pin, 0, +- AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_MUTE); +- if (hp2_pin_sense) +- snd_hda_codec_write(codec, 0x16, 0, +- AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_MUTE); +- +- if (hp1_pin_sense || hp2_pin_sense || spec->ultra_low_power) +- msleep(85); +- +- if (hp1_pin_sense || spec->ultra_low_power) +- snd_hda_codec_write(codec, hp_pin, 0, +- AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT); +- if (hp2_pin_sense) +- snd_hda_codec_write(codec, 0x16, 0, +- AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT); +- +- if (hp1_pin_sense || hp2_pin_sense || spec->ultra_low_power) +- msleep(100); +- +- alc_update_coef_idx(codec, 0x4a, 3 << 10, 0); +- alc_update_coefex_idx(codec, 0x57, 0x04, 0x0007, 0x4); /* Hight power */ ++ msleep(75); ++ alc_update_coefex_idx(codec, 0x57, 0x04, 0x0007, 0x4); /* Hight power */ ++ } + } + + static void alc225_shutup(struct hda_codec *codec) +@@ -3672,36 +3667,35 @@ static void alc225_shutup(struct hda_cod + if (!hp_pin) + hp_pin = 0x21; + +- alc_disable_headset_jack_key(codec); +- /* 3k pull low control for Headset jack. */ +- alc_update_coef_idx(codec, 0x4a, 0, 3 << 10); +- + hp1_pin_sense = snd_hda_jack_detect(codec, hp_pin); + hp2_pin_sense = snd_hda_jack_detect(codec, 0x16); + +- if (hp1_pin_sense || hp2_pin_sense) ++ if (hp1_pin_sense || hp2_pin_sense) { ++ alc_disable_headset_jack_key(codec); ++ /* 3k pull low control for Headset jack. */ ++ alc_update_coef_idx(codec, 0x4a, 0, 3 << 10); + msleep(2); + +- if (hp1_pin_sense || spec->ultra_low_power) +- snd_hda_codec_write(codec, hp_pin, 0, +- AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_MUTE); +- if (hp2_pin_sense) +- snd_hda_codec_write(codec, 0x16, 0, +- AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_MUTE); +- +- if (hp1_pin_sense || hp2_pin_sense || spec->ultra_low_power) +- msleep(85); +- +- if (hp1_pin_sense || spec->ultra_low_power) +- snd_hda_codec_write(codec, hp_pin, 0, +- AC_VERB_SET_PIN_WIDGET_CONTROL, 0x0); +- if (hp2_pin_sense) +- snd_hda_codec_write(codec, 0x16, 0, +- AC_VERB_SET_PIN_WIDGET_CONTROL, 0x0); +- +- if (hp1_pin_sense || hp2_pin_sense || spec->ultra_low_power) +- msleep(100); +- ++ if (hp1_pin_sense) ++ snd_hda_codec_write(codec, hp_pin, 0, ++ AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_MUTE); ++ if (hp2_pin_sense) ++ snd_hda_codec_write(codec, 0x16, 0, ++ AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_MUTE); ++ ++ msleep(75); ++ ++ if (hp1_pin_sense) ++ snd_hda_codec_write(codec, hp_pin, 0, ++ AC_VERB_SET_PIN_WIDGET_CONTROL, 0x0); ++ if (hp2_pin_sense) ++ snd_hda_codec_write(codec, 0x16, 0, ++ AC_VERB_SET_PIN_WIDGET_CONTROL, 0x0); ++ ++ msleep(75); ++ alc_update_coef_idx(codec, 0x4a, 3 << 10, 0); ++ alc_enable_headset_jack_key(codec); ++ } + alc_auto_setup_eapd(codec, false); + alc_shutup_pins(codec); + if (spec->ultra_low_power) { +@@ -3712,9 +3706,6 @@ static void alc225_shutup(struct hda_cod + alc_update_coef_idx(codec, 0x4a, 3<<4, 2<<4); + msleep(30); + } +- +- alc_update_coef_idx(codec, 0x4a, 3 << 10, 0); +- alc_enable_headset_jack_key(codec); + } + + static void alc_default_init(struct hda_codec *codec) diff --git a/queue-5.4/series b/queue-5.4/series index a612702e554..f191f7a0bb3 100644 --- a/queue-5.4/series +++ b/queue-5.4/series @@ -169,3 +169,7 @@ arm64-tls-fix-context-switching-of-tpidrro_el0-when-kpti-is-enabled.patch block-fix-ordering-between-checking-blk_mq_s_stopped-request-adding.patch hid-wacom-interpret-tilt-data-from-intuos-pro-bt-as-signed-values.patch media-wl128x-fix-atomicity-violation-in-fmc_send_cmd.patch +alsa-hda-realtek-update-alc225-depop-procedure.patch +alsa-hda-realtek-set-pcbeep-to-default-value-for-alc274.patch +alsa-hda-realtek-fix-internal-speaker-and-mic-boost-of-infinix-y4-max.patch +alsa-hda-realtek-apply-quirk-for-medion-e15433.patch -- 2.47.3