dmaengine: at_xdmac: fix residue corruption
authorLudovic Desroches <ludovic.desroches@atmel.com>
Thu, 12 May 2016 14:54:09 +0000 (16:54 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 10 Aug 2016 10:54:42 +0000 (12:54 +0200)
commitd1a41160ee77efcee8d150138f442b5faae2e61f
treea6a3e190773ad45434ebe8de9be44d8ef9acb340
parentde46295628512d25cb8190dace8c220880aca8c3
dmaengine: at_xdmac: fix residue corruption

commit 53398f488821c2b5b15291e3debec6ad33f75d3d upstream.

An unexpected value of CUBC can lead to a corrupted residue. A more
complex sequence is needed to detect an inaccurate value for NCA or CUBC.

Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com>
Fixes: e1f7c9eee707 ("dmaengine: at_xdmac: creation of the atmel
eXtended DMA Controller driver")
Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/dma/at_xdmac.c