From: Peter Ujfalusi Date: Wed, 11 Nov 2015 10:37:55 +0000 (+0200) Subject: dmaengine: omap-dma: Correct status reporting for memcpy X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=adf850bcca4eec45f06c6ad3e297a350a8a319bc;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git dmaengine: omap-dma: Correct status reporting for memcpy During mem copy both src and dst position moves at the same pace. Check the dst position for progress reporting. Signed-off-by: Peter Ujfalusi Tested-by: Tomi Valkeinen Signed-off-by: Jyri Sarha Signed-off-by: Vinod Koul --- diff --git a/drivers/dma/omap-dma.c b/drivers/dma/omap-dma.c index 1dfc71c90123..8ed39ce24d46 100644 --- a/drivers/dma/omap-dma.c +++ b/drivers/dma/omap-dma.c @@ -719,7 +719,7 @@ static enum dma_status omap_dma_tx_status(struct dma_chan *chan, if (d->dir == DMA_MEM_TO_DEV) pos = omap_dma_get_src_pos(c); - else if (d->dir == DMA_DEV_TO_MEM) + else if (d->dir == DMA_DEV_TO_MEM || d->dir == DMA_MEM_TO_MEM) pos = omap_dma_get_dst_pos(c); else pos = 0;