diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2020-04-24 08:14:48 +0900 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2020-04-29 13:27:36 +0100 |
commit | 0b73ba550cdd95b0fdca5da0040c29ae5d25ae5d (patch) | |
tree | 36bce07a7ac0b237d9b3ae17e21a5e5f5228cf0d /sound/soc/soc-core.c | |
parent | 479914ed779d408273fb3cac4c061dbe695f17cb (diff) | |
download | linux-0b73ba550cdd95b0fdca5da0040c29ae5d25ae5d.tar.bz2 |
ASoC: soc-dai: add snd_soc_pcm_dai_new()
We have 2 type of component functions
snd_soc_dai_xxx() is focusing to dai itself,
snd_soc_pcm_dai_xxx() is focusing to rtd related dai.
Now we can update soc_dai_pcm_new() to
snd_soc_pcm_dai_new(). This patch do it.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Reviewed-By: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Link: https://lore.kernel.org/r/87y2qlssk7.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/soc-core.c')
-rw-r--r-- | sound/soc/soc-core.c | 23 |
1 files changed, 1 insertions, 22 deletions
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 6778eeffb48f..76167fa264af 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -1036,27 +1036,6 @@ _err_defer: } EXPORT_SYMBOL_GPL(snd_soc_add_pcm_runtime); -static int soc_dai_pcm_new(struct snd_soc_pcm_runtime *rtd) -{ - struct snd_soc_dai *dai; - int i, ret = 0; - - for_each_rtd_dais(rtd, i, dai) { - struct snd_soc_dai_driver *drv = dai->driver; - - if (drv->pcm_new) - ret = drv->pcm_new(rtd, dai); - if (ret < 0) { - dev_err(dai->dev, - "ASoC: Failed to bind %s with pcm device\n", - dai->name); - return ret; - } - } - - return 0; -} - static int soc_init_pcm_runtime(struct snd_soc_card *card, struct snd_soc_pcm_runtime *rtd) { @@ -1121,7 +1100,7 @@ static int soc_init_pcm_runtime(struct snd_soc_card *card, return ret; } - return soc_dai_pcm_new(rtd); + return snd_soc_pcm_dai_new(rtd); } static void soc_set_name_prefix(struct snd_soc_card *card, |