Re: [PATCH RFC v2 2/2] ASoC: amd: acp70: Add rt713 + rt1320 SoundWire machine for LG gram 16Z95U
From: Mukunda,Vijendar
Date: Tue Nov 10 2026 - 21:05:58 EST
On 11/11/26 07:09, fixca wrote:
> [You don't often get email from jaehoon1744@xxxxxxxxxxxxx. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
>
> From: Jaehoon Kim <jaehoon1744@xxxxxxxxxxxxx>
>
> 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@xxxxxxxxxxxxx>
> Co-Authored-By: Claude Opus 5.5 <noreply@xxxxxxxxxxxxx>
Reviewed-by: Vijendar Mukunda <Vijendar.Mukunda@xxxxxxx>
> ---
> 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