diff options
author | Alex Shi <alex.shi@linaro.org> | 2017-09-24 22:45:01 -0700 |
---|---|---|
committer | Alex Shi <alex.shi@linaro.org> | 2017-09-24 22:45:01 -0700 |
commit | 1cfb9d628fa24c0a8b24cd604ae62dfa10a0d716 (patch) | |
tree | 4e57e7465ce5fbc2a6cc838fd78e5e8a2b9799ff /sound/soc/soc-pcm.c | |
parent | d595150285cf886cf2399fd74b0eeb43b444c706 (diff) | |
parent | 7ecc9777c5c76d7b31c376ffd4f59c4a85472a1b (diff) |
Merge branch 'linux-linaro-lsk-v4.9' into v4.9/topic/ionv4.9/topic/ion
Diffstat (limited to 'sound/soc/soc-pcm.c')
-rw-r--r-- | sound/soc/soc-pcm.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c index d56a16a0f6fa..80088c98ce27 100644 --- a/sound/soc/soc-pcm.c +++ b/sound/soc/soc-pcm.c @@ -181,6 +181,10 @@ int dpcm_dapm_stream_event(struct snd_soc_pcm_runtime *fe, int dir, dev_dbg(be->dev, "ASoC: BE %s event %d dir %d\n", be->dai_link->name, event, dir); + if ((event == SND_SOC_DAPM_STREAM_STOP) && + (be->dpcm[dir].users >= 1)) + continue; + snd_soc_dapm_stream_event(be, dir, event); } @@ -2184,9 +2188,11 @@ static int dpcm_fe_dai_do_trigger(struct snd_pcm_substream *substream, int cmd) break; case SNDRV_PCM_TRIGGER_STOP: case SNDRV_PCM_TRIGGER_SUSPEND: - case SNDRV_PCM_TRIGGER_PAUSE_PUSH: fe->dpcm[stream].state = SND_SOC_DPCM_STATE_STOP; break; + case SNDRV_PCM_TRIGGER_PAUSE_PUSH: + fe->dpcm[stream].state = SND_SOC_DPCM_STATE_PAUSED; + break; } out: |