dmaengine: dw-edma: Don't permit non-inc interleaved xfers
DW eDMA controller always increments both source and destination
addresses. Permitting DMA interleaved transfers with no src_inc/dst_inc
flags set may lead to unexpected behaviour for the device users. Let's fix
that by terminating the interleaved transfers if at least one of the
dma_interleaved_template.{src_inc,dst_inc} flag is initialized with false
value. Note in addition to that we need to increase the source and
destination addresses accordingly after each iteration.
Fixes: 85e7518f ("dmaengine: dw-edma: Add device_prep_interleave_dma() support")
Signed-off-by:
Serge Semin <Sergey.Semin@baikalelectronics.ru>
Reviewed-by:
Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Tested-by:
Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Acked-by:
Vinod Koul <vkoul@kernel.org>
Signed-off-by:
Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Loading
Please sign in to comment