summaryrefslogtreecommitdiff
path: root/sound/soc/soc-compress.c
diff options
context:
space:
mode:
authorCharles Keepax <ckeepax@opensource.wolfsonmicro.com>2013-05-20 08:33:54 +0100
committerMark Brown <broonie@opensource.wolfsonmicro.com>2013-05-20 08:01:48 -0500
commit2c071ed7c3660992951abe4b560359058ce41f68 (patch)
treecc01c98faef23641c0b12f33d0b0bdb90556df92 /sound/soc/soc-compress.c
parentf722406faae2d073cc1d01063d1123c35425939e (diff)
downloadlwn-2c071ed7c3660992951abe4b560359058ce41f68.tar.gz
lwn-2c071ed7c3660992951abe4b560359058ce41f68.zip
ASoC: soc-compress: Send correct stream event for capture start
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/soc-compress.c')
-rw-r--r--sound/soc/soc-compress.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sound/soc/soc-compress.c b/sound/soc/soc-compress.c
index 3853f7eb3f28..06a8000aa07b 100644
--- a/sound/soc/soc-compress.c
+++ b/sound/soc/soc-compress.c
@@ -220,8 +220,12 @@ static int soc_compr_set_params(struct snd_compr_stream *cstream,
goto err;
}
- snd_soc_dapm_stream_event(rtd, SNDRV_PCM_STREAM_PLAYBACK,
- SND_SOC_DAPM_STREAM_START);
+ if (cstream->direction == SND_COMPRESS_PLAYBACK)
+ snd_soc_dapm_stream_event(rtd, SNDRV_PCM_STREAM_PLAYBACK,
+ SND_SOC_DAPM_STREAM_START);
+ else
+ snd_soc_dapm_stream_event(rtd, SNDRV_PCM_STREAM_CAPTURE,
+ SND_SOC_DAPM_STREAM_START);
/* cancel any delayed stream shutdown that is pending */
rtd->pop_wait = 0;