Skip to content

Commit 78cb312

Browse files
charleskeepaxsmb49
authored andcommitted
ASoC: Intel: soc-acpi: lnl: Add match entries for new cs42l43 laptops
BugLink: https://bugs.launchpad.net/bugs/2106394 Add some new match table entries on Lunarlake for some coming cs42l43 laptops. Signed-off-by: Charles Keepax<[email protected]> Reviewed-by: Pierre-Louis Bossart<[email protected]> Signed-off-by: Bard Liao<[email protected]> Link:https://patch.msgid.link/[email protected] Signed-off-by: Mark Brown<[email protected]> (cherry picked from commit 1be6b1c) Signed-off-by: Aaron Ma<[email protected]> Acked-by: Kuba Pawlak <[email protected]> Acked-by: Tim Whisonant <[email protected]> Signed-off-by: Stefan Bader <[email protected]>
1 parent f88ef0d commit 78cb312

File tree

1 file changed

+104
-0
lines changed

1 file changed

+104
-0
lines changed

sound/soc/intel/common/soc-acpi-intel-lnl-match.c

Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,20 @@ static const struct snd_soc_acpi_endpoint spk_r_endpoint = {
3636
.group_id = 1,
3737
};
3838

39+
static const struct snd_soc_acpi_endpoint spk_2_endpoint = {
40+
.num = 0,
41+
.aggregated = 1,
42+
.group_position = 2,
43+
.group_id = 1,
44+
};
45+
46+
static const struct snd_soc_acpi_endpoint spk_3_endpoint = {
47+
.num = 0,
48+
.aggregated = 1,
49+
.group_position = 3,
50+
.group_id = 1,
51+
};
52+
3953
static const struct snd_soc_acpi_endpoint rt712_endpoints[] = {
4054
{
4155
.num = 0,
@@ -103,6 +117,51 @@ static const struct snd_soc_acpi_endpoint cs42l43_endpoints[] = {
103117
},
104118
};
105119

120+
static const struct snd_soc_acpi_adr_device cs35l56_2_l_adr[] = {
121+
{
122+
.adr = 0x00023001FA355601ull,
123+
.num_endpoints = 1,
124+
.endpoints = &spk_l_endpoint,
125+
.name_prefix = "AMP1"
126+
},
127+
{
128+
.adr = 0x00023101FA355601ull,
129+
.num_endpoints = 1,
130+
.endpoints = &spk_2_endpoint,
131+
.name_prefix = "AMP2"
132+
}
133+
};
134+
135+
static const struct snd_soc_acpi_adr_device cs35l56_3_r_adr[] = {
136+
{
137+
.adr = 0x00033201fa355601ull,
138+
.num_endpoints = 1,
139+
.endpoints = &spk_r_endpoint,
140+
.name_prefix = "AMP3"
141+
},
142+
{
143+
.adr = 0x00033301fa355601ull,
144+
.num_endpoints = 1,
145+
.endpoints = &spk_3_endpoint,
146+
.name_prefix = "AMP4"
147+
}
148+
};
149+
150+
static const struct snd_soc_acpi_adr_device cs35l56_3_lr_adr[] = {
151+
{
152+
.adr = 0x00033001fa355601ull,
153+
.num_endpoints = 1,
154+
.endpoints = &spk_l_endpoint,
155+
.name_prefix = "AMP1"
156+
},
157+
{
158+
.adr = 0x00033101fa355601ull,
159+
.num_endpoints = 1,
160+
.endpoints = &spk_r_endpoint,
161+
.name_prefix = "AMP2"
162+
}
163+
};
164+
106165
static const struct snd_soc_acpi_adr_device cs42l43_0_adr[] = {
107166
{
108167
.adr = 0x00003001FA424301ull,
@@ -229,6 +288,39 @@ static const struct snd_soc_acpi_link_adr lnl_cs42l43_l0[] = {
229288
{}
230289
};
231290

291+
static const struct snd_soc_acpi_link_adr lnl_cs42l43_l0_cs35l56_l3[] = {
292+
{
293+
.mask = BIT(0),
294+
.num_adr = ARRAY_SIZE(cs42l43_0_adr),
295+
.adr_d = cs42l43_0_adr,
296+
},
297+
{
298+
.mask = BIT(3),
299+
.num_adr = ARRAY_SIZE(cs35l56_3_lr_adr),
300+
.adr_d = cs35l56_3_lr_adr,
301+
},
302+
{}
303+
};
304+
305+
static const struct snd_soc_acpi_link_adr lnl_cs42l43_l0_cs35l56_l23[] = {
306+
{
307+
.mask = BIT(0),
308+
.num_adr = ARRAY_SIZE(cs42l43_0_adr),
309+
.adr_d = cs42l43_0_adr,
310+
},
311+
{
312+
.mask = BIT(2),
313+
.num_adr = ARRAY_SIZE(cs35l56_2_l_adr),
314+
.adr_d = cs35l56_2_l_adr,
315+
},
316+
{
317+
.mask = BIT(3),
318+
.num_adr = ARRAY_SIZE(cs35l56_3_r_adr),
319+
.adr_d = cs35l56_3_r_adr,
320+
},
321+
{}
322+
};
323+
232324
static const struct snd_soc_acpi_link_adr lnl_rvp[] = {
233325
{
234326
.mask = BIT(0),
@@ -345,6 +437,18 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_lnl_sdw_machines[] = {
345437
.drv_name = "sof_sdw",
346438
.sof_tplg_filename = "sof-lnl-rt711-l0-rt1316-l23-rt714-l1.tplg",
347439
},
440+
{
441+
.link_mask = BIT(0) | BIT(2) | BIT(3),
442+
.links = lnl_cs42l43_l0_cs35l56_l23,
443+
.drv_name = "sof_sdw",
444+
.sof_tplg_filename = "sof-lnl-cs42l43-l0-cs35l56-l23.tplg",
445+
},
446+
{
447+
.link_mask = BIT(0) | BIT(3),
448+
.links = lnl_cs42l43_l0_cs35l56_l3,
449+
.drv_name = "sof_sdw",
450+
.sof_tplg_filename = "sof-lnl-cs42l43-l0-cs35l56-l3.tplg",
451+
},
348452
{
349453
.link_mask = BIT(0),
350454
.links = lnl_cs42l43_l0,

0 commit comments

Comments
 (0)