summaryrefslogtreecommitdiffstats
path: root/sound/soc/soc-core.c
diff options
context:
space:
mode:
authorKuninori Morimoto2018-05-08 05:23:01 +0200
committerMark Brown2018-05-09 11:40:09 +0200
commit0e7b25c673ec916dee8d927fc8de5806d900cba8 (patch)
tree6afebc2a5ddea7bb332d02da2aa7d41f52ad4c76 /sound/soc/soc-core.c
parentASoC: soc-core: remove snd_soc_component_add_unlocked() (diff)
downloadkernel-qcow2-linux-0e7b25c673ec916dee8d927fc8de5806d900cba8.tar.gz
kernel-qcow2-linux-0e7b25c673ec916dee8d927fc8de5806d900cba8.tar.xz
kernel-qcow2-linux-0e7b25c673ec916dee8d927fc8de5806d900cba8.zip
ASoC: soc-core: remove legacy_dai_naming from snd_soc_register_dais()
We can get legacy dai name flag from component driver. Thus, there is no need to have its parameter on snd_soc_register_dais(). Let's remove unneeded parameter Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/soc-core.c')
-rw-r--r--sound/soc/soc-core.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c
index 2d3abb3f1231..3d56f1fe5914 100644
--- a/sound/soc/soc-core.c
+++ b/sound/soc/soc-core.c
@@ -2783,8 +2783,7 @@ static struct snd_soc_dai *soc_add_dai(struct snd_soc_component *component,
* parent's name.
*/
static int snd_soc_register_dais(struct snd_soc_component *component,
- struct snd_soc_dai_driver *dai_drv, size_t count,
- bool legacy_dai_naming)
+ struct snd_soc_dai_driver *dai_drv, size_t count)
{
struct device *dev = component->dev;
struct snd_soc_dai *dai;
@@ -2796,7 +2795,7 @@ static int snd_soc_register_dais(struct snd_soc_component *component,
for (i = 0; i < count; i++) {
dai = soc_add_dai(component, dai_drv + i,
- count == 1 && legacy_dai_naming);
+ count == 1 && !component->driver->non_legacy_dai_naming);
if (dai == NULL) {
ret = -ENOMEM;
goto err;
@@ -3046,8 +3045,7 @@ int snd_soc_add_component(struct device *dev,
}
}
- ret = snd_soc_register_dais(component, dai_drv, num_dai,
- !component_driver->non_legacy_dai_naming);
+ ret = snd_soc_register_dais(component, dai_drv, num_dai);
if (ret < 0) {
dev_err(dev, "ASoC: Failed to register DAIs: %d\n", ret);
goto err_cleanup;