From: Jeeja KP Date: Mon, 13 Mar 2017 16:41:23 +0000 (+0530) Subject: ASoC: Intel: Skylake: Fix to delete DSP pipe after stopping pipe X-Git-Tag: v4.12-rc1~115^2^2~14^2~42 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=6914968b8203aef72edf936319c4d46c6d46401b;p=karo-tx-linux.git ASoC: Intel: Skylake: Fix to delete DSP pipe after stopping pipe DSP pipe needs to stopped before deleting the pipe. Currently check is for pipe state > STARTED, which is incorrect. So changed to include pipe state STARTED to stop the pipe if it started. Signed-off-by: Jeeja KP Acked-by: Vinod Koul Signed-off-by: Mark Brown --- diff --git a/sound/soc/intel/skylake/skl-messages.c b/sound/soc/intel/skylake/skl-messages.c index e66870474f10..ed576965cacc 100644 --- a/sound/soc/intel/skylake/skl-messages.c +++ b/sound/soc/intel/skylake/skl-messages.c @@ -1098,7 +1098,7 @@ int skl_delete_pipe(struct skl_sst *ctx, struct skl_pipe *pipe) dev_dbg(ctx->dev, "%s: pipe = %d\n", __func__, pipe->ppl_id); /* If pipe is started, do stop the pipe in FW. */ - if (pipe->state > SKL_PIPE_STARTED) { + if (pipe->state >= SKL_PIPE_STARTED) { ret = skl_set_pipe_state(ctx, pipe, PPL_PAUSED); if (ret < 0) { dev_err(ctx->dev, "Failed to stop pipeline\n");