summaryrefslogtreecommitdiff
path: root/sound/soc/dwc
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2020-02-17 17:28:15 +0900
committerMark Brown <broonie@kernel.org>2020-02-18 23:37:05 +0000
commit0f6011fd79a2fb92cb80177fd6bdc8aac3a3cd93 (patch)
tree6690859cf756b651bf56948794c15d9fc61cf01c /sound/soc/dwc
parentcae06eb92557f0a073835380e57abee5f8173d73 (diff)
ASoC: soc-pcm: merge playback/cature_active into stream_active
DAI has playback_active and capture_active to care usage count. OTOH, we have SNDRV_PCM_STREAM_PLAYBACK/CAPTURE. But because of this kind of implementation mismatch, ALSA SoC has many verbose code. To solve this issue, this patch merge playback_active/capture_active into stream_active[2]; Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/875zg5botu.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/dwc')
-rw-r--r--sound/soc/dwc/dwc-i2s.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/soc/dwc/dwc-i2s.c b/sound/soc/dwc/dwc-i2s.c
index 7eeca2150b2d..a8bff6f08a69 100644
--- a/sound/soc/dwc/dwc-i2s.c
+++ b/sound/soc/dwc/dwc-i2s.c
@@ -427,9 +427,9 @@ static int dw_i2s_resume(struct snd_soc_component *component)
clk_enable(dev->clk);
for_each_component_dais(component, dai) {
- if (dai->playback_active)
+ if (dai->stream_active[SNDRV_PCM_STREAM_PLAYBACK])
dw_i2s_config(dev, SNDRV_PCM_STREAM_PLAYBACK);
- if (dai->capture_active)
+ if (dai->stream_active[SNDRV_PCM_STREAM_CAPTURE])
dw_i2s_config(dev, SNDRV_PCM_STREAM_CAPTURE);
}