Commit 8c8a0f01 authored by Charles Keepax's avatar Charles Keepax Committed by Mark Brown

ASoC: core: Pass legacy_dai_naming flag directly

Passing the result of the helper function snd_soc_component_is_codec
to snd_soc_register_dai is less clear than just passing the DAI
naming flag directly. snd_soc_register_dai wants to know if it
should use the legacy DAI naming. The CODEC distinction is more
of a historical thing and not obviously directly related, and there
are already a couple of CPU side components that explicitly opt in
to non-legacy DAI naming.
Signed-off-by: default avatarCharles Keepax <ckeepax@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20220513090532.1450944-2-ckeepax@opensource.cirrus.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 64c917d1
...@@ -2497,7 +2497,7 @@ static int snd_soc_register_dais(struct snd_soc_component *component, ...@@ -2497,7 +2497,7 @@ static int snd_soc_register_dais(struct snd_soc_component *component,
for (i = 0; i < count; i++) { for (i = 0; i < count; i++) {
dai = snd_soc_register_dai(component, dai_drv + i, count == 1 && dai = snd_soc_register_dai(component, dai_drv + i, count == 1 &&
!snd_soc_component_is_codec(component)); !component->driver->non_legacy_dai_naming);
if (dai == NULL) { if (dai == NULL) {
ret = -ENOMEM; ret = -ENOMEM;
goto err; goto err;
......
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