public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Sasha Levin <sashal@kernel.org>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: Vasiliy Kovalev <kovalev@altlinux.org>,
	Takashi Iwai <tiwai@suse.de>, Sasha Levin <sashal@kernel.org>,
	perex@perex.cz, tiwai@suse.com, kailang@realtek.com,
	sbinding@opensource.cirrus.com, simont@opensource.cirrus.com,
	josh@joshuagrisham.com, rf@opensource.cirrus.com,
	linux-sound@vger.kernel.org
Subject: [PATCH AUTOSEL 6.12 08/29] ALSA: hda/realtek - Add support for ASUS Zen AIO 27 Z272SD_A272SD audio
Date: Fri, 20 Dec 2024 12:11:09 -0500	[thread overview]
Message-ID: <20241220171130.511389-8-sashal@kernel.org> (raw)
In-Reply-To: <20241220171130.511389-1-sashal@kernel.org>

From: Vasiliy Kovalev <kovalev@altlinux.org>

[ Upstream commit 1b452c2de5555d832cd51c46824272a44ad7acac ]

Introduces necessary quirks to enable audio functionality on the
ASUS Zen AIO 27 Z272SD_A272SD:
- configures verbs to activate internal speakers and headphone jack.
- implements adjustments for headset microphone functionality.

The speaker and jack configurations were derived from a dump of
the working Windows driver, while the headset microphone
functionality was fine-tuned through experimental testing.

Link: https://lore.kernel.org/all/CAGGMHBOGDUnMewBTrZgoBKFk_A4sNF4fEXwfH9Ay8SNTzjy0-g@mail.gmail.com/T/
Signed-off-by: Vasiliy Kovalev <kovalev@altlinux.org>
Link: https://patch.msgid.link/20241205210306.977634-1-kovalev@altlinux.org
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 sound/pci/hda/patch_realtek.c | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 973671e0cdb0..5b518a44b78a 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -7704,6 +7704,7 @@ enum {
 	ALC274_FIXUP_HP_MIC,
 	ALC274_FIXUP_HP_HEADSET_MIC,
 	ALC274_FIXUP_HP_ENVY_GPIO,
+	ALC274_FIXUP_ASUS_ZEN_AIO_27,
 	ALC256_FIXUP_ASUS_HPE,
 	ALC285_FIXUP_THINKPAD_NO_BASS_SPK_HEADSET_JACK,
 	ALC287_FIXUP_HP_GPIO_LED,
@@ -9505,6 +9506,26 @@ static const struct hda_fixup alc269_fixups[] = {
 		.type = HDA_FIXUP_FUNC,
 		.v.func = alc274_fixup_hp_envy_gpio,
 	},
+	[ALC274_FIXUP_ASUS_ZEN_AIO_27] = {
+		.type = HDA_FIXUP_VERBS,
+		.v.verbs = (const struct hda_verb[]) {
+			{ 0x20, AC_VERB_SET_COEF_INDEX, 0x10 },
+			{ 0x20, AC_VERB_SET_PROC_COEF, 0xc420 },
+			{ 0x20, AC_VERB_SET_COEF_INDEX, 0x40 },
+			{ 0x20, AC_VERB_SET_PROC_COEF, 0x8800 },
+			{ 0x20, AC_VERB_SET_COEF_INDEX, 0x49 },
+			{ 0x20, AC_VERB_SET_PROC_COEF, 0x0249 },
+			{ 0x20, AC_VERB_SET_COEF_INDEX, 0x4a },
+			{ 0x20, AC_VERB_SET_PROC_COEF, 0x202b },
+			{ 0x20, AC_VERB_SET_COEF_INDEX, 0x62 },
+			{ 0x20, AC_VERB_SET_PROC_COEF, 0xa007 },
+			{ 0x20, AC_VERB_SET_COEF_INDEX, 0x6b },
+			{ 0x20, AC_VERB_SET_PROC_COEF, 0x5060 },
+			{}
+		},
+		.chained = true,
+		.chain_id = ALC2XX_FIXUP_HEADSET_MIC,
+	},
 	[ALC256_FIXUP_ASUS_HPE] = {
 		.type = HDA_FIXUP_VERBS,
 		.v.verbs = (const struct hda_verb[]) {
@@ -10614,6 +10635,7 @@ static const struct hda_quirk alc269_fixup_tbl[] = {
 	SND_PCI_QUIRK(0x1043, 0x1f62, "ASUS UX7602ZM", ALC245_FIXUP_CS35L41_SPI_2),
 	SND_PCI_QUIRK(0x1043, 0x1f92, "ASUS ROG Flow X16", ALC289_FIXUP_ASUS_GA401),
 	SND_PCI_QUIRK(0x1043, 0x3030, "ASUS ZN270IE", ALC256_FIXUP_ASUS_AIO_GPIO2),
+	SND_PCI_QUIRK(0x1043, 0x31d0, "ASUS Zen AIO 27 Z272SD_A272SD", ALC274_FIXUP_ASUS_ZEN_AIO_27),
 	SND_PCI_QUIRK(0x1043, 0x3a20, "ASUS G614JZR", ALC285_FIXUP_ASUS_SPI_REAR_SPEAKERS),
 	SND_PCI_QUIRK(0x1043, 0x3a30, "ASUS G814JVR/JIR", ALC285_FIXUP_ASUS_SPI_REAR_SPEAKERS),
 	SND_PCI_QUIRK(0x1043, 0x3a40, "ASUS G814JZR", ALC285_FIXUP_ASUS_SPI_REAR_SPEAKERS),
-- 
2.39.5


  parent reply	other threads:[~2024-12-20 17:11 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-20 17:11 [PATCH AUTOSEL 6.12 01/29] perf/x86/intel: Add Arrow Lake U support Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 02/29] wifi: mac80211: fix mbss changed flags corruption on 32 bit systems Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 03/29] wifi: cfg80211: clear link ID from bitmap during link delete after clean up Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 04/29] wifi: mac80211: wake the queues in case of failure in resume Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 05/29] drm/amdgpu: use sjt mec fw on gfx943 for sriov Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 06/29] drm/amdkfd: Correct the migration DMA map direction Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 07/29] ALSA: hda: cs35l56: Remove calls to cs35l56_force_sync_asp1_registers_from_cache() Sasha Levin
2024-12-20 17:11 ` Sasha Levin [this message]
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 09/29] btrfs: handle bio_split() errors Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 10/29] btrfs: flush delalloc workers queue before stopping cleaner kthread during unmount Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 11/29] ALSA: hda/ca0132: Use standard HD-audio quirk matching helpers Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 12/29] ALSA: hda/realtek: Add new alc2xx-fixup-headset-mic model Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 13/29] sound: usb: enable DSD output for ddHiFi TC44C Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 14/29] sound: usb: format: don't warn that raw DSD is unsupported Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 15/29] spi: spi-cadence-qspi: Disable STIG mode for Altera SoCFPGA Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 16/29] ASoC: audio-graph-card: Call of_node_put() on correct node Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 17/29] ARC: build: disallow invalid PAE40 + 4K page config Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 18/29] ARC: build: Use __force to suppress per-CPU cmpxchg warnings Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 19/29] ARC: bpf: Correct conditional check in 'check_jmp_32' Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 20/29] bpf: fix potential error return Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 21/29] ksmbd: retry iterate_dir in smb2_query_dir Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 22/29] ksmbd: set ATTR_CTIME flags when setting mtime Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 23/29] smb: client: destroy cfid_put_wq on module exit Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 24/29] net: usb: qmi_wwan: add Telit FE910C04 compositions Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 25/29] Bluetooth: hci_core: Fix sleeping function called from invalid context Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 26/29] irqchip/gic: Correct declaration of *percpu_base pointer in union gic_base Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 27/29] ARC: build: Try to guess GCC variant of cross compiler Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 28/29] bpf: refactor bpf_helper_changes_pkt_data to use helper number Sasha Levin
2024-12-20 17:11 ` [PATCH AUTOSEL 6.12 29/29] bpf: consider that tail calls invalidate packet pointers Sasha Levin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241220171130.511389-8-sashal@kernel.org \
    --to=sashal@kernel.org \
    --cc=josh@joshuagrisham.com \
    --cc=kailang@realtek.com \
    --cc=kovalev@altlinux.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=rf@opensource.cirrus.com \
    --cc=sbinding@opensource.cirrus.com \
    --cc=simont@opensource.cirrus.com \
    --cc=stable@vger.kernel.org \
    --cc=tiwai@suse.com \
    --cc=tiwai@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox