]> git.baikalelectronics.ru Git - kernel.git/commit
dmaengine: at_xdmac: double FIFO flush needed to compute residue
authorLudovic Desroches <ludovic.desroches@atmel.com>
Thu, 12 May 2016 14:54:10 +0000 (16:54 +0200)
committerVinod Koul <vinod.koul@intel.com>
Mon, 30 May 2016 05:17:52 +0000 (10:47 +0530)
commitbadd1964aef7ee61f509f45ac23d94152a0b2181
tree18a9444f8302117c4cb1412452f59f1707fca04a
parent25b69464883257a73772bb70c8a33699573cac7a
dmaengine: at_xdmac: double FIFO flush needed to compute residue

Due to the way CUBC register is updated, a double flush is needed to
compute an accurate residue. First flush aim is to get data from the DMA
FIFO and second one ensures that we won't report data which are not in
memory.

Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com>
Fixes: ac70d1d8dc5d ("dmaengine: at_xdmac: creation of the atmel
eXtended DMA Controller driver")
Cc: stable@vger.kernel.org #v4.1 and later
Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
drivers/dma/at_xdmac.c