Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp10717028ybl; Fri, 27 Dec 2019 00:41:02 -0800 (PST) X-Google-Smtp-Source: APXvYqycOE1S3zXLfQKpMQjiAZadNiJQHNIXTnDeylzRnxNeVqX5CYm9OHpm815sT4W6tOJxpd47 X-Received: by 2002:a9d:6396:: with SMTP id w22mr55682236otk.364.1577436062645; Fri, 27 Dec 2019 00:41:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1577436062; cv=none; d=google.com; s=arc-20160816; b=HjtfMx/co1AwxUeNIR6TJCmpse4ZISEqEKHePuQXuoSCM4kj4w+Am7QndGxNefdI+3 81GsXl7GNpxSrsmrny37jyA4jdNJfqPWP4sMJJCh192rF2welnUTIzAaqbjrBZ+hve21 ZtlTNtxQsAnuu0XEwsr0snNmdCx0FvaQJ5F1T3MAS158HCPlHlKUWL4ll4QovWnnCrjo JbEOsjChpQbxPRsjEOGSuL2lj+PmFg+UL4OcKIE9om8qiu2OR2J7wtxK3TIuqZNtr+FM Uuc2+SFMKRHrD87FeeoMg2S61U7iHCtqZ3qZU0UlMypDWPaD7oYn/GL4hpmshK4UTiIB v9EA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=0AQj3lh0dp90BrCkbzH3dJXsxK6ILYTeCrSMLfhWdoc=; b=c0if4+26rupFNAM2EnlL/TSDrRu0M9lA9ZXgIH0mE0AUaYFDK0g3CV/3ZpNqJHlpDY r38KOTN3x+HhD+ghMKniXdPswJ5ftSHD/zx6fjBUAZkoJbvpyAQKBs0KT8GSn+FNiEIe CR401txQvpWs9pp0zQ9+uRyv/8rOmk+RQqEsLIZrlw57YjKUOYhueMVXMtPVXtw3O8+a yrfk8osPVFQAmIQfTIT6t5lkz4plst772CrnrAL/vj45Bikwa4Fd2bqcXHNjO9po61P9 80jKq3Ta0d0P0gDQKLev8qQSmQHj1p5PD9lG4wKKTDeBqhwD+JwK2raavLke+zTqQz/9 JWEA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@endlessm-com.20150623.gappssmtp.com header.s=20150623 header.b=JFgdHhWM; 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 l19si15310553oii.54.2019.12.27.00.40.50; Fri, 27 Dec 2019 00:41:02 -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=@endlessm-com.20150623.gappssmtp.com header.s=20150623 header.b=JFgdHhWM; 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 S1726527AbfL0IjS (ORCPT + 99 others); Fri, 27 Dec 2019 03:39:18 -0500 Received: from mail-ot1-f67.google.com ([209.85.210.67]:41461 "EHLO mail-ot1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726197AbfL0IjS (ORCPT ); Fri, 27 Dec 2019 03:39:18 -0500 Received: by mail-ot1-f67.google.com with SMTP id r27so35523136otc.8 for ; Fri, 27 Dec 2019 00:39:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=endlessm-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=0AQj3lh0dp90BrCkbzH3dJXsxK6ILYTeCrSMLfhWdoc=; b=JFgdHhWMInr1A86TzQxVXO0hcqH0Epc7vYOitkFXmduOcWsmxKH97ExTRcH7OtKB2f bAmUKljpZfxt3csiK7WOrbFd/ekIJt6AbYvOjNkF+eISK2EcklfdzmeNxOzy8a7ALgMg M8Ye1lGHYsUtvopGLCTb3mPiULjmPawTAHVf+60rqiIbETD+n6iu589BlxPNnUVV8SwW 7Wqs7gNcMlICVygz4KJJUjlYmFaQSVyO+Gz5G4zGi1H35Bre532aKFlK+ZfBkP7hUDLo yV7H/V0dDUoQeLaVHaCbiHG11G529rA9H0TssuabE/NoaaCErcKxMsZLLkjA340i12SC ZV7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=0AQj3lh0dp90BrCkbzH3dJXsxK6ILYTeCrSMLfhWdoc=; b=Y/Q7fnkvTldwEFVKgKjpiggU6rPCGGjuTTMJqcl+E8hoe4c8Of1XyH5u7ZQpVrS6us GYRzwUQGk8o5lNun4i448F4Dmd/cUkQqrxggSu++dRQhUBjAakzxcBthriu3Dx0SrYQy J3176mgmsw8yDMuQRjT978tLiTbY/NOr8vXTSEVgwjNa2mjZ9prWJFqE3CLA8LpXw9Mm JeGBeA3Iutyw25pifmGUX0EitetjQ1jlpPxBaRUo0JmhlLXowhF9eOFrw/2Z51hy+BVm n5YJv2TwRGPP9AETz6FY3pQzBeUWq1Zq6kcF9fQ/nDXf3TqJF67wRf0+pIDZDHuNy5HT sZlQ== X-Gm-Message-State: APjAAAW1+QBpqdS1SNYqUkNzsqzkm9R2ofFkS43VuuDsp8HbVF5YwZuT ZEwjnZ/serRRfshzSJvd4D4vbUoA8y8GwywAlVkS/Q== X-Received: by 2002:a05:6830:1248:: with SMTP id s8mr55046530otp.202.1577435957406; Fri, 27 Dec 2019 00:39:17 -0800 (PST) MIME-Version: 1.0 References: <20191227065724.2581-1-chris.chiu@pacidal.com> <9a6937eb53264ef99409ac234fffe8af@realtek.com> In-Reply-To: From: Chris Chiu Date: Fri, 27 Dec 2019 16:41:04 +0800 Message-ID: Subject: Re: [PATCH] ALSA: hda/realtek - Enable the subwoofer of ASUS UX431FLC To: Takashi Iwai Cc: Kailang , "perex@perex.cz" , "tiwai@suse.com" , "hui.wang@canonical.com" , "tomas.espeleta@gmail.com" , "alsa-devel@alsa-project.org" , "linux-kernel@vger.kernel.org" , "linux@endlessm.com" , Jian-Hong Pan Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Dec 27, 2019 at 4:18 PM Takashi Iwai wrote: > > On Fri, 27 Dec 2019 08:28:32 +0100, > Kailang wrote: > > > > Hi all, > > > > Current kernel had exist function alc285_fixup_speaker2_to_dac1 to fixed dac for 0x17. > > Replace as below. > > Good catch. > > Chris, could you rebase on the top of the current for-linus branch, > modify as Kailang suggested and resubmit? > > Also, the commit id mentioned in your patch doesn't exist. Please > correct to the right id. > > No problem. I'll send a v2 patch later with what Kailang suggested. Chris > thanks, > > Takashi > > > > > diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index fada1ff61353..0193a8722be2 100644 > > --- a/sound/pci/hda/patch_realtek.c > > +++ b/sound/pci/hda/patch_realtek.c > > @@ -5950,7 +5960,8 @@ enum { > > ALC269VC_FIXUP_ACER_HEADSET_MIC, > > ALC294_FIXUP_ASUS_INTSPK_HEADSET_MIC, > > ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE, > > - ALC294_FIXUP_ASUS_INTSPK_GPIO, > > + ALC294_FIXUP_ASUS_DUAL_SPEAKERS, > > + ALC294_FIXUP_FIXED_DAC_SUBWOOFER, > > }; > > > > static const struct hda_fixup alc269_fixups[] = { @@ -7097,10 +7108,9 @@ static const struct hda_fixup alc269_fixups[] = { > > { } > > } > > }, > > - [ALC294_FIXUP_ASUS_INTSPK_HEADSET_MIC] = { > > + [ALC294_FIXUP_ASUS_HEADSET_MIC] = { > > .type = HDA_FIXUP_PINS, > > .v.pins = (const struct hda_pintbl[]) { > > - { 0x14, 0x411111f0 }, /* disable confusing internal speaker */ > > { 0x19, 0x04a11150 }, /* use as headset mic, without its own jack detect */ > > { } > > }, > > @@ -7117,12 +7127,18 @@ static const struct hda_fixup alc269_fixups[] = { > > .chained = true, > > .chain_id = ALC256_FIXUP_ASUS_HEADSET_MODE > > }, > > - [ALC294_FIXUP_ASUS_INTSPK_GPIO] = { > > + [ALC294_FIXUP_FIXED_DAC_SUBWOOFER] = { > > + .type = HDA_FIXUP_FUNC, > > + .v.func = alc285_fixup_speaker2_to_dac1, > > + .chained = true, > > + .chain_id = ALC294_FIXUP_ASUS_HEADSET_MIC > > + }, > > + [ALC294_FIXUP_ASUS_DUAL_SPEAKERS] = { > > .type = HDA_FIXUP_FUNC, > > /* The GPIO must be pulled to initialize the AMP */ > > .v.func = alc_fixup_gpio4, > > .chained = true, > > - .chain_id = ALC294_FIXUP_ASUS_INTSPK_HEADSET_MIC > > + .chain_id = ALC294_FIXUP_FIXED_DAC_SUBWOOFER > > }, > > }; > > > > @@ -7291,7 +7307,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { > > SND_PCI_QUIRK(0x1043, 0x1427, "Asus Zenbook UX31E", ALC269VB_FIXUP_ASUS_ZENBOOK), > > SND_PCI_QUIRK(0x1043, 0x1517, "Asus Zenbook UX31A", ALC269VB_FIXUP_ASUS_ZENBOOK_UX31A), > > SND_PCI_QUIRK(0x1043, 0x16e3, "ASUS UX50", ALC269_FIXUP_STEREO_DMIC), > > - SND_PCI_QUIRK(0x1043, 0x17d1, "ASUS UX431FL", ALC294_FIXUP_ASUS_INTSPK_GPIO), > > + SND_PCI_QUIRK(0x1043, 0x17d1, "ASUS UX431FL", > > +ALC294_FIXUP_ASUS_DUAL_SPEAKERS), > > SND_PCI_QUIRK(0x1043, 0x18b1, "Asus MJ401TA", ALC256_FIXUP_ASUS_HEADSET_MIC), > > SND_PCI_QUIRK(0x1043, 0x1a13, "Asus G73Jw", ALC269_FIXUP_ASUS_G73JW), > > SND_PCI_QUIRK(0x1043, 0x1a30, "ASUS X705UD", ALC256_FIXUP_ASUS_MIC), > > -- > > > > > -----Original Message----- > > > From: Chris Chiu > > > Sent: Friday, December 27, 2019 2:57 PM > > > To: perex@perex.cz; tiwai@suse.com; Kailang ; > > > hui.wang@canonical.com; tomas.espeleta@gmail.com > > > Cc: alsa-devel@alsa-project.org; linux-kernel@vger.kernel.org; > > > linux@endlessm.com; Chris Chiu ; Jian-Hong Pan > > > > > > Subject: [PATCH] ALSA: hda/realtek - Enable the subwoofer of ASUS UX431FLC > > > > > > From: Chris Chiu > > > > > > ASUS reported that there's an additional speaker which serves as the > > > subwoofer and uses DAC 0x02. It does not work with the commit > > > 73a723348a43 ("ALSA: hda/realtek - Enable internal speaker of ASUS > > > UX431FLC") which enables the amplifier and front speakers. This commit > > > enables the subwoofer to improve the acoustic experience. > > > > > > Signed-off-by: Chris Chiu > > > Signed-off-by: Jian-Hong Pan > > > --- > > > sound/pci/hda/patch_realtek.c | 28 ++++++++++++++++++++++------ > > > 1 file changed, 22 insertions(+), 6 deletions(-) > > > > > > diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c > > > index fada1ff61353..0193a8722be2 100644 > > > --- a/sound/pci/hda/patch_realtek.c > > > +++ b/sound/pci/hda/patch_realtek.c > > > @@ -5576,6 +5576,16 @@ static void alc295_fixup_disable_dac3(struct > > > hda_codec *codec, > > > } > > > } > > > > > > +/* Fixed DAC (0x02) on NID 0x17 to enable the mono speaker */ static > > > +void alc294_fixup_fixed_dac_subwoofer(struct hda_codec *codec, > > > + const struct hda_fixup *fix, int action) { > > > + if (action == HDA_FIXUP_ACT_PRE_PROBE) { > > > + hda_nid_t conn[1] = { 0x02 }; > > > + snd_hda_override_conn_list(codec, 0x17, 1, conn); > > > + } > > > +} > > > + > > > /* Hook to update amp GPIO4 for automute */ static void > > > alc280_hp_gpio4_automute_hook(struct hda_codec *codec, > > > struct hda_jack_callback *jack) > > > @@ -5950,7 +5960,8 @@ enum { > > > ALC269VC_FIXUP_ACER_HEADSET_MIC, > > > ALC294_FIXUP_ASUS_INTSPK_HEADSET_MIC, > > > ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE, > > > - ALC294_FIXUP_ASUS_INTSPK_GPIO, > > > + ALC294_FIXUP_ASUS_DUAL_SPEAKERS, > > > + ALC294_FIXUP_FIXED_DAC_SUBWOOFER, > > > }; > > > > > > static const struct hda_fixup alc269_fixups[] = { @@ -7097,10 +7108,9 @@ > > > static const struct hda_fixup alc269_fixups[] = { > > > { } > > > } > > > }, > > > - [ALC294_FIXUP_ASUS_INTSPK_HEADSET_MIC] = { > > > + [ALC294_FIXUP_ASUS_HEADSET_MIC] = { > > > .type = HDA_FIXUP_PINS, > > > .v.pins = (const struct hda_pintbl[]) { > > > - { 0x14, 0x411111f0 }, /* disable confusing internal speaker */ > > > { 0x19, 0x04a11150 }, /* use as headset mic, without its own > > > jack detect */ > > > { } > > > }, > > > @@ -7117,12 +7127,18 @@ static const struct hda_fixup alc269_fixups[] = { > > > .chained = true, > > > .chain_id = ALC256_FIXUP_ASUS_HEADSET_MODE > > > }, > > > - [ALC294_FIXUP_ASUS_INTSPK_GPIO] = { > > > + [ALC294_FIXUP_FIXED_DAC_SUBWOOFER] = { > > > + .type = HDA_FIXUP_FUNC, > > > + .v.func = alc294_fixup_fixed_dac_subwoofer, > > > + .chained = true, > > > + .chain_id = ALC294_FIXUP_ASUS_HEADSET_MIC > > > + }, > > > + [ALC294_FIXUP_ASUS_DUAL_SPEAKERS] = { > > > .type = HDA_FIXUP_FUNC, > > > /* The GPIO must be pulled to initialize the AMP */ > > > .v.func = alc_fixup_gpio4, > > > .chained = true, > > > - .chain_id = ALC294_FIXUP_ASUS_INTSPK_HEADSET_MIC > > > + .chain_id = ALC294_FIXUP_FIXED_DAC_SUBWOOFER > > > }, > > > }; > > > > > > @@ -7291,7 +7307,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] > > > = { > > > SND_PCI_QUIRK(0x1043, 0x1427, "Asus Zenbook UX31E", > > > ALC269VB_FIXUP_ASUS_ZENBOOK), > > > SND_PCI_QUIRK(0x1043, 0x1517, "Asus Zenbook UX31A", > > > ALC269VB_FIXUP_ASUS_ZENBOOK_UX31A), > > > SND_PCI_QUIRK(0x1043, 0x16e3, "ASUS UX50", > > > ALC269_FIXUP_STEREO_DMIC), > > > - SND_PCI_QUIRK(0x1043, 0x17d1, "ASUS UX431FL", > > > ALC294_FIXUP_ASUS_INTSPK_GPIO), > > > + SND_PCI_QUIRK(0x1043, 0x17d1, "ASUS UX431FL", > > > +ALC294_FIXUP_ASUS_DUAL_SPEAKERS), > > > SND_PCI_QUIRK(0x1043, 0x18b1, "Asus MJ401TA", > > > ALC256_FIXUP_ASUS_HEADSET_MIC), > > > SND_PCI_QUIRK(0x1043, 0x1a13, "Asus G73Jw", > > > ALC269_FIXUP_ASUS_G73JW), > > > SND_PCI_QUIRK(0x1043, 0x1a30, "ASUS X705UD", > > > ALC256_FIXUP_ASUS_MIC), > > > -- > > > 2.20.1 > >