From: 邱建斌 Date: Thu, 14 Mar 2013 03:42:36 +0000 (+0800) Subject: audio DMA : dma_period is not an integer multiple of dma_size support X-Git-Tag: firefly_0821_release~7412 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=e609b8428a2abd372ad63872c6e2dbf5c97b106c;p=firefly-linux-kernel-4.4.55.git audio DMA : dma_period is not an integer multiple of dma_size support --- diff --git a/sound/soc/rk29/rk29_pcm.c b/sound/soc/rk29/rk29_pcm.c index d936b2653d09..69b871a3bd98 100755 --- a/sound/soc/rk29/rk29_pcm.c +++ b/sound/soc/rk29/rk29_pcm.c @@ -114,15 +114,14 @@ static void rockchip_pcm_enqueue(struct snd_pcm_substream *substream) limit = prtd->dma_limit; if (DMA_INFIN_LOOP()) { - if(prtd->dma_period % prtd->params->dma_size*16){ - WARN_ON(1); + if(prtd->dma_period % (prtd->params->dma_size*16)){ + printk("dma_period(%d) is not an integer multiple of dma_size(%d)",prtd->dma_period,prtd->params->dma_size*16); rk29_dma_config(prtd->params->channel, prtd->params->dma_size, 1); } else rk29_dma_config(prtd->params->channel, prtd->params->dma_size, 16); - ret = rk29_dma_enqueue_ring(prtd->params->channel, substream, pos, prtd->dma_period, limit ,true); if (ret == 0)