]> git.baikalelectronics.ru Git - kernel.git/commit
dmaengine: xilinx_dma: in axidma slave_sg and dma_cyclic mode align split descriptors
authorAndrea Merello <andrea.merello@gmail.com>
Tue, 20 Nov 2018 15:31:46 +0000 (16:31 +0100)
committerVinod Koul <vkoul@kernel.org>
Mon, 7 Jan 2019 04:23:11 +0000 (09:53 +0530)
commitd0254f5874c42e82c80020f62b16f38aad1bf8ed
treeda727149d396b2122fd2fc75ad597c0614d15167
parent806245a8f0227cb95cc7d4cd6f50bcac38001d39
dmaengine: xilinx_dma: in axidma slave_sg and dma_cyclic mode align split descriptors

Whenever a single or cyclic transaction is prepared, the driver
could eventually split it over several SG descriptors in order
to deal with the HW maximum transfer length.

This could end up in DMA operations starting from a misaligned
address. This seems fatal for the HW if DRE (Data Realignment Engine)
is not enabled.

This patch eventually adjusts the transfer size in order to make sure
all operations start from an aligned address.

Cc: Radhey Shyam Pandey <radhey.shyam.pandey@xilinx.com>
Signed-off-by: Andrea Merello <andrea.merello@gmail.com>
Reviewed-by: Radhey Shyam Pandey <radhey.shyam.pandey@xilinx.com>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/dma/xilinx/xilinx_dma.c