ASoC: amd: acp: Make use of existing *_CODEC_DAI macros
authorCristian Ciocaltea <cristian.ciocaltea@collabora.com>
Tue, 19 Dec 2023 03:07:20 +0000 (05:07 +0200)
committerMark Brown <broonie@kernel.org>
Mon, 22 Jan 2024 00:06:25 +0000 (00:06 +0000)
The generic ACP machine driver provides macros for NAU88221 and MAX98388
codec DAI names, but in places it is still using directly the related
strings.

For consistency, replace all strings with the equivalent macros.

Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Link: https://msgid.link/r/20231219030728.2431640-3-cristian.ciocaltea@collabora.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/amd/acp/acp-mach-common.c

index c90ec3419247797a0628bfa5207eaf3afcb8d012..346f7514c81aa9446794086aed7e1f615b7b98e4 100644 (file)
@@ -821,8 +821,8 @@ static const struct snd_soc_ops acp_card_maxim_ops = {
 };
 
 SND_SOC_DAILINK_DEF(max98388,
-                   DAILINK_COMP_ARRAY(COMP_CODEC("i2c-ADS8388:00", "max98388-aif1"),
-                                      COMP_CODEC("i2c-ADS8388:01", "max98388-aif1")));
+                   DAILINK_COMP_ARRAY(COMP_CODEC("i2c-ADS8388:00", MAX98388_CODEC_DAI),
+                                      COMP_CODEC("i2c-ADS8388:01", MAX98388_CODEC_DAI)));
 
 static const struct snd_kcontrol_new max98388_controls[] = {
        SOC_DAPM_PIN_SWITCH("Left Spk"),
@@ -1273,7 +1273,7 @@ static const struct snd_soc_ops acp_8821_ops = {
 
 SND_SOC_DAILINK_DEF(nau8821,
                    DAILINK_COMP_ARRAY(COMP_CODEC("i2c-NVTN2020:00",
-                                                 "nau8821-hifi")));
+                                                 NAU8821_CODEC_DAI)));
 
 /* Declare DMIC codec components */
 SND_SOC_DAILINK_DEF(dmic_codec,