aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/soc-pcm.c
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2020-06-04 17:07:11 +0900
committerMark Brown <broonie@kernel.org>2020-06-15 18:21:23 +0100
commite1bafa828e3a0622ac24d238e00937f3059ed585 (patch)
treeea076ae60369bd946ffccaba9b11726eacd0f7b5 /sound/soc/soc-pcm.c
parentASoC: soc-component: add snd_soc_pcm_component_prepare() (diff)
downloadlinux-dev-e1bafa828e3a0622ac24d238e00937f3059ed585.tar.xz
linux-dev-e1bafa828e3a0622ac24d238e00937f3059ed585.zip
ASoC: soc-component: add snd_soc_pcm_component_hw_params()
We have 2 type of component functions snd_soc_component_xxx() is focusing to component itself, snd_soc_pcm_component_xxx() is focusing to rtd related component. Now we can update snd_soc_component_hw_params() to snd_soc_pcm_component_hw_params(). 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/87mu5jw8y8.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/soc-pcm.c')
-rw-r--r--sound/soc/soc-pcm.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c
index 8ba0f14a2f2f..e5eef48af167 100644
--- a/sound/soc/soc-pcm.c
+++ b/sound/soc/soc-pcm.c
@@ -1009,16 +1009,9 @@ static int soc_pcm_hw_params(struct snd_pcm_substream *substream,
snd_soc_dapm_update_dai(substream, params, cpu_dai);
}
- for_each_rtd_components(rtd, i, component) {
- ret = snd_soc_component_hw_params(component, substream, params);
- if (ret < 0) {
- dev_err(component->dev,
- "ASoC: %s hw params failed: %d\n",
- component->name, ret);
- goto component_err;
- }
- }
- component = NULL;
+ ret = snd_soc_pcm_component_hw_params(substream, params, &component);
+ if (ret < 0)
+ goto component_err;
out:
mutex_unlock(&rtd->card->pcm_mutex);