Commit 8dcc2059 authored by Yong Zhi's avatar Yong Zhi Committed by Mark Brown

ASoC: Intel: soc-acpi: add MTL AIC SoundWire configurations

Add support to the following daughter card:

SDW0: MX98373 Speaker
SDW2: ALC5682 Headset

Share same driver data used by sof_sdw driver for mtlrvp.
Reviewed-by: default avatarRanjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: default avatarBard Liao <yung-chuan.liao@linux.intel.com>
Signed-off-by: default avatarYong Zhi <yong.zhi@intel.com>
Signed-off-by: default avatarJairaj Arava <jairaj.arava@intel.com>
Signed-off-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20221110225432.144184-6-pierre-louis.bossart@linux.intel.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 97b5fbf4
......@@ -39,6 +39,20 @@ static const struct snd_soc_acpi_endpoint single_endpoint = {
.group_id = 0,
};
static const struct snd_soc_acpi_endpoint spk_l_endpoint = {
.num = 0,
.aggregated = 1,
.group_position = 0,
.group_id = 1,
};
static const struct snd_soc_acpi_endpoint spk_r_endpoint = {
.num = 0,
.aggregated = 1,
.group_position = 1,
.group_id = 1,
};
static const struct snd_soc_acpi_adr_device rt711_sdca_0_adr[] = {
{
.adr = 0x000030025D071101ull,
......@@ -48,6 +62,45 @@ static const struct snd_soc_acpi_adr_device rt711_sdca_0_adr[] = {
}
};
static const struct snd_soc_acpi_adr_device mx8373_0_adr[] = {
{
.adr = 0x000023019F837300ull,
.num_endpoints = 1,
.endpoints = &spk_l_endpoint,
.name_prefix = "Left"
},
{
.adr = 0x000027019F837300ull,
.num_endpoints = 1,
.endpoints = &spk_r_endpoint,
.name_prefix = "Right"
}
};
static const struct snd_soc_acpi_adr_device rt5682_2_adr[] = {
{
.adr = 0x000221025D568200ull,
.num_endpoints = 1,
.endpoints = &single_endpoint,
.name_prefix = "rt5682"
}
};
static const struct snd_soc_acpi_link_adr rt5682_link2_max98373_link0[] = {
/* Expected order: jack -> amp */
{
.mask = BIT(2),
.num_adr = ARRAY_SIZE(rt5682_2_adr),
.adr_d = rt5682_2_adr,
},
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(mx8373_0_adr),
.adr_d = mx8373_0_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr mtl_rvp[] = {
{
.mask = BIT(0),
......@@ -84,6 +137,12 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_mtl_sdw_machines[] = {
.drv_name = "sof_sdw",
.sof_tplg_filename = "sof-mtl-rt711.tplg",
},
{
.link_mask = BIT(0) | BIT(2),
.links = rt5682_link2_max98373_link0,
.drv_name = "sof_sdw",
.sof_tplg_filename = "sof-mtl-sdw-rt5682-l2-max98373-l0.tplg",
},
{},
};
EXPORT_SYMBOL_GPL(snd_soc_acpi_intel_mtl_sdw_machines);
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment