Commit 93693dcf authored by Yong Zhi's avatar Yong Zhi Committed by Mark Brown

ASoC: Intel: boards: rename RTL1019 compatible driver to rt1019p

Use rt1019p for rt1015p.c compatible codec and reserve the name rt1019
for 10EC1019 matched driver in sof_realtek_common.
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 avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20220606204622.144424-3-pierre-louis.bossart@linux.intel.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 11fe58c4
...@@ -463,26 +463,26 @@ EXPORT_SYMBOL_NS(sof_rt1308_dai_link, SND_SOC_INTEL_SOF_REALTEK_COMMON); ...@@ -463,26 +463,26 @@ EXPORT_SYMBOL_NS(sof_rt1308_dai_link, SND_SOC_INTEL_SOF_REALTEK_COMMON);
* 2-amp Configuration for RT1019 * 2-amp Configuration for RT1019
*/ */
static const struct snd_soc_dapm_route rt1019_dapm_routes[] = { static const struct snd_soc_dapm_route rt1019p_dapm_routes[] = {
/* speaker */ /* speaker */
{ "Left Spk", NULL, "Speaker" }, { "Left Spk", NULL, "Speaker" },
{ "Right Spk", NULL, "Speaker" }, { "Right Spk", NULL, "Speaker" },
}; };
static struct snd_soc_dai_link_component rt1019_components[] = { static struct snd_soc_dai_link_component rt1019p_components[] = {
{ {
.name = RT1019_DEV0_NAME, .name = RT1019P_DEV0_NAME,
.dai_name = RT1019_CODEC_DAI, .dai_name = RT1019P_CODEC_DAI,
}, },
}; };
static int rt1019_init(struct snd_soc_pcm_runtime *rtd) static int rt1019p_init(struct snd_soc_pcm_runtime *rtd)
{ {
struct snd_soc_card *card = rtd->card; struct snd_soc_card *card = rtd->card;
int ret; int ret;
ret = snd_soc_dapm_add_routes(&card->dapm, rt1019_dapm_routes, ret = snd_soc_dapm_add_routes(&card->dapm, rt1019p_dapm_routes,
ARRAY_SIZE(rt1019_dapm_routes)); ARRAY_SIZE(rt1019p_dapm_routes));
if (ret) { if (ret) {
dev_err(rtd->dev, "Speaker map addition failed: %d\n", ret); dev_err(rtd->dev, "Speaker map addition failed: %d\n", ret);
return ret; return ret;
...@@ -490,13 +490,13 @@ static int rt1019_init(struct snd_soc_pcm_runtime *rtd) ...@@ -490,13 +490,13 @@ static int rt1019_init(struct snd_soc_pcm_runtime *rtd)
return ret; return ret;
} }
void sof_rt1019_dai_link(struct snd_soc_dai_link *link) void sof_rt1019p_dai_link(struct snd_soc_dai_link *link)
{ {
link->codecs = rt1019_components; link->codecs = rt1019p_components;
link->num_codecs = ARRAY_SIZE(rt1019_components); link->num_codecs = ARRAY_SIZE(rt1019p_components);
link->init = rt1019_init; link->init = rt1019p_init;
} }
EXPORT_SYMBOL_NS(sof_rt1019_dai_link, SND_SOC_INTEL_SOF_REALTEK_COMMON); EXPORT_SYMBOL_NS(sof_rt1019p_dai_link, SND_SOC_INTEL_SOF_REALTEK_COMMON);
MODULE_DESCRIPTION("ASoC Intel SOF Realtek helpers"); MODULE_DESCRIPTION("ASoC Intel SOF Realtek helpers");
MODULE_LICENSE("GPL"); MODULE_LICENSE("GPL");
...@@ -39,9 +39,9 @@ void sof_rt1015_codec_conf(struct snd_soc_card *card); ...@@ -39,9 +39,9 @@ void sof_rt1015_codec_conf(struct snd_soc_card *card);
#define RT1308_DEV0_NAME "i2c-10EC1308:00" #define RT1308_DEV0_NAME "i2c-10EC1308:00"
void sof_rt1308_dai_link(struct snd_soc_dai_link *link); void sof_rt1308_dai_link(struct snd_soc_dai_link *link);
#define RT1019_CODEC_DAI "HiFi" #define RT1019P_CODEC_DAI "HiFi"
#define RT1019_DEV0_NAME "RTL1019:00" #define RT1019P_DEV0_NAME "RTL1019:00"
void sof_rt1019_dai_link(struct snd_soc_dai_link *link); void sof_rt1019p_dai_link(struct snd_soc_dai_link *link);
#endif /* __SOF_REALTEK_COMMON_H */ #endif /* __SOF_REALTEK_COMMON_H */
...@@ -735,7 +735,7 @@ static struct snd_soc_dai_link *sof_card_dai_links_create(struct device *dev, ...@@ -735,7 +735,7 @@ static struct snd_soc_dai_link *sof_card_dai_links_create(struct device *dev,
} else if (sof_rt5682_quirk & SOF_RT1015P_SPEAKER_AMP_PRESENT) { } else if (sof_rt5682_quirk & SOF_RT1015P_SPEAKER_AMP_PRESENT) {
sof_rt1015p_dai_link(&links[id]); sof_rt1015p_dai_link(&links[id]);
} else if (sof_rt5682_quirk & SOF_RT1019_SPEAKER_AMP_PRESENT) { } else if (sof_rt5682_quirk & SOF_RT1019_SPEAKER_AMP_PRESENT) {
sof_rt1019_dai_link(&links[id]); sof_rt1019p_dai_link(&links[id]);
} else if (sof_rt5682_quirk & } else if (sof_rt5682_quirk &
SOF_MAX98373_SPEAKER_AMP_PRESENT) { SOF_MAX98373_SPEAKER_AMP_PRESENT) {
links[id].codecs = max_98373_components; links[id].codecs = max_98373_components;
......
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