Skip to contentSkip to conversation

ALSA: hda/realtek: Sort Ally X properly, fix Asus Z13 2025 audio

PATCH Superseded Antheas Kapenekakis 2 participants 7 messages Feb 24, 2025 Sound

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

cover ALSA: hda/realtek: Sort Ally X properly, fix Asus Z13 2025 audio

The Ally X has two quirks in the kernel currently. This is due to the previous quirk not being sorted properly, whoopsies. Therefore, only one has to stay. During AB testing, I found that the Lenovo quirk makes a popping sound during boot. Therefore the better quirk is the previous one.

This also mirrors our initial testing last August, where creating that custom quirk fixed the popping sound over re-using the existing Lenovo TAS quirk.

Then, add the Asus Z13 2025 quirk to the list. When looking into its dsdt file, it was found to be identical to the original Ally. Therefore, borrow its quirk. After using the quirk, sound works properly. However, the kernel loads the default firmware for it, resulting in subpar sound quality.

After looking into the Windows driver files, the following files were identified to be the correct ones for it:

Playback_6.83.0/Firmware/CS35L41/RevB2/halo_cspl_RAM_revB2_29.85.0.wmfw tunings/ASUS_GZ302EA_10431FB3_241018/10431FB3_241018_V01_A0.bin tunings/ASUS_GZ302EA_10431FB3_241018/10431FB3_241018_V01_A0_cal.bin tunings/ASUS_GZ302EA_10431FB3_241018/10431FB3_241018_V01_A1.bin tunings/ASUS_GZ302EA_10431FB3_241018/10431FB3_241018_V01_A1_cal.bin

Which the kernel expects to be named as:

cirrus/cs35l41-dsp1-spk-prot-10431fb3.wmfw
cirrus/cs35l41-dsp1-spk-prot-10431fb3-r0.bin
cirrus/cs35l41-dsp1-spk-prot-10431fb3-l0.bin
cirrus/cs35l41-dsp1-spk-cali-10431fb3-r0.bin
cirrus/cs35l41-dsp1-spk-cali-10431fb3-l0.bin

where A0 corresponds to r0.

Therefore, +cc Simon Trimmer who often uploads firmware for these devices.

Antheas Kapenekakis (2):
ALSA: hda/realtek: Remove dup Ally X config
ALSA: hda/realtek: Fix Asus Z13 2025 audio

 sound/pci/hda/patch_realtek.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
Signature · 1 line
2.48.1
#1 lore raw

PATCH 1/2 ALSA: hda/realtek: Remove dup Ally X config

In commit 1e9c708dc3ae ("ALSA: hda/tas2781: Add new quirk for Lenovo, ASUS, Dell projects") Baojun adds a bunch of projects to the file, including for the Ally X. Turns out the initial Ally X was not sorted properly, so the kernel had 2 quirks for it.

The previous quirk overrode the new one due to being earlier and they are different. When AB testing, it was found that the Ally X makes a popping sound during boot when using the (new) Lenovo quirk.

Therefore, keep using the previous custom quirk for the Ally X and sort it properly, replacing the one added by Baojun.

---
 sound/pci/hda/patch_realtek.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
sound/pci/hda/patch_realtek.c +1 -2
index 224616fbec4f..1771e3b5618d 100644
@@ -10644,7 +10644,6 @@ static const struct hda_quirk alc269_fixup_tbl[] = {
 	SND_PCI_QUIRK(0x1043, 0x1740, "ASUS UX430UA", ALC295_FIXUP_ASUS_DACS),
 	SND_PCI_QUIRK(0x1043, 0x17d1, "ASUS UX431FL", ALC294_FIXUP_ASUS_DUAL_SPK),
 	SND_PCI_QUIRK(0x1043, 0x17f3, "ROG Ally NR2301L/X", ALC294_FIXUP_ASUS_ALLY),
-	SND_PCI_QUIRK(0x1043, 0x1eb3, "ROG Ally X RC72LA", ALC294_FIXUP_ASUS_ALLY_X),
 	SND_PCI_QUIRK(0x1043, 0x1863, "ASUS UX6404VI/VV", ALC245_FIXUP_CS35L41_SPI_2),
 	SND_PCI_QUIRK(0x1043, 0x1881, "ASUS Zephyrus S/M", ALC294_FIXUP_ASUS_GX502_PINS),
 	SND_PCI_QUIRK(0x1043, 0x18b1, "Asus MJ401TA", ALC256_FIXUP_ASUS_HEADSET_MIC),
@@ -10691,7 +10690,7 @@ static const struct hda_quirk alc269_fixup_tbl[] = {
 	SND_PCI_QUIRK(0x1043, 0x1e63, "ASUS H7606W", ALC285_FIXUP_ASUS_GU605_SPI_SPEAKER2_TO_DAC1),
 	SND_PCI_QUIRK(0x1043, 0x1e83, "ASUS GA605W", ALC285_FIXUP_ASUS_GU605_SPI_SPEAKER2_TO_DAC1),
 	SND_PCI_QUIRK(0x1043, 0x1e8e, "ASUS Zephyrus G15", ALC289_FIXUP_ASUS_GA401),
-	SND_PCI_QUIRK(0x1043, 0x1eb3, "ASUS Ally RCLA72", ALC287_FIXUP_TAS2781_I2C),
+	SND_PCI_QUIRK(0x1043, 0x1eb3, "ROG Ally X RC72LA", ALC294_FIXUP_ASUS_ALLY_X),
 	SND_PCI_QUIRK(0x1043, 0x1ed3, "ASUS HN7306W", ALC287_FIXUP_CS35L41_I2C_2),
 	SND_PCI_QUIRK(0x1043, 0x1ee2, "ASUS UM6702RA/RC", ALC287_FIXUP_CS35L41_I2C_2),
 	SND_PCI_QUIRK(0x1043, 0x1c52, "ASUS Zephyrus G15 2022", ALC289_FIXUP_ASUS_GA401),
Signature · 1 line
2.48.1
#2 lore raw

PATCH 2/2 ALSA: hda/realtek: Fix Asus Z13 2025 audio

In reply to Antheas Kapenekakis

dsdt entry is the same as the original Ally, so borrow its quirks. Sound works in both speakers, headphones, and microphone. Whereas none worked before.

---
 sound/pci/hda/patch_realtek.c | 1 +
 1 file changed, 1 insertion(+)
sound/pci/hda/patch_realtek.c +1 -0
index 1771e3b5618d..62c77db73df9 100644
@@ -10699,6 +10699,7 @@ static const struct hda_quirk alc269_fixup_tbl[] = {
 	SND_PCI_QUIRK(0x1043, 0x1f1f, "ASUS H7604JI/JV/J3D", ALC245_FIXUP_CS35L41_SPI_2),
 	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, 0x1fb3, "ASUS ROG Flow Z13 GZ302EA", ALC294_FIXUP_ASUS_ALLY),
 	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),
Signature · 1 line
2.48.1
#3 lore raw

RE: [PATCH 2/2] ALSA: hda/realtek: Fix Asus Z13 2025 audio

Hi,

Quoted 9 lines

-----Original Message-----
From: Antheas Kapenekakis <[email protected]>
Sent: Monday, February 24, 2025 4:10 PM
To: [email protected]; [email protected]
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Antheas Kapenekakis <[email protected]>; Kyle Gospodnetich <[email protected]>
Subject: [PATCH 2/2] ALSA: hda/realtek: Fix Asus Z13 2025 audio

Quoted 3 lines

dsdt entry is the same as the original Ally, so borrow its quirks. Sound works in both speakers, headphones, and microphone. Whereas none worked before.

This laptop is in the list of laptops that I was planning to upstream, but I am currently waiting on testing for this generation of laptops. The Ally fixups do some extra stuff in the Realtek driver, which may or may not apply to this laptop. I believe the minimum fixup required for this laptop is ALC287_FIXUP_CS35L41_I2C_2, but I don't have the laptop to test that.
If possible, could you provide an acpidump of this system, so I can compare against what I have?

It would be better to wait until we have tested this generation of laptops, after which I can upstream the kernel patches to support them, as well as the firmware.

Thanks,
Stefan

sound/pci/hda/patch_realtek.c static const struct hda_quirk alc269_fixup_tbl[] =

Quoted 12 lines
---
 sound/pci/hda/patch_realtek.c | 1 +
 1 file changed, 1 insertion(+)
sound/pci/hda/patch_realtek.c +0 -0
index 1771e3b5618d..62c77db73df9 100644
@@ -10699,6 +10699,7 @@ static const struct hda_quirk alc269_fixup_tbl[] =

{

Quoted 17 lines
sound/pci/hda/patch_realtek.c +2 -0
 	SND_PCI_QUIRK(0x1043, 0x1f1f, "ASUS H7604JI/JV/J3D",
 ALC245_FIXUP_CS35L41_SPI_2),
 	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, 0x1fb3, "ASUS ROG Flow Z13 GZ302EA",
+ALC294_FIXUP_ASUS_ALLY),
 	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),
--
2.48.1

#5 lore raw

Re: [PATCH 2/2] ALSA: hda/realtek: Fix Asus Z13 2025 audio

You are indeed right Stefan, during grepping i got 16 results for ALC294_FIXUP_ASUS_ALLY so I thought it was used more.

My mistake. I can also try the base 2c fixup

Antheas

Quoted 11 lines · Antheas Kapenekakis

Hi Stefan,

Quoted 2 lines

If possible, could you provide an acpidump of this system, so I can compare against what I have?

sure, see [1]

Antheas

[1] https://github.com/hhd-dev/hwinfo/blob/5bb16fa59f533e036e430016f2c85facd0325f5a/devices/Asus%20Z13%202025/decoded/dsdt.dsl

#6 lore raw

Re: [PATCH 2/2] ALSA: hda/realtek: Fix Asus Z13 2025 audio

Sounds about the same, perhaps a bit better. I'll swap to that one for our use and for when/if there is a V2.

Any tips about going through this stuff are well appreciated. Online documentation is very sparse

On that note, what's the timeline for adding support to these laptops?

And speaking of a V2, the Ally X quirk is a bit suspect. Yes it fixes the popping during boot, but which part of it does that? It is very long and touches a different amp quirk in the process I'd say, so it would be nice to clean up. Let's forget about the original Ally, but the Ally X is still relevant.

Of course, I do not expect an answer from you Stefan, as it is a competitor amp, haha. This is mostly for Baojun et al.

Best,
Antheas