From: Nicolin Chen Date: Mon, 12 May 2014 12:12:05 +0000 (+0800) Subject: ASoC: pcm: Fix incorrect condition check for case SNDRV_PCM_TRIGGER_SUSPEND X-Git-Tag: v3.15~13^2~8^2^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=868a6ca84ee7e547ae01a5e04e232e4a392c50b8;p=platform%2Fkernel%2Flinux-stable.git ASoC: pcm: Fix incorrect condition check for case SNDRV_PCM_TRIGGER_SUSPEND The regular state before we execute SNDRV_PCM_TRIGGER_SUSPEND should be SNDRV_PCM_TRIGGER_START, not SNDRV_PCM_TRIGGER_STOP. Thus fix it. Signed-off-by: Nicolin Chen Signed-off-by: Mark Brown --- diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c index 2cedf09..a391de0 100644 --- a/sound/soc/soc-pcm.c +++ b/sound/soc/soc-pcm.c @@ -1675,7 +1675,7 @@ int dpcm_be_dai_trigger(struct snd_soc_pcm_runtime *fe, int stream, be->dpcm[stream].state = SND_SOC_DPCM_STATE_STOP; break; case SNDRV_PCM_TRIGGER_SUSPEND: - if (be->dpcm[stream].state != SND_SOC_DPCM_STATE_STOP) + if (be->dpcm[stream].state != SND_SOC_DPCM_STATE_START) continue; if (!snd_soc_dpcm_can_be_free_stop(fe, be, stream))