mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent
@ 2026-11-11  1:39 fixca
  2026-11-11  1:39 ` [PATCH RFC v2 1/2] ASoC: amd: acp: Add ACP70 ACPI flag override for LG gram 16Z95U fixca
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: fixca @ 2026-11-11  1:39 UTC (permalink / raw)
  To: broonie, Vijendar.Mukunda, shumingf; +Cc: linux-sound, linux-kernel

The 2026 LG gram 16 with AMD Ryzen AI 400 (16Z95U, ACP rev 0x72,
PCI SSID 1854:056c) has no internal audio on mainline: no sound card is
created. The same generation 15Z95U has been reported with identical
symptoms (https://github.com/CachyOS/distribution/issues/516).

These two patches create the card. With them, headphone playback and
internal microphone capture work. Speaker playback through the RT1320
is still silent, and I would appreciate advice on that part (details
below). I am sending the series as RFC for that reason.

Changes in v2:
 - Rebased onto broonie/sound for-next; v1 was against v7.2.14 and did
   not apply. No functional change.
 - Patch 2: use a dedicated rt713 jack + DMIC endpoint array; the new
   jack_dmic_endpoints maps the DMIC to endpoint #2 (rt721), whereas
   the rt713 SmartMic DAI is endpoint #1.
 - Cover letter: added what the Windows driver loads for the RT1320.

Hardware, from the ACPI tables (ACP node \_SB.PCI0.GPPA.ACP):

  acp-audio-config-flag = 0x10 (FLAG_AMD_LEGACY_ONLY_DMIC)
  SDWC (_ADR 5): mipi-sdw-manager-list = 0x3
    link 0: SW36 _ADR 0x000030025D071301  RT713
            SDCA functions: UAJ (type 6) at 0x1, SmartMic (type 3) at 0x2
    link 1: SW23 _ADR 0x000131025D132001  RT1320
            SDCA function: SmartAmp (type 1) at 0x4

Patch 1 adds the machine to acp70_acpi_flag_override_table. Without it
snd_pci_ps returns -ENODEV because of the BIOS flag, snd_acp_pci binds
and reports "No matching ASoC machine driver found".

Patch 2 adds rt713 (link 0) + rt1320 (link 1, unique ID 1) entries to
snd_soc_acpi_amd_acp70_sdw_machines[].

Result with both patches (tested on 7.2.14, Arch Linux,
alsa-ucm-conf 1.2.16.1):

  card: amd-soundwire, components " cfg-amp:1 hs:rt713-sdca mic:rt713 spk:rt1320"
  SDW0-PIN0-PLAYBACK-SimpleJack  rt712-sdca-aif1   works
  SDW0-PIN3-CAPTURE-SimpleJack   rt712-sdca-aif1   not tested
  SDW0-PIN5-CAPTURE-SmartMic     rt712-sdca-aif3   works
  SDW1-PIN1-PLAYBACK-SmartAmp    rt1320-aif1       silent

Open problem: RT1320 speaker output is silent

The playback stream starts and runs without any error:

  rt1320-sdca sdw:0:1:025d:1320:01: rt1320_io_init amp func_status=0x41
  rt1320-sdca sdw:0:1:025d:1320:01: rt1320_vc_preset, RT1320_KR0_INT_READY=0x1f
  rt1320-sdca sdw:0:1:025d:1320:01: rt1320_io_init version_id=2, dev_id=0x6981
  rt1320-sdca sdw:0:1:025d:1320:01: rt1320_io_init hw_init complete
  ...
  soundwire sdw-master-0-1: Port=1 hstart=1 hstop=9 port_bo=65 slots=32 max_ports=6
  rt1320-sdca sdw:0:1:025d:1320:01: rt1320_sdw_hw_params rt1320-aif1

What I checked:

 - Mixer: "Speaker Switch" on, "rt1320-1 OT23 L/R Switch" on,
   "rt1320-1 FU21 Playback Volume" 87 (0 dB), "RX Channel Select" L,R.
 - Direct ALSA playback (speaker-test -D plughw:amdsoundwire,2) and
   playback through PipeWire both run to completion with no sound.
 - Runtime PM: forcing power/control=on for the RT1320, so io_init runs
   only once at boot, does not change the result.
 - rt1320-patch-code-vc.bin is installed and loads without error.
 - No DSP firmware is loaded: there is no "realtek,dspfw-name" property,
   and linux-firmware has no realtek/rt1320/rt1320_<vendor>_<product>_<sku>.dat
   or rt1320_RAE_<vendor>_<product>_<sku>.dat for this machine.

On Windows, Realtek's SDCA XU extension driver (RtkSdcaXuLG.inf,
10.0.297.1) binds to this amplifier:

  SOUNDWIRE\SDCA_10&MAN_025D&FUNC_1320&TYPE_01&VER_01&ADR_04&LID_01&UID_01&SUBSYS_056C1854

It ships RTKDAT_1854.dat and RTKDAT_GENERAL.dat and references per-SSID
ALC1320 DSP firmware / preset files (ALC1320\FWFiles.txt,
FWFiles_LG_1854_*.txt, alc1320fw_preset_*\alc1320_afx1_*.dat.bin,
RAE_XU). So on Windows a DSP firmware and RAE preset are loaded for this
amplifier, while on Linux none is.

In addition, the ACPI SmartAmp function carries a 5627-entry
"mipi-sdca-function-initialization-table" that differs from
rt1320_vc_blind_write[] in a number of registers (full list was attached
to v1), for example:

  register   ACPI   driver
  0xc900     0xd0   0x73
  0xc901     0x09   0x04
  0xd471     0xba   0x3a
  0xd479     0x40   0x20
  0xdb08     0xe7   0x7a

Questions:

 1. Shuming: is the missing DSP firmware / RAE preset the reason the
    amplifier stays silent on this design? If so, could Realtek provide
    RT1320 DSP and RAE files for the LG gram 16Z95U (SSID 1854:056c) to
    linux-firmware? I can test them.
 2. Vijendar: is SDW1 / ACP70_SW_AUDIO1_TX the right pin for an
    amplifier on link 1 with ACP rev 0x72, as used by the existing
    rt722 (link 0) + rt1320 (link 1) entry?

I can provide the full acpidump, dmesg and alsa-info output.

Disclosure: the analysis and both patches were prepared with the help of
an AI assistant (Claude); I built and tested them on the hardware.

Thanks,
Jaehoon Kim

body content if you don't wish to send a summary.
From: fixca <jaehoon1744@gmail.com>
To: broonie@kernel.org,Vijendar.Mukunda@amd.com,shumingf@realtek.com
Cc: linux-sound@vger.kernel.org,linux-kernel@vger.kernel.org
Bcc: 
Reply-To: 
Subject: [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent
In-Reply-To: 


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH RFC v2 1/2] ASoC: amd: acp: Add ACP70 ACPI flag override for LG gram 16Z95U
  2026-11-11  1:39 [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent fixca
@ 2026-11-11  1:39 ` fixca
  2026-11-11  1:57   ` Mukunda,Vijendar
  2026-11-11  1:39 ` [PATCH RFC v2 2/2] ASoC: amd: acp70: Add rt713 + rt1320 SoundWire machine " fixca
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 10+ messages in thread
From: fixca @ 2026-11-11  1:39 UTC (permalink / raw)
  To: broonie, Vijendar.Mukunda, shumingf
  Cc: linux-sound, linux-kernel, Jaehoon Kim, Claude Opus 5.5

From: Jaehoon Kim  <jaehoon1744@dankook.ac.kr>

The LG gram 16 (16Z95U, AMD Ryzen AI 400 series, ACP rev 0x72) BIOS
sets "acp-audio-config-flag" to 0x10 (FLAG_AMD_LEGACY_ONLY_DMIC), but
the machine has no ACP PDM microphone. All audio endpoints are
SoundWire peripherals declared under the ACP SoundWire controller:

  link 0: RT713 (UAJ + SmartMic functions), _ADR 0x000030025D071301
  link 1: RT1320 (SmartAmp function),      _ADR 0x000131025D132001

With the flag honoured, snd_pci_ps bails out with -ENODEV, the legacy
snd_acp_pci driver binds instead and fails with:

  platform acp_asoc_acp70.0: warning: No matching ASoC machine driver found

so no sound card is created at all.

Add the machine to acp70_acpi_flag_override_table so that the
SoundWire path is used.

Tested on LG gram 16Z95U-GS59K (PCI SSID 1854:056c): with this change
snd_pci_ps binds and both peripherals enumerate
(sdw:0:0:025d:0713:01, sdw:0:1:025d:1320:01).

Signed-off-by: Jaehoon Kim <jaehoon1744@dankook.ac.kr>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---
v2: rebased onto broonie/sound for-next (v1 did not apply).
 sound/soc/amd/acp-config.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/sound/soc/amd/acp-config.c b/sound/soc/amd/acp-config.c
index 3d4c852..febf559 100644
--- a/sound/soc/amd/acp-config.c
+++ b/sound/soc/amd/acp-config.c
@@ -140,6 +140,13 @@ static const struct dmi_system_id acp70_acpi_flag_override_table[] = {
 			DMI_MATCH(DMI_PRODUCT_NAME, "Dell 14S DS14265"),
 		},
 	},
+	{
+		/* LG gram 16 16Z95U (ACP 7.2) */
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LG Electronics"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "16Z95U"),
+		},
+	},
 	{}
 };
 
-- 
2.43.0


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH RFC v2 2/2] ASoC: amd: acp70: Add rt713 + rt1320 SoundWire machine for LG gram 16Z95U
  2026-11-11  1:39 [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent fixca
  2026-11-11  1:39 ` [PATCH RFC v2 1/2] ASoC: amd: acp: Add ACP70 ACPI flag override for LG gram 16Z95U fixca
@ 2026-11-11  1:39 ` fixca
  2026-11-11  2:05   ` Mukunda,Vijendar
  2026-11-11  1:55 ` [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent Mukunda,Vijendar
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 10+ messages in thread
From: fixca @ 2026-11-11  1:39 UTC (permalink / raw)
  To: broonie, Vijendar.Mukunda, shumingf
  Cc: linux-sound, linux-kernel, Jaehoon Kim, Claude Opus 5.5

From: Jaehoon Kim <jaehoon1744@dankook.ac.kr>

The LG gram 16 (16Z95U) uses an RT713 jack codec on SoundWire link 0
and a single stereo RT1320 amplifier (unique ID 1) on link 1. There is
no matching entry in snd_soc_acpi_amd_acp70_sdw_machines[], so no
machine device is registered even once the SoundWire path is selected.

Add two machine entries:

 - rt713 (jack + DMIC endpoints) on link 0 and rt1320 on link 1, used
   when the RT713 exposes a SmartMic SDCA function (rt712-vb check).
   On this machine the internal microphones are routed through the
   RT713 SmartMic function; the ACP PDM controller is not used.
 - a fallback with only the rt713 jack endpoint and rt1320.

The existing jack_dmic_endpoints cannot be reused: it maps the DMIC to
endpoint #2 for rt721, while on rt713 the SmartMic DAI is the second
DAI, so endpoint #1.

Tested on LG gram 16Z95U-GS59K with kernel 7.2.14. The "amd-soundwire"
card is created with these PCMs:

  SDW0-PIN0-PLAYBACK-SimpleJack  rt712-sdca-aif1
  SDW0-PIN3-CAPTURE-SimpleJack   rt712-sdca-aif1
  SDW0-PIN5-CAPTURE-SmartMic     rt712-sdca-aif3
  SDW1-PIN1-PLAYBACK-SmartAmp    rt1320-aif1

Headphone playback and internal microphone capture work with the
stock alsa-ucm-conf (1.2.16.1) HiFi profile; headset microphone
capture was not tested. Speaker playback through the RT1320 is still
silent although the stream starts without errors; see the cover
letter.

Signed-off-by: Jaehoon Kim <jaehoon1744@dankook.ac.kr>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---
v2: rebased onto broonie/sound for-next (v1 did not apply).
 sound/soc/amd/acp/amd-acp70-acpi-match.c | 83 ++++++++++++++++++++++++
 1 file changed, 83 insertions(+)

diff --git a/sound/soc/amd/acp/amd-acp70-acpi-match.c b/sound/soc/amd/acp/amd-acp70-acpi-match.c
index c2f0479..b492cbe 100644
--- a/sound/soc/amd/acp/amd-acp70-acpi-match.c
+++ b/sound/soc/amd/acp/amd-acp70-acpi-match.c
@@ -583,6 +583,78 @@ static const struct snd_soc_acpi_link_adr acp70_rt722_l0_rt1320_l1[] = {
 	{}
 };
 
+static const struct snd_soc_acpi_endpoint rt713_jack_dmic_endpoints[] = {
+	/* Jack Endpoint (AIF1) */
+	{
+		.num = 0,
+		.aggregated = 0,
+		.group_position = 0,
+		.group_id = 0,
+	},
+	/* DMIC Endpoint (AIF3, SmartMic function) */
+	{
+		.num = 1,
+		.aggregated = 0,
+		.group_position = 0,
+		.group_id = 0,
+	},
+};
+
+static const struct snd_soc_acpi_adr_device rt713_vb_0_single_adr[] = {
+	{
+		.adr = 0x000030025D071301ull,
+		.num_endpoints = ARRAY_SIZE(rt713_jack_dmic_endpoints),
+		.endpoints = rt713_jack_dmic_endpoints,
+		.name_prefix = "rt713"
+	}
+};
+
+static const struct snd_soc_acpi_adr_device rt713_0_single_adr[] = {
+	{
+		.adr = 0x000030025D071301ull,
+		.num_endpoints = 1,
+		.endpoints = &single_endpoint,
+		.name_prefix = "rt713"
+	}
+};
+
+static const struct snd_soc_acpi_adr_device rt1320_1_u1_single_adr[] = {
+	{
+		.adr = 0x000131025D132001ull,
+		.num_endpoints = 1,
+		.endpoints = &single_endpoint,
+		.name_prefix = "rt1320-1"
+	}
+};
+
+static const struct snd_soc_acpi_link_adr acp70_rt713_vb_l0_rt1320_l1u1[] = {
+	{
+		.mask = BIT(0),
+		.num_adr = ARRAY_SIZE(rt713_vb_0_single_adr),
+		.adr_d = rt713_vb_0_single_adr,
+	},
+	{
+		.mask = BIT(1),
+		.num_adr = ARRAY_SIZE(rt1320_1_u1_single_adr),
+		.adr_d = rt1320_1_u1_single_adr,
+	},
+	{}
+};
+
+static const struct snd_soc_acpi_link_adr acp70_rt713_l0_rt1320_l1u1[] = {
+	{
+		.mask = BIT(0),
+		.num_adr = ARRAY_SIZE(rt713_0_single_adr),
+		.adr_d = rt713_0_single_adr,
+	},
+	{
+		.mask = BIT(1),
+		.num_adr = ARRAY_SIZE(rt1320_1_u1_single_adr),
+		.adr_d = rt1320_1_u1_single_adr,
+	},
+	{}
+};
+
 static const struct snd_soc_acpi_adr_device tas2783_2_adr[] = {
 	{
 		/* left */
@@ -820,6 +892,17 @@ struct snd_soc_acpi_mach snd_soc_acpi_amd_acp70_sdw_machines[] = {
 		.links = acp70_rt722_l0_rt1320_l1,
 		.drv_name = "amd_sdw",
 	},
+	{
+		.link_mask = BIT(0) | BIT(1),
+		.links = acp70_rt713_vb_l0_rt1320_l1u1,
+		.machine_check = snd_soc_acpi_amd_sdca_is_device_rt712_vb,
+		.drv_name = "amd_sdw",
+	},
+	{
+		.link_mask = BIT(0) | BIT(1),
+		.links = acp70_rt713_l0_rt1320_l1u1,
+		.drv_name = "amd_sdw",
+	},
 	{
 		.link_mask = BIT(0) | BIT(1),
 		.links = acp70_4_in_1_sdca,
-- 
2.43.0


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent
  2026-11-11  1:39 [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent fixca
  2026-11-11  1:39 ` [PATCH RFC v2 1/2] ASoC: amd: acp: Add ACP70 ACPI flag override for LG gram 16Z95U fixca
  2026-11-11  1:39 ` [PATCH RFC v2 2/2] ASoC: amd: acp70: Add rt713 + rt1320 SoundWire machine " fixca
@ 2026-11-11  1:55 ` Mukunda,Vijendar
  2026-11-11  2:20 ` Mark Brown
  2026-11-12  4:01 ` [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values fixca
  4 siblings, 0 replies; 10+ messages in thread
From: Mukunda,Vijendar @ 2026-11-11  1:55 UTC (permalink / raw)
  To: fixca, broonie, shumingf; +Cc: linux-sound, linux-kernel

On 11/11/26 07:09, fixca wrote:
> [You don't often get email from jaehoon1744@dankook.ac.kr. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
>
> The 2026 LG gram 16 with AMD Ryzen AI 400 (16Z95U, ACP rev 0x72,
> PCI SSID 1854:056c) has no internal audio on mainline: no sound card is
> created. The same generation 15Z95U has been reported with identical
> symptoms (https://github.com/CachyOS/distribution/issues/516).
>
> These two patches create the card. With them, headphone playback and
> internal microphone capture work. Speaker playback through the RT1320
> is still silent, and I would appreciate advice on that part (details
> below). I am sending the series as RFC for that reason.
>
> Changes in v2:
>  - Rebased onto broonie/sound for-next; v1 was against v7.2.14 and did
>    not apply. No functional change.
>  - Patch 2: use a dedicated rt713 jack + DMIC endpoint array; the new
>    jack_dmic_endpoints maps the DMIC to endpoint #2 (rt721), whereas
>    the rt713 SmartMic DAI is endpoint #1.
>  - Cover letter: added what the Windows driver loads for the RT1320.
>
> Hardware, from the ACPI tables (ACP node \_SB.PCI0.GPPA.ACP):
>
>   acp-audio-config-flag = 0x10 (FLAG_AMD_LEGACY_ONLY_DMIC)
>   SDWC (_ADR 5): mipi-sdw-manager-list = 0x3
>     link 0: SW36 _ADR 0x000030025D071301  RT713
>             SDCA functions: UAJ (type 6) at 0x1, SmartMic (type 3) at 0x2
>     link 1: SW23 _ADR 0x000131025D132001  RT1320
>             SDCA function: SmartAmp (type 1) at 0x4
>
> Patch 1 adds the machine to acp70_acpi_flag_override_table. Without it
> snd_pci_ps returns -ENODEV because of the BIOS flag, snd_acp_pci binds
> and reports "No matching ASoC machine driver found".
>
> Patch 2 adds rt713 (link 0) + rt1320 (link 1, unique ID 1) entries to
> snd_soc_acpi_amd_acp70_sdw_machines[].
>
> Result with both patches (tested on 7.2.14, Arch Linux,
> alsa-ucm-conf 1.2.16.1):
>
>   card: amd-soundwire, components " cfg-amp:1 hs:rt713-sdca mic:rt713 spk:rt1320"
>   SDW0-PIN0-PLAYBACK-SimpleJack  rt712-sdca-aif1   works
>   SDW0-PIN3-CAPTURE-SimpleJack   rt712-sdca-aif1   not tested
>   SDW0-PIN5-CAPTURE-SmartMic     rt712-sdca-aif3   works
>   SDW1-PIN1-PLAYBACK-SmartAmp    rt1320-aif1       silent
>
> Open problem: RT1320 speaker output is silent
>
> The playback stream starts and runs without any error:
>
>   rt1320-sdca sdw:0:1:025d:1320:01: rt1320_io_init amp func_status=0x41
>   rt1320-sdca sdw:0:1:025d:1320:01: rt1320_vc_preset, RT1320_KR0_INT_READY=0x1f
>   rt1320-sdca sdw:0:1:025d:1320:01: rt1320_io_init version_id=2, dev_id=0x6981
>   rt1320-sdca sdw:0:1:025d:1320:01: rt1320_io_init hw_init complete
>   ...
>   soundwire sdw-master-0-1: Port=1 hstart=1 hstop=9 port_bo=65 slots=32 max_ports=6
>   rt1320-sdca sdw:0:1:025d:1320:01: rt1320_sdw_hw_params rt1320-aif1
>
> What I checked:
>
>  - Mixer: "Speaker Switch" on, "rt1320-1 OT23 L/R Switch" on,
>    "rt1320-1 FU21 Playback Volume" 87 (0 dB), "RX Channel Select" L,R.
>  - Direct ALSA playback (speaker-test -D plughw:amdsoundwire,2) and
>    playback through PipeWire both run to completion with no sound.
>  - Runtime PM: forcing power/control=on for the RT1320, so io_init runs
>    only once at boot, does not change the result.
>  - rt1320-patch-code-vc.bin is installed and loads without error.
>  - No DSP firmware is loaded: there is no "realtek,dspfw-name" property,
>    and linux-firmware has no realtek/rt1320/rt1320_<vendor>_<product>_<sku>.dat
>    or rt1320_RAE_<vendor>_<product>_<sku>.dat for this machine.
>
> On Windows, Realtek's SDCA XU extension driver (RtkSdcaXuLG.inf,
> 10.0.297.1) binds to this amplifier:
>
>   SOUNDWIRE\SDCA_10&MAN_025D&FUNC_1320&TYPE_01&VER_01&ADR_04&LID_01&UID_01&SUBSYS_056C1854
>
> It ships RTKDAT_1854.dat and RTKDAT_GENERAL.dat and references per-SSID
> ALC1320 DSP firmware / preset files (ALC1320\FWFiles.txt,
> FWFiles_LG_1854_*.txt, alc1320fw_preset_*\alc1320_afx1_*.dat.bin,
> RAE_XU). So on Windows a DSP firmware and RAE preset are loaded for this
> amplifier, while on Linux none is.
>
> In addition, the ACPI SmartAmp function carries a 5627-entry
> "mipi-sdca-function-initialization-table" that differs from
> rt1320_vc_blind_write[] in a number of registers (full list was attached
> to v1), for example:
>
>   register   ACPI   driver
>   0xc900     0xd0   0x73
>   0xc901     0x09   0x04
>   0xd471     0xba   0x3a
>   0xd479     0x40   0x20
>   0xdb08     0xe7   0x7a
>
> Questions:
>
>  1. Shuming: is the missing DSP firmware / RAE preset the reason the
>     amplifier stays silent on this design? If so, could Realtek provide
>     RT1320 DSP and RAE files for the LG gram 16Z95U (SSID 1854:056c) to
>     linux-firmware? I can test them.
>  2. Vijendar: is SDW1 / ACP70_SW_AUDIO1_TX the right pin for an
>     amplifier on link 1 with ACP rev 0x72, as used by the existing
>     rt722 (link 0) + rt1320 (link 1) entry?
Yes, Speaker endpoint should use AUDIO1_TX pin.
>
> I can provide the full acpidump, dmesg and alsa-info output.
>
> Disclosure: the analysis and both patches were prepared with the help of
> an AI assistant (Claude); I built and tested them on the hardware.
>
> Thanks,
> Jaehoon Kim
>
> body content if you don't wish to send a summary.
> From: fixca <jaehoon1744@gmail.com>
> To: broonie@kernel.org,Vijendar.Mukunda@amd.com,shumingf@realtek.com
> Cc: linux-sound@vger.kernel.org,linux-kernel@vger.kernel.org
> Bcc:
> Reply-To:
> Subject: [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent
> In-Reply-To:


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH RFC v2 1/2] ASoC: amd: acp: Add ACP70 ACPI flag override for LG gram 16Z95U
  2026-11-11  1:39 ` [PATCH RFC v2 1/2] ASoC: amd: acp: Add ACP70 ACPI flag override for LG gram 16Z95U fixca
@ 2026-11-11  1:57   ` Mukunda,Vijendar
  0 siblings, 0 replies; 10+ messages in thread
From: Mukunda,Vijendar @ 2026-11-11  1:57 UTC (permalink / raw)
  To: fixca, broonie, shumingf; +Cc: linux-sound, linux-kernel, Claude Opus 5.5

On 11/11/26 07:09, fixca wrote:
> [You don't often get email from jaehoon1744@dankook.ac.kr. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
>
> From: Jaehoon Kim  <jaehoon1744@dankook.ac.kr>
>
> The LG gram 16 (16Z95U, AMD Ryzen AI 400 series, ACP rev 0x72) BIOS
> sets "acp-audio-config-flag" to 0x10 (FLAG_AMD_LEGACY_ONLY_DMIC), but
> the machine has no ACP PDM microphone. All audio endpoints are
> SoundWire peripherals declared under the ACP SoundWire controller:
>
>   link 0: RT713 (UAJ + SmartMic functions), _ADR 0x000030025D071301
>   link 1: RT1320 (SmartAmp function),      _ADR 0x000131025D132001
>
> With the flag honoured, snd_pci_ps bails out with -ENODEV, the legacy
> snd_acp_pci driver binds instead and fails with:
>
>   platform acp_asoc_acp70.0: warning: No matching ASoC machine driver found
>
> so no sound card is created at all.
>
> Add the machine to acp70_acpi_flag_override_table so that the
> SoundWire path is used.
>
> Tested on LG gram 16Z95U-GS59K (PCI SSID 1854:056c): with this change
> snd_pci_ps binds and both peripherals enumerate
> (sdw:0:0:025d:0713:01, sdw:0:1:025d:1320:01).
>
> Signed-off-by: Jaehoon Kim <jaehoon1744@dankook.ac.kr>
> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Reviwed-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com>
> ---
> v2: rebased onto broonie/sound for-next (v1 did not apply).
>  sound/soc/amd/acp-config.c | 7 +++++++
>  1 file changed, 7 insertions(+)
>
> diff --git a/sound/soc/amd/acp-config.c b/sound/soc/amd/acp-config.c
> index 3d4c852..febf559 100644
> --- a/sound/soc/amd/acp-config.c
> +++ b/sound/soc/amd/acp-config.c
> @@ -140,6 +140,13 @@ static const struct dmi_system_id acp70_acpi_flag_override_table[] = {
>                         DMI_MATCH(DMI_PRODUCT_NAME, "Dell 14S DS14265"),
>                 },
>         },
> +       {
> +               /* LG gram 16 16Z95U (ACP 7.2) */
> +               .matches = {
> +                       DMI_MATCH(DMI_SYS_VENDOR, "LG Electronics"),
> +                       DMI_MATCH(DMI_PRODUCT_NAME, "16Z95U"),
> +               },
> +       },
>         {}
>  };
>
> --
> 2.43.0


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH RFC v2 2/2] ASoC: amd: acp70: Add rt713 + rt1320 SoundWire machine for LG gram 16Z95U
  2026-11-11  1:39 ` [PATCH RFC v2 2/2] ASoC: amd: acp70: Add rt713 + rt1320 SoundWire machine " fixca
@ 2026-11-11  2:05   ` Mukunda,Vijendar
  0 siblings, 0 replies; 10+ messages in thread
From: Mukunda,Vijendar @ 2026-11-11  2:05 UTC (permalink / raw)
  To: fixca, broonie, shumingf; +Cc: linux-sound, linux-kernel, Claude Opus 5.5

On 11/11/26 07:09, fixca wrote:
> [You don't often get email from jaehoon1744@dankook.ac.kr. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
>
> From: Jaehoon Kim <jaehoon1744@dankook.ac.kr>
>
> The LG gram 16 (16Z95U) uses an RT713 jack codec on SoundWire link 0
> and a single stereo RT1320 amplifier (unique ID 1) on link 1. There is
> no matching entry in snd_soc_acpi_amd_acp70_sdw_machines[], so no
> machine device is registered even once the SoundWire path is selected.
>
> Add two machine entries:
>
>  - rt713 (jack + DMIC endpoints) on link 0 and rt1320 on link 1, used
>    when the RT713 exposes a SmartMic SDCA function (rt712-vb check).
>    On this machine the internal microphones are routed through the
>    RT713 SmartMic function; the ACP PDM controller is not used.
>  - a fallback with only the rt713 jack endpoint and rt1320.
>
> The existing jack_dmic_endpoints cannot be reused: it maps the DMIC to
> endpoint #2 for rt721, while on rt713 the SmartMic DAI is the second
> DAI, so endpoint #1.
>
> Tested on LG gram 16Z95U-GS59K with kernel 7.2.14. The "amd-soundwire"
> card is created with these PCMs:
>
>   SDW0-PIN0-PLAYBACK-SimpleJack  rt712-sdca-aif1
>   SDW0-PIN3-CAPTURE-SimpleJack   rt712-sdca-aif1
>   SDW0-PIN5-CAPTURE-SmartMic     rt712-sdca-aif3
>   SDW1-PIN1-PLAYBACK-SmartAmp    rt1320-aif1
>
> Headphone playback and internal microphone capture work with the
> stock alsa-ucm-conf (1.2.16.1) HiFi profile; headset microphone
> capture was not tested. Speaker playback through the RT1320 is still
> silent although the stream starts without errors; see the cover
> letter.
>
> Signed-off-by: Jaehoon Kim <jaehoon1744@dankook.ac.kr>
> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Reviewed-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com>
> ---
> v2: rebased onto broonie/sound for-next (v1 did not apply).
>  sound/soc/amd/acp/amd-acp70-acpi-match.c | 83 ++++++++++++++++++++++++
>  1 file changed, 83 insertions(+)
>
> diff --git a/sound/soc/amd/acp/amd-acp70-acpi-match.c b/sound/soc/amd/acp/amd-acp70-acpi-match.c
> index c2f0479..b492cbe 100644
> --- a/sound/soc/amd/acp/amd-acp70-acpi-match.c
> +++ b/sound/soc/amd/acp/amd-acp70-acpi-match.c
> @@ -583,6 +583,78 @@ static const struct snd_soc_acpi_link_adr acp70_rt722_l0_rt1320_l1[] = {
>         {}
>  };
>
> +static const struct snd_soc_acpi_endpoint rt713_jack_dmic_endpoints[] = {
> +       /* Jack Endpoint (AIF1) */
> +       {
> +               .num = 0,
> +               .aggregated = 0,
> +               .group_position = 0,
> +               .group_id = 0,
> +       },
> +       /* DMIC Endpoint (AIF3, SmartMic function) */
> +       {
> +               .num = 1,
> +               .aggregated = 0,
> +               .group_position = 0,
> +               .group_id = 0,
> +       },
> +};
> +
> +static const struct snd_soc_acpi_adr_device rt713_vb_0_single_adr[] = {
> +       {
> +               .adr = 0x000030025D071301ull,
> +               .num_endpoints = ARRAY_SIZE(rt713_jack_dmic_endpoints),
> +               .endpoints = rt713_jack_dmic_endpoints,
> +               .name_prefix = "rt713"
> +       }
> +};
> +
> +static const struct snd_soc_acpi_adr_device rt713_0_single_adr[] = {
> +       {
> +               .adr = 0x000030025D071301ull,
> +               .num_endpoints = 1,
> +               .endpoints = &single_endpoint,
> +               .name_prefix = "rt713"
> +       }
> +};
> +
> +static const struct snd_soc_acpi_adr_device rt1320_1_u1_single_adr[] = {
> +       {
> +               .adr = 0x000131025D132001ull,
> +               .num_endpoints = 1,
> +               .endpoints = &single_endpoint,
> +               .name_prefix = "rt1320-1"
> +       }
> +};
> +
> +static const struct snd_soc_acpi_link_adr acp70_rt713_vb_l0_rt1320_l1u1[] = {
> +       {
> +               .mask = BIT(0),
> +               .num_adr = ARRAY_SIZE(rt713_vb_0_single_adr),
> +               .adr_d = rt713_vb_0_single_adr,
> +       },
> +       {
> +               .mask = BIT(1),
> +               .num_adr = ARRAY_SIZE(rt1320_1_u1_single_adr),
> +               .adr_d = rt1320_1_u1_single_adr,
> +       },
> +       {}
> +};
> +
> +static const struct snd_soc_acpi_link_adr acp70_rt713_l0_rt1320_l1u1[] = {
> +       {
> +               .mask = BIT(0),
> +               .num_adr = ARRAY_SIZE(rt713_0_single_adr),
> +               .adr_d = rt713_0_single_adr,
> +       },
> +       {
> +               .mask = BIT(1),
> +               .num_adr = ARRAY_SIZE(rt1320_1_u1_single_adr),
> +               .adr_d = rt1320_1_u1_single_adr,
> +       },
> +       {}
> +};
> +
>  static const struct snd_soc_acpi_adr_device tas2783_2_adr[] = {
>         {
>                 /* left */
> @@ -820,6 +892,17 @@ struct snd_soc_acpi_mach snd_soc_acpi_amd_acp70_sdw_machines[] = {
>                 .links = acp70_rt722_l0_rt1320_l1,
>                 .drv_name = "amd_sdw",
>         },
> +       {
> +               .link_mask = BIT(0) | BIT(1),
> +               .links = acp70_rt713_vb_l0_rt1320_l1u1,
> +               .machine_check = snd_soc_acpi_amd_sdca_is_device_rt712_vb,
> +               .drv_name = "amd_sdw",
> +       },
> +       {
> +               .link_mask = BIT(0) | BIT(1),
> +               .links = acp70_rt713_l0_rt1320_l1u1,
> +               .drv_name = "amd_sdw",
> +       },
>         {
>                 .link_mask = BIT(0) | BIT(1),
>                 .links = acp70_4_in_1_sdca,
> --
> 2.43.0


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent
  2026-11-11  1:39 [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent fixca
                   ` (2 preceding siblings ...)
  2026-11-11  1:55 ` [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent Mukunda,Vijendar
@ 2026-11-11  2:20 ` Mark Brown
  2026-11-12  4:01 ` [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values fixca
  4 siblings, 0 replies; 10+ messages in thread
From: Mark Brown @ 2026-11-11  2:20 UTC (permalink / raw)
  To: Vijendar.Mukunda, shumingf, fixca; +Cc: linux-sound, linux-kernel

On Wed, 11 Nov 2026 10:39:08 +0900, fixca wrote:
> ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent
> 
> The 2026 LG gram 16 with AMD Ryzen AI 400 (16Z95U, ACP rev 0x72,
> PCI SSID 1854:056c) has no internal audio on mainline: no sound card is
> created. The same generation 15Z95U has been reported with identical
> symptoms (https://github.com/CachyOS/distribution/issues/516).
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-7.4

Thanks!

[1/2] ASoC: amd: acp: Add ACP70 ACPI flag override for LG gram 16Z95U
      https://git.kernel.org/broonie/sound/c/067db578cc2d
[2/2] ASoC: amd: acp70: Add rt713 + rt1320 SoundWire machine for LG gram 16Z95U
      https://git.kernel.org/broonie/sound/c/53094890a821

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values
  2026-11-11  1:39 [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent fixca
                   ` (3 preceding siblings ...)
  2026-11-11  2:20 ` Mark Brown
@ 2026-11-12  4:01 ` fixca
  2026-11-12  4:01   ` [PATCH RFC 1/1] ASoC: rt1320: Use the BIOS init values on LG gram 16Z95U fixca
  2026-11-12  4:46   ` [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values fixca
  4 siblings, 2 replies; 10+ messages in thread
From: fixca @ 2026-11-12  4:01 UTC (permalink / raw)
  To: shumingf
  Cc: broonie, Vijendar.Mukunda, linux-sound, linux-kernel, JaeHoon Kim

From: JaeHoon Kim <jaehoon1744@dankook.ac.kr>

Hi Shuming,

Follow-up on the silent RT1320 speaker on the LG gram 16Z95U (SSID
1854:056c), from the "SoundWire audio for LG gram 16Z95U" thread. Thanks
to Mark for applying the two ACP patches, and to Vijendar for confirming
the AUDIO1_TX pin.

The speakers now work, with one change in the RT1320 driver: using the
values from the BIOS SDCA function initialization table of the SmartAmp
function instead of rt1320_vc_blind_write[].

Results on 7.2.15 (version_id=2, dev_id=0x6981):

  rt1320_vc_blind_write[]     stream runs without errors, silent at 0 dB
  BIOS init values (patch)    speakers work, correct L/R, no distortion

The BIOS table has the same structure as rt1320_vc_blind_write[]. The
differences are listed in the patch description. Two of them stand out:

 - The L/R mapping in 0x1000db15-0x1000db23 is swapped compared to the
   driver, and the swapped (BIOS) mapping gives the correct channels on
   this machine.
 - Several registers are written only by the BIOS table (0xc5c2-0xc5d0,
   0xc050-0xc063, 0xc582, 0xc60b, 0xc682, 0xdc20, 0xcd00, 0xcf02,
   0xce1b-0xce44), and 0xc900/0xc901 and 0xd471/0xd479 have different
   values.

The attached patch is a test patch against v7.2.15, not meant for merging:
it changes about 50 registers at once and I do not know which ones are
required. DSP firmware and RAE files are still not loaded on this
machine, so the speaker protection that Windows sets up (R0 calibration,
EnableAdvanceMode) is not active.

Questions:

 1. Which of these registers does this design actually need? I can
    test a smaller patch, or narrow it down by removing groups of
    registers if that helps.
 2. Would you prefer the driver to apply the BIOS
    "mipi-sdca-function-initialization-table" in general, or a
    per-machine table like in this patch?
 3. Could Realtek provide DSP firmware / RAE files for this machine
    for linux-firmware?

Thanks,
JaeHoon Kim

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH RFC 1/1] ASoC: rt1320: Use the BIOS init values on LG gram 16Z95U
  2026-11-12  4:01 ` [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values fixca
@ 2026-11-12  4:01   ` fixca
  2026-11-12  4:46   ` [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values fixca
  1 sibling, 0 replies; 10+ messages in thread
From: fixca @ 2026-11-12  4:01 UTC (permalink / raw)
  To: shumingf
  Cc: broonie, Vijendar.Mukunda, linux-sound, linux-kernel, JaeHoon Kim

From: JaeHoon Kim <jaehoon1744@dankook.ac.kr>

On the LG gram 16 (16Z95U, AMD ACP 7.2, SSID 1854:056c) the RT1320
speaker amplifier on SoundWire link 1 accepts the playback stream
without any error but stays completely silent with
rt1320_vc_blind_write[], even at 0 dB.

The BIOS describes a board specific "mipi-sdca-function-initialization-table"
for the SmartAmp function (SW23, function 4, 5627 writes). It follows
the same sequence as rt1320_vc_blind_write[] but differs in about 50
registers: clock setup (0xc5c2-0xc5d0), 0xc050-0xc063, 0xc582, 0xc60b,
0xc682, 0xdc20, 0xcd00, 0xcf02, 0xc900/0xc901, 0xce1b-0xce44,
0xd471/0xd479, the L/R mapping in 0x1000db15-0x1000db23 (swapped
compared to the driver) and the final 0xdb00-0xdb1b values.

Use that sequence on this machine, without the table's bulk areas
(0xe000-0xe7ff, 0x10007000-, 0x1000d000-, 0x2000xxxx). The MCU patch is
still loaded from linux-firmware at 0x3fc2bf83, and registers the table
does not touch but rt1320_vc_blind_write[] does are kept.

With this change the internal speakers work: normal music playback at
0 dB amplifier gain and 50% system volume, correct left/right, no
distortion or noticeable heating.

Not intended for merging as is: it changes ~50 registers at once and I
do not know which of them are actually required. DSP firmware / RAE
files are still not loaded on this machine.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: JaeHoon Kim <jaehoon1744@dankook.ac.kr>
---
 sound/soc/codecs/rt1320-sdw.c | 214 +++++++++++++++++++++++++++++++++-
 1 file changed, 210 insertions(+), 4 deletions(-)

diff --git a/sound/soc/codecs/rt1320-sdw.c b/sound/soc/codecs/rt1320-sdw.c
index 42acb6c..14d07c6 100644
--- a/sound/soc/codecs/rt1320-sdw.c
+++ b/sound/soc/codecs/rt1320-sdw.c
@@ -1805,15 +1805,221 @@ static void rt1320_load_dspfw_work(struct work_struct *work)
 	rt1320_dspfw_load_code(rt1320);
 }
 
+/*
+ * LG gram 16 16Z95U: the BIOS provides a board specific SDCA function
+ * initialization table for the RT1320 SmartAmp (SW23 AF04). This is that
+ * table without its bulk RAM/patch areas (0xe000-0xe7ff, 0x10007000-,
+ * 0x1000d000-, 0x2000xxxx); the MCU patch is still loaded from
+ * linux-firmware at 0x3fc2bf83 as in rt1320_vc_blind_write[]. Registers
+ * that the table does not touch but rt1320_vc_blind_write[] does are kept
+ * and marked "drv".
+ */
+static const struct reg_sequence rt1320_vc_lg_16z95u_blind_write[] = {
+	{ 0xc003, 0xe0 },
+	{ 0xe80a, 0x01 },
+	{ 0xc01b, 0xfc },
+	{ 0xc5c3, 0xf2 },
+	{ 0xc5c2, 0x00 },
+	{ 0xc5c6, 0x10 },
+	{ 0xc5c4, 0x12 },
+	{ 0xc5c8, 0x03 },
+	{ 0xc5d8, 0x0a },
+	{ 0xc5d0, 0x09 },
+	{ 0xc5d1, 0x89 },
+	{ 0xdc20, 0x30 },
+	{ 0xc582, 0x01 },
+	{ 0xc60b, 0xb1 },
+	{ 0xc682, 0x60 },
+	{ 0xc057, 0x51 },
+	{ 0xc054, 0x35 },
+	{ 0xc053, 0x55 },
+	{ 0xc052, 0x55 },
+	{ 0xc051, 0x13 },
+	{ 0xc050, 0x15 },
+	{ 0xc060, 0x99 },
+	{ 0xc061, 0x55 },
+	{ 0xc063, 0x55 },
+	{ 0xc065, 0xa5 },
+	{ 0xc06b, 0x0a },
+	{ 0xca05, 0xd6 },
+	{ 0xca07, 0x07 },
+	{ 0xca25, 0xd6 },
+	{ 0xca27, 0x07 },
+	{ 0xcd00, 0x05 },
+	{ 0xcf02, 0x0f },
+	{ 0xc604, 0x40 },
+	{ 0xc609, 0x40 },
+	{ 0xc046, 0xff },
+	{ 0xc045, 0xff },
+	{ 0xc044, 0xff },
+	{ 0xc043, 0xff },
+	{ 0xc042, 0xff },
+	{ 0xc041, 0x7f },
+	{ 0xc040, 0xff },
+	{ 0xcc10, 0x01 },
+	{ 0xc700, 0xf0 },
+	{ 0xc701, 0x13 },
+	{ 0xc901, 0x09 },
+	{ 0xc900, 0xd0 },
+	{ 0xce44, 0x1c },
+	{ 0xce1b, 0x88 },
+	{ 0xce31, 0x0d },
+	{ 0xce30, 0xae },
+	{ 0xce37, 0x0b },
+	{ 0xce36, 0xd2 },
+	{ 0xce39, 0x04 },
+	{ 0xce38, 0x80 },
+	{ 0xce3f, 0x00 },
+	{ 0xce3e, 0x00 },
+	{ 0xde03, 0x05 },
+	{ 0xc570, 0x08 },
+	{ 0xc086, 0x02 },
+	{ 0xc085, 0x7f },
+	{ 0xc084, 0x00 },
+	{ 0xc081, 0xfe },
+	{ 0xf084, 0x0f },
+	{ 0xf083, 0xff },
+	{ 0xf082, 0xff },
+	{ 0xf081, 0xff },
+	{ 0xf080, 0xff },
+	{ 0xe801, 0x01 },
+	{ 0xe802, 0xf8 },
+	{ 0xe803, 0xbe },
+	{ 0xc003, 0xc0 },
+	{ 0xd470, 0xec },
+	{ 0xd471, 0xba },
+	{ 0xd474, 0x11 },
+	{ 0xd475, 0x32 },
+	{ 0xd478, 0xff },
+	{ 0xd479, 0x40 },
+	{ 0xd47a, 0x10 },
+	{ 0xd47c, 0xff },	/* drv */
+	{ 0xc019, 0x10 },
+	{ 0xd487, 0x0b },
+	{ 0xd487, 0x3b },
+	{ 0xd486, 0xc3 },
+	{ 0xc598, 0x04 },	/* drv */
+	{ 0xd500, 0x00 },	/* drv */
+	{ 0xd500, 0x17 },	/* drv */
+	{ 0xd600, 0x01 },	/* drv */
+	{ 0xd601, 0x02 },	/* drv */
+	{ 0xd602, 0x03 },	/* drv */
+	{ 0xd603, 0x04 },	/* drv */
+	{ 0xd64c, 0x03 },	/* drv */
+	{ 0xd64d, 0x03 },	/* drv */
+	{ 0xd64e, 0x03 },	/* drv */
+	{ 0xd64f, 0x03 },	/* drv */
+	{ 0xd650, 0x03 },	/* drv */
+	{ 0xd651, 0x03 },	/* drv */
+	{ 0xd652, 0x03 },	/* drv */
+	{ 0xd610, 0x01 },	/* drv */
+	{ 0xd608, 0x03 },	/* drv */
+	{ 0xd609, 0x00 },	/* drv */
+	{ 0x3fc2bf83, 0x00 },
+	{ 0x3fc2bf82, 0x00 },
+	{ 0x3fc2bf81, 0x00 },
+	{ 0x3fc2bf80, 0x00 },
+	{ 0x3fc2bfc7, 0x00 },
+	{ 0x3fc2bfc6, 0x00 },
+	{ 0x3fc2bfc5, 0x00 },
+	{ 0x3fc2bfc4, 0x00 },
+	{ 0x3fc2bfc3, 0x00 },
+	{ 0x3fc2bfc2, 0x00 },
+	{ 0x3fc2bfc1, 0x00 },
+	{ 0x3fc2bfc0, 0x07 },
+	{ 0x1000cc46, 0x00 },
+	{ 0xd486, 0x43 },
+	{ 0x1000db00, 0x07 },
+	{ 0x1000db01, 0x00 },
+	{ 0x1000db02, 0x11 },
+	{ 0x1000db03, 0x00 },
+	{ 0x1000db04, 0x00 },
+	{ 0x1000db05, 0x82 },
+	{ 0x1000db06, 0x04 },
+	{ 0x1000db07, 0xf1 },
+	{ 0x1000db08, 0x00 },
+	{ 0x1000db09, 0x00 },
+	{ 0x1000db0a, 0x40 },
+	{ 0x1000db0b, 0x02 },
+	{ 0x1000db0c, 0xf2 },
+	{ 0x1000db0d, 0x00 },
+	{ 0x1000db0e, 0x00 },
+	{ 0x1000db0f, 0xe0 },
+	{ 0x1000db10, 0x00 },
+	{ 0x1000db11, 0x10 },
+	{ 0x1000db12, 0x00 },
+	{ 0x1000db13, 0x00 },
+	{ 0x1000db14, 0x45 },
+	{ 0x1000db15, 0x12 },
+	{ 0x1000db16, 0x09 },
+	{ 0x1000db17, 0x00 },
+	{ 0x1000db18, 0x00 },
+	{ 0x1000db19, 0x00 },
+	{ 0x1000db1a, 0x13 },
+	{ 0x1000db1b, 0x09 },
+	{ 0x1000db1c, 0x00 },
+	{ 0x1000db1d, 0x00 },
+	{ 0x1000db1e, 0x00 },
+	{ 0x1000db1f, 0x0d },
+	{ 0x1000db20, 0x01 },
+	{ 0x1000db21, 0x00 },
+	{ 0x1000db22, 0x00 },
+	{ 0x1000db23, 0xbf },
+	{ 0xd540, 0x21 },
+	{ 0xc5c3, 0xf2 },
+	{ 0xc5c8, 0x03 },
+	{ 0xd471, 0xba },
+	{ 0xdd0b, 0x0d },
+	{ 0xdd0a, 0xff },
+	{ 0xdd09, 0x0d },
+	{ 0xdd08, 0xff },
+	{ 0xdb03, 0xf0 },
+	{ 0xdb08, 0xe7 },
+	{ 0xdb09, 0x00 },
+	{ 0xdb19, 0x02 },
+	{ 0xdb02, 0x73 },
+	{ 0xdb01, 0x00 },
+	{ 0xdb04, 0x00 },
+	{ 0xdb07, 0x00 },
+	{ 0xdb00, 0x00 },
+	{ 0xdb05, 0x00 },
+	{ 0xdb06, 0x00 },
+	{ 0xdb1a, 0x00 },
+	{ 0xdb1b, 0x00 },
+	{ 0xc5f7, 0x22 },	/* drv */
+	{ 0xc5f6, 0x22 },	/* drv */
+	{ 0xd172, 0x2a },	/* drv */
+	{ 0xc5d6, 0x01 },	/* drv */
+};
+
+static const struct dmi_system_id rt1320_lg_16z95u_dmi[] = {
+	{
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LG Electronics"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "16Z95U"),
+		},
+	},
+	{}
+};
+
 static void rt1320_vc_preset(struct rt1320_sdw_priv *rt1320)
 {
 	struct sdw_slave *slave = rt1320->sdw_slave;
+	const struct reg_sequence *seq = rt1320_vc_blind_write;
+	unsigned int num = ARRAY_SIZE(rt1320_vc_blind_write);
 	unsigned int i, reg, val, delay, retry, tmp;
 
-	for (i = 0; i < ARRAY_SIZE(rt1320_vc_blind_write); i++) {
-		reg = rt1320_vc_blind_write[i].reg;
-		val = rt1320_vc_blind_write[i].def;
-		delay = rt1320_vc_blind_write[i].delay_us;
+	if (dmi_check_system(rt1320_lg_16z95u_dmi)) {
+		seq = rt1320_vc_lg_16z95u_blind_write;
+		num = ARRAY_SIZE(rt1320_vc_lg_16z95u_blind_write);
+		dev_info(&slave->dev, "%s: using LG 16Z95U init sequence (%u writes)\n",
+			 __func__, num);
+	}
+
+	for (i = 0; i < num; i++) {
+		reg = seq[i].reg;
+		val = seq[i].def;
+		delay = seq[i].delay_us;
 
 		if (reg == 0x3fc2bf83)
 			rt1320_load_mcu_patch(rt1320);
-- 
2.43.0


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values
  2026-11-12  4:01 ` [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values fixca
  2026-11-12  4:01   ` [PATCH RFC 1/1] ASoC: rt1320: Use the BIOS init values on LG gram 16Z95U fixca
@ 2026-11-12  4:46   ` fixca
  1 sibling, 0 replies; 10+ messages in thread
From: fixca @ 2026-11-12  4:46 UTC (permalink / raw)
  To: shumingf
  Cc: broonie, Vijendar.Mukunda, linux-sound, linux-kernel, JaeHoon Kim

From: JaeHoon Kim <jaehoon1744@dankook.ac.kr>

Hi Shuming,

Please disregard this RFC. The BIOS init values are not needed: the
stock rt1320 driver works on this machine.

While narrowing the register groups down (after the Sashiko review,
which correctly pointed out that my table dropped the two PDE23 entries
and that 0x1000db15-0x1000db23 is the same command list in a different
order, not an L/R swap), the baseline with no BIOS values also played
sound. I then retested the unmodified v7.2.15 rt1320 driver, with only
the two ACP patches Mark applied, in three boot scenarios:

  boot                                   amp func_status   speaker
  cold boot (power fully removed)        0x61              works
  warm reboot Linux -> Linux             0x41              works
  Windows (speaker used) -> warm reboot  0x43              works

v7.2.15 has no audio related changes compared to v7.2.14, so I cannot
explain the silence I saw earlier on v7.2.14. It is no longer
reproducible; it may have been a stale amplifier state left over from
my earlier experiments. Once (also no longer reproducible) the RT1320
read back 0x81 for every register after a warm reboot, which only a
full power removal cleared. I will report back if either problem shows
up again.

The remaining open point is the one from before: no DSP firmware / RAE
files are loaded for this machine, so the speaker protection set up on
Windows is not active on Linux. If Realtek can provide those files for
the LG gram 16Z95U (SSID 1854:056c), I am happy to test them.

Sorry for the noise.

Thanks,
JaeHoon Kim

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2026-11-12  4:46 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-11  1:39 [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent fixca
2026-11-11  1:39 ` [PATCH RFC v2 1/2] ASoC: amd: acp: Add ACP70 ACPI flag override for LG gram 16Z95U fixca
2026-11-11  1:57   ` Mukunda,Vijendar
2026-11-11  1:39 ` [PATCH RFC v2 2/2] ASoC: amd: acp70: Add rt713 + rt1320 SoundWire machine " fixca
2026-11-11  2:05   ` Mukunda,Vijendar
2026-11-11  1:55 ` [PATCH RFC v2 0/2] ASoC: amd: SoundWire audio for LG gram 16Z95U (rt713 + rt1320), speaker still silent Mukunda,Vijendar
2026-11-11  2:20 ` Mark Brown
2026-11-12  4:01 ` [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values fixca
2026-11-12  4:01   ` [PATCH RFC 1/1] ASoC: rt1320: Use the BIOS init values on LG gram 16Z95U fixca
2026-11-12  4:46   ` [PATCH RFC 0/1] ASoC: rt1320: LG gram 16Z95U speaker works with the BIOS init values fixca

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®