dmaengine: stm32-dma: fix max items per transfer
authorPierre Yves MORDRET <pierre-yves.mordret@st.com>
Tue, 13 Mar 2018 16:42:04 +0000 (17:42 +0100)
committerVinod Koul <vinod.koul@intel.com>
Wed, 4 Apr 2018 06:19:36 +0000 (11:49 +0530)
commit80a76952a5a5d2914a5c04d6f3a151348e5580a5
tree534c4b3597004503d28f1c191eaddf617ed123ae
parentc2d86b1cd64c5db8948119761008ff337c688d96
dmaengine: stm32-dma: fix max items per transfer

Having 0 in item counter register is valid and stands for a "No or Ended
transfer". Therefore valid transfer starts from @+0 to @+0xFFFE leading to
unaligned scatter gather at boundary. Thus it's safer to round down this
value on its FIFO size (16 Bytes).

Signed-off-by: Pierre-Yves MORDRET <pierre-yves.mordret@st.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
drivers/dma/stm32-dma.c