Received: by 2002:ac0:b08d:0:0:0:0:0 with SMTP id l13csp4914202imc; Mon, 25 Feb 2019 13:31:41 -0800 (PST) X-Google-Smtp-Source: AHgI3IbQRFObFNpxhhk0n6tT8ARGxqwJfxdRXtuJkWexLigTl3wHqlAtJKBeUcNlI3S8sJoqBlWK X-Received: by 2002:a63:fb0b:: with SMTP id o11mr3831283pgh.222.1551130301712; Mon, 25 Feb 2019 13:31:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551130301; cv=none; d=google.com; s=arc-20160816; b=OWfgTR4oej6BqsgcNC7JBsXziFVtls4O1uvuSytugowiuRbqjDfo5Mxsyuo7GpmQN+ vAEXqdhXt5ZY+fhV84PdBJLWG14Z3ElriHbt7QVBPuJ3N+OJoNdUtiqTPDsZmQzjKE+X QWwlb769QjoW7D2O3Cz+kkrtaL/jDJN+XAuINnVBU3lPkIIdwDnPiHyzGZ97NO251ztE S/JB0/CwpenlBP3fwoMQ84zAt2o6gdDWnhnC5R+9RSiBFIGl3Sz9SByGXsja1G4fkKkC GypTrVwYTTmJo20dkhnc6AjrrRTIV3w1OaxFIY0G/e+8wHQHI6TwReWSKBk0PvoLclUe TUcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=xrf8SS3pI6UXTwe6Fx1tq+txDCS5dIRSM4UbZqSXANk=; b=FY15r4PwcwR9t+lBVVfVX4C7K26BdHZugcUHMayMlCbESlgClS0j9gm4oVHAzmC8Ib iw0IeKL25i0tbmIB0OrzW70b0miZNlxVLvtC7uQAHr86rrBATt49wQ/eMzRexdLMtdT5 nUJ6wQmjwHmKPBmHiwPar3VRWEhRs1y4bkI0F0ujIktnaDvUV+iwHkKN0I2XprW4v52z zji0oVoKJIhdlJralBjsfSgB8tU0DK5WLgacynAy7wfsqM7ByrELZtMd2h4zaNXWTMHH mvfE6R+m6FG7g19hfFOGBEc0v0/RyR0S7M7vDMShphOZa2rYY1ICZqOaJSBPswORKa3n 7ZFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=wH0hoNWk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s11si10447116pgk.344.2019.02.25.13.31.26; Mon, 25 Feb 2019 13:31:41 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=wH0hoNWk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732245AbfBYVbJ (ORCPT + 99 others); Mon, 25 Feb 2019 16:31:09 -0500 Received: from mail.kernel.org ([198.145.29.99]:36656 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731785AbfBYVbD (ORCPT ); Mon, 25 Feb 2019 16:31:03 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id CA394217F5; Mon, 25 Feb 2019 21:31:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1551130262; bh=dIJR2nn057dslu2lzNU7MVlXDBA10qWhiqvO5TWxMIo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=wH0hoNWkk6LV0W3j57H4D44WpXrZr7pyOwPK1y0Fl/P0jYpwRseElmNoJXU8elHt3 8DRkN9/hxLzrxykaZnmO33OEXNzOIK1XXcl2avzhZJkRHsmK6et19y32Dd89GWgGId yuKKJG+JcfzJa+77VNL0h08zbxxe9lPoAWT1USlw= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Kailang Yang , Hui Wang , Takashi Iwai Subject: [PATCH 4.20 017/183] ALSA: hda/realtek: Disable PC beep in passthrough on alc285 Date: Mon, 25 Feb 2019 22:09:50 +0100 Message-Id: <20190225195057.609364492@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190225195054.748060397@linuxfoundation.org> References: <20190225195054.748060397@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.20-stable review patch. If anyone has any objections, please let me know. ------------------ From: Hui Wang commit c8c6ee611926685a7d753409e0a6e48b9e1b8748 upstream. 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: Signed-off-by: Kailang Yang Signed-off-by: Hui Wang Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman --- 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 @@ -5601,6 +5601,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[] = { @@ -6534,6 +6535,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[] = { @@ -7215,7 +7227,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},