Message ID | 1518766434-7911-8-git-send-email-Vijendar.Mukunda@amd.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Fri, Feb 16, 2018 at 01:03:52PM +0530, Vijendar Mukunda wrote: > As per design, non-circular dma also need to be > stopped explicitly for both playback and capture > scenarios. > > Added condition checks to stop non-circular dma for > both the I2S controller instances. Shouldn't this have been going in as a bugfix at the start of the series?
On Monday 19 February 2018 10:20 PM, Mark Brown wrote: > On Fri, Feb 16, 2018 at 01:03:52PM +0530, Vijendar Mukunda wrote: >> As per design, non-circular dma also need to be >> stopped explicitly for both playback and capture >> scenarios. >> >> Added condition checks to stop non-circular dma for >> both the I2S controller instances. > Shouldn't this have been going in as a bugfix at the start of the > series? This patch also includes changes for BT I2S controller instance. Either we can split the patch in to two ( one for I2S SP Instance and one for I2S BT Instance) or we can let go these changes as one patch.
diff --git a/sound/soc/amd/acp-pcm-dma.c b/sound/soc/amd/acp-pcm-dma.c index 0e2dc05..a16e2bb 100644 --- a/sound/soc/amd/acp-pcm-dma.c +++ b/sound/soc/amd/acp-pcm-dma.c @@ -1178,11 +1178,15 @@ static int acp_dma_trigger(struct snd_pcm_substream *substream, int cmd) switch (rtd->i2s_play_instance) { case I2S_BT_INSTANCE: ret = acp_dma_stop(rtd->acp_mmio, + SYSRAM_TO_ACP_BT_INSTANCE_CH_NUM); + ret = acp_dma_stop(rtd->acp_mmio, ACP_TO_I2S_DMA_BT_INSTANCE_CH_NUM); rtd->i2sbt_renderbytescount = 0; break; case I2S_SP_INSTANCE: default: + ret = acp_dma_stop(rtd->acp_mmio, + SYSRAM_TO_ACP_CH_NUM); ret = acp_dma_stop(rtd->acp_mmio, ACP_TO_I2S_DMA_CH_NUM); rtd->i2ssp_renderbytescount = 0; @@ -1192,12 +1196,16 @@ static int acp_dma_trigger(struct snd_pcm_substream *substream, int cmd) case I2S_BT_INSTANCE: ret = acp_dma_stop(rtd->acp_mmio, I2S_TO_ACP_DMA_BT_INSTANCE_CH_NUM); + ret = acp_dma_stop(rtd->acp_mmio, + ACP_TO_SYSRAM_BT_INSTANCE_CH_NUM); rtd->i2sbt_capturebytescount = 0; break; case I2S_SP_INSTANCE: default: ret = acp_dma_stop(rtd->acp_mmio, I2S_TO_ACP_DMA_CH_NUM); + ret = acp_dma_stop(rtd->acp_mmio, + ACP_TO_SYSRAM_CH_NUM); rtd->i2ssp_capturebytescount = 0; } }