Home Home > GIT Browse > SLE12-SP4-AZURE
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-02-21 09:04:49 +0100
committerTakashi Iwai <tiwai@suse.de>2019-02-21 09:04:56 +0100
commitb333acf0c5d8c643d8aa24832ed6cd947aa392e7 (patch)
tree5c7ede65b75a5b2f2663f58ff028209ea1da2e29
parent35a167edd11440a560c631e91bf0bc90a9e43449 (diff)
ALSA: hda/realtek: Disable PC beep in passthrough on alc285
(bsc#1051510).
-rw-r--r--patches.drivers/ALSA-hda-realtek-Disable-PC-beep-in-passthrough-on-a.patch66
-rw-r--r--series.conf1
2 files changed, 67 insertions, 0 deletions
diff --git a/patches.drivers/ALSA-hda-realtek-Disable-PC-beep-in-passthrough-on-a.patch b/patches.drivers/ALSA-hda-realtek-Disable-PC-beep-in-passthrough-on-a.patch
new file mode 100644
index 0000000000..fd9349cb91
--- /dev/null
+++ b/patches.drivers/ALSA-hda-realtek-Disable-PC-beep-in-passthrough-on-a.patch
@@ -0,0 +1,66 @@
+From c8c6ee611926685a7d753409e0a6e48b9e1b8748 Mon Sep 17 00:00:00 2001
+From: Hui Wang <hui.wang@canonical.com>
+Date: Thu, 14 Feb 2019 11:41:33 +0800
+Subject: [PATCH] ALSA: hda/realtek: Disable PC beep in passthrough on alc285
+Git-commit: c8c6ee611926685a7d753409e0a6e48b9e1b8748
+Patch-mainline: v5.0
+References: bsc#1051510
+
+It is reported that there's a constant background "hum/whitenoise"
+in the headset on the Lenovo X1 machines with the codec alc285, and it
+is confirmed that if we run the command below, the noise will stop.
+ sudo hda-verb /dev/snd/hwC0D0 0x1d SET_PIN_WIDGET_CONTROL 0x0
+
+Then I consulted this issue with Kailang, he told me the pin 0x1d on
+this codec is used for PC beep in, the noise probably comes from this
+pin and we can also disable the PC beep in passthrough, then the PC
+beep in will not affect other sound playback.
+
+Fixes: c4cfcf6f4297 ("ALSA: hda/realtek - fix the pop noise on headphone for lenovo laptops")
+Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1660581
+Cc: <stable@vger.kernel.org>
+Signed-off-by: Kailang Yang <kailang@realtek.com>
+Signed-off-by: Hui Wang <hui.wang@canonical.com>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+
+---
+ sound/pci/hda/patch_realtek.c | 14 +++++++++++++-
+ 1 file changed, 13 insertions(+), 1 deletion(-)
+
+--- a/sound/pci/hda/patch_realtek.c
++++ b/sound/pci/hda/patch_realtek.c
+@@ -5691,6 +5691,7 @@ enum {
+ ALC294_FIXUP_ASUS_HEADSET_MIC,
+ ALC294_FIXUP_ASUS_SPK,
+ ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE,
++ ALC285_FIXUP_LENOVO_PC_BEEP_IN_NOISE,
+ };
+
+ static const struct hda_fixup alc269_fixups[] = {
+@@ -6650,6 +6651,17 @@ static const struct hda_fixup alc269_fix
+ .chained = true,
+ .chain_id = ALC269_FIXUP_HEADSET_MODE_NO_HP_MIC
+ },
++ [ALC285_FIXUP_LENOVO_PC_BEEP_IN_NOISE] = {
++ .type = HDA_FIXUP_VERBS,
++ .v.verbs = (const struct hda_verb[]) {
++ /* Disable PCBEEP-IN passthrough */
++ { 0x20, AC_VERB_SET_COEF_INDEX, 0x36 },
++ { 0x20, AC_VERB_SET_PROC_COEF, 0x57d7 },
++ { }
++ },
++ .chained = true,
++ .chain_id = ALC285_FIXUP_LENOVO_HEADPHONE_NOISE
++ },
+ };
+
+ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
+@@ -7249,7 +7261,7 @@ static const struct snd_hda_pin_quirk al
+ {0x12, 0x90a60130},
+ {0x19, 0x03a11020},
+ {0x21, 0x0321101f}),
+- SND_HDA_PIN_QUIRK(0x10ec0285, 0x17aa, "Lenovo", ALC285_FIXUP_LENOVO_HEADPHONE_NOISE,
++ SND_HDA_PIN_QUIRK(0x10ec0285, 0x17aa, "Lenovo", ALC285_FIXUP_LENOVO_PC_BEEP_IN_NOISE,
+ {0x12, 0x90a60130},
+ {0x14, 0x90170110},
+ {0x19, 0x04a11040},
diff --git a/series.conf b/series.conf
index 7b830ed0a8..4607a0da2b 100644
--- a/series.conf
+++ b/series.conf
@@ -20388,6 +20388,7 @@
patches.drivers/i2c-bcm2835-Clear-current-buffer-pointers-and-counts.patch
patches.fixes/mac80211-Restore-vif-beacon-interval-if-start-ap-fai.patch
patches.drivers/ALSA-hda-realtek-Headset-microphone-and-internal-spe.patch
+ patches.drivers/ALSA-hda-realtek-Disable-PC-beep-in-passthrough-on-a.patch
# git://linuxtv.org/media_tree.git
patches.fixes/0001-media-usb-pwc-Don-t-use-coherent-DMA-buffers-for-ISO.patch