diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2021-04-16 03:59:48 +0200 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2021-04-16 15:34:10 +0200 |
commit | 1cacbac447d9b29a4057d7bbffe8c3d4125ec82a (patch) | |
tree | 8a9d1a6f9221bda4a3b2f90453cd9415fcb06ea5 /sound/soc | |
parent | ASoC: SOF: use current DAI config during resume (diff) | |
download | linux-1cacbac447d9b29a4057d7bbffe8c3d4125ec82a.tar.xz linux-1cacbac447d9b29a4057d7bbffe8c3d4125ec82a.zip |
ASoC: soc-pcm: don't use "name" on __soc_pcm_params_symmetry() macro
__soc_pcm_params_symmetry() macro is using "name" as parameter
which will be exchanged to rate/channles/sample_bit, like below
dai->name => dai->rate
dai->name => dai->channels
dai->name => dai->sample_bit
But, dai itself has "name". This means
1) It is very confusable naming
2) It can't use dai->name
This patch use "xxx" instead of "name"
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/8735vryoob.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/soc-pcm.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c index 02968a4e52b4..a3fc27fc156f 100644 --- a/sound/soc/soc-pcm.c +++ b/sound/soc/soc-pcm.c @@ -386,16 +386,16 @@ static int soc_pcm_params_symmetry(struct snd_pcm_substream *substream, soc_pcm_set_dai_params(&d, params); -#define __soc_pcm_params_symmetry(name) \ - symmetry = rtd->dai_link->symmetric_##name; \ +#define __soc_pcm_params_symmetry(xxx) \ + symmetry = rtd->dai_link->symmetric_##xxx; \ for_each_rtd_dais(rtd, i, dai) \ - symmetry |= dai->driver->symmetric_##name; \ + symmetry |= dai->driver->symmetric_##xxx; \ \ if (symmetry) \ for_each_rtd_cpu_dais(rtd, i, cpu_dai) \ - if (cpu_dai->name && cpu_dai->name != d.name) { \ + if (cpu_dai->xxx && cpu_dai->xxx != d.xxx) { \ dev_err(rtd->dev, "ASoC: unmatched %s symmetry: %d - %d\n", \ - #name, cpu_dai->name, d.name); \ + #xxx, cpu_dai->xxx, d.xxx); \ return -EINVAL; \ } |