mirror of
https://github.com/torvalds/linux.git
synced 2026-05-25 15:41:52 +02:00
ASoC: Intel: soc-acpi-intel-ptl-match: Add rt721 support
Patch adds driver data & match table for rt721 multi-function codec on PTL-RVP at sdw link3. Signed-off-by: Naveen Manohar <naveen.m@intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Liam Girdwood <liam.r.girdwood@intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://patch.msgid.link/20241007075955.12575-4-yung-chuan.liao@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
10488630e1
commit
846a8d3cf3
|
|
@ -69,6 +69,24 @@ static const struct snd_soc_acpi_adr_device rt711_sdca_0_adr[] = {
|
|||
}
|
||||
};
|
||||
|
||||
static const struct snd_soc_acpi_adr_device rt721_3_single_adr[] = {
|
||||
{
|
||||
.adr = 0x000330025d072101ull,
|
||||
.num_endpoints = ARRAY_SIZE(rt_mf_endpoints),
|
||||
.endpoints = rt_mf_endpoints,
|
||||
.name_prefix = "rt721"
|
||||
}
|
||||
};
|
||||
|
||||
static const struct snd_soc_acpi_link_adr ptl_rt721_l3[] = {
|
||||
{
|
||||
.mask = BIT(3),
|
||||
.num_adr = ARRAY_SIZE(rt721_3_single_adr),
|
||||
.adr_d = rt721_3_single_adr,
|
||||
},
|
||||
{},
|
||||
};
|
||||
|
||||
static const struct snd_soc_acpi_adr_device rt722_0_single_adr[] = {
|
||||
{
|
||||
.adr = 0x000030025d072201ull,
|
||||
|
|
@ -159,6 +177,12 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_ptl_sdw_machines[] = {
|
|||
.drv_name = "sof_sdw",
|
||||
.sof_tplg_filename = "sof-ptl-rt711.tplg",
|
||||
},
|
||||
{
|
||||
.link_mask = BIT(3),
|
||||
.links = ptl_rt721_l3,
|
||||
.drv_name = "sof_sdw",
|
||||
.sof_tplg_filename = "sof-ptl-rt721.tplg",
|
||||
},
|
||||
{
|
||||
.link_mask = BIT(0),
|
||||
.links = ptl_rt722_only,
|
||||
|
|
|
|||
|
|
@ -25,6 +25,10 @@ static const struct snd_soc_dapm_route rt712_spk_map[] = {
|
|||
{ "Speaker", NULL, "rt712 SPOR" },
|
||||
};
|
||||
|
||||
static const struct snd_soc_dapm_route rt721_spk_map[] = {
|
||||
{ "Speaker", NULL, "rt721 SPK" },
|
||||
};
|
||||
|
||||
static const struct snd_soc_dapm_route rt722_spk_map[] = {
|
||||
{ "Speaker", NULL, "rt722 SPK" },
|
||||
};
|
||||
|
|
@ -39,6 +43,7 @@ struct codec_route_map {
|
|||
/* Codec route maps array */
|
||||
static const struct codec_route_map codec_routes[] = {
|
||||
{ "rt712", rt712_spk_map, ARRAY_SIZE(rt712_spk_map) },
|
||||
{ "rt721", rt721_spk_map, ARRAY_SIZE(rt721_spk_map) },
|
||||
{ "rt722", rt722_spk_map, ARRAY_SIZE(rt722_spk_map) },
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -60,6 +60,11 @@ static const struct snd_soc_dapm_route rt713_sdca_map[] = {
|
|||
{ "rt713 MIC2", NULL, "Headset Mic" },
|
||||
};
|
||||
|
||||
static const struct snd_soc_dapm_route rt721_sdca_map[] = {
|
||||
{ "Headphone", NULL, "rt721 HP" },
|
||||
{ "rt721 MIC2", NULL, "Headset Mic" },
|
||||
};
|
||||
|
||||
static const struct snd_soc_dapm_route rt722_sdca_map[] = {
|
||||
{ "Headphone", NULL, "rt722 HP" },
|
||||
{ "rt722 MIC2", NULL, "Headset Mic" },
|
||||
|
|
@ -121,6 +126,9 @@ int asoc_sdw_rt_sdca_jack_rtd_init(struct snd_soc_pcm_runtime *rtd, struct snd_s
|
|||
} else if (strstr(component->name_prefix, "rt713")) {
|
||||
ret = snd_soc_dapm_add_routes(&card->dapm, rt713_sdca_map,
|
||||
ARRAY_SIZE(rt713_sdca_map));
|
||||
} else if (strstr(component->name_prefix, "rt721")) {
|
||||
ret = snd_soc_dapm_add_routes(&card->dapm, rt721_sdca_map,
|
||||
ARRAY_SIZE(rt721_sdca_map));
|
||||
} else if (strstr(component->name_prefix, "rt722")) {
|
||||
ret = snd_soc_dapm_add_routes(&card->dapm, rt722_sdca_map,
|
||||
ARRAY_SIZE(rt722_sdca_map));
|
||||
|
|
|
|||
|
|
@ -333,6 +333,47 @@ struct asoc_sdw_codec_info codec_info_list[] = {
|
|||
},
|
||||
.dai_num = 1,
|
||||
},
|
||||
{
|
||||
.part_id = 0x721,
|
||||
.version_id = 3,
|
||||
.dais = {
|
||||
{
|
||||
.direction = {true, true},
|
||||
.dai_name = "rt721-sdca-aif1",
|
||||
.dai_type = SOC_SDW_DAI_TYPE_JACK,
|
||||
.dailink = {SOC_SDW_JACK_OUT_DAI_ID, SOC_SDW_JACK_IN_DAI_ID},
|
||||
.init = asoc_sdw_rt_sdca_jack_init,
|
||||
.exit = asoc_sdw_rt_sdca_jack_exit,
|
||||
.rtd_init = asoc_sdw_rt_sdca_jack_rtd_init,
|
||||
.controls = generic_jack_controls,
|
||||
.num_controls = ARRAY_SIZE(generic_jack_controls),
|
||||
.widgets = generic_jack_widgets,
|
||||
.num_widgets = ARRAY_SIZE(generic_jack_widgets),
|
||||
},
|
||||
{
|
||||
.direction = {true, false},
|
||||
.dai_name = "rt721-sdca-aif2",
|
||||
.dai_type = SOC_SDW_DAI_TYPE_AMP,
|
||||
/* No feedback capability is provided by rt721-sdca codec driver*/
|
||||
.dailink = {SOC_SDW_AMP_OUT_DAI_ID, SOC_SDW_UNUSED_DAI_ID},
|
||||
.init = asoc_sdw_rt_amp_init,
|
||||
.exit = asoc_sdw_rt_amp_exit,
|
||||
.rtd_init = asoc_sdw_rt_mf_sdca_spk_rtd_init,
|
||||
.controls = generic_spk_controls,
|
||||
.num_controls = ARRAY_SIZE(generic_spk_controls),
|
||||
.widgets = generic_spk_widgets,
|
||||
.num_widgets = ARRAY_SIZE(generic_spk_widgets),
|
||||
},
|
||||
{
|
||||
.direction = {false, true},
|
||||
.dai_name = "rt721-sdca-aif3",
|
||||
.dai_type = SOC_SDW_DAI_TYPE_MIC,
|
||||
.dailink = {SOC_SDW_UNUSED_DAI_ID, SOC_SDW_DMIC_DAI_ID},
|
||||
.rtd_init = asoc_sdw_rt_dmic_rtd_init,
|
||||
},
|
||||
},
|
||||
.dai_num = 3,
|
||||
},
|
||||
{
|
||||
.part_id = 0x722,
|
||||
.version_id = 3,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user