ASoC: Intel: Skylake: Prevent sending Set DMA Control IPC if the widget is "On"
authorDharageswari.R <dharageswari.r@intel.com>
Thu, 28 Apr 2016 13:15:27 +0000 (18:45 +0530)
committerMark Brown <broonie@kernel.org>
Mon, 2 May 2016 11:02:17 +0000 (12:02 +0100)
If widget of a playback or capture DAI is already On, then no
need not send the Set DMA Control IPC message to firmware.

Signed-off-by: Dharageswari R <dharageswari.r@intel.com>
Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/intel/skylake/skl-pcm.c

index dab0900..4fcf5f8 100644 (file)
@@ -213,7 +213,7 @@ static int skl_be_prepare(struct snd_pcm_substream *substream,
        struct skl_sst *ctx = skl->skl_sst;
        struct skl_module_cfg *mconfig;
 
-       if ((dai->playback_active > 1) || (dai->capture_active > 1))
+       if (dai->playback_widget->power || dai->capture_widget->power)
                return 0;
 
        mconfig = skl_tplg_be_get_cpr_module(dai, substream->stream);