summaryrefslogtreecommitdiff
path: root/net/rds
diff options
context:
space:
mode:
authorRadu Alexe <radu.alexe@nxp.com>2017-10-09 14:29:11 (GMT)
committerXie Xiaobo <xiaobo.xie@nxp.com>2017-10-12 03:37:27 (GMT)
commit445358482f0e9a1d30c8fd36c2eae581812e086d (patch)
tree215c897512cbdcb1583e5829da2ccc6f8f1e2e11 /net/rds
parent072da00ac095a99e27ad40c966a5044fb3798b78 (diff)
downloadlinux-445358482f0e9a1d30c8fd36c2eae581812e086d.tar.xz
dma: caam: fix desc error when data length is over 130815 bytes
The CAAM DMA shared descriptor states that if a buffer is large enough it is broken into chunks of maximum 65280 bytes (DMA_MAX_DATA_CHUNK) and for each chunk a transfer request is issued. The length of the chunk for each iteration should be therefore computed as min(DMA_MAX_DATA_CHUNK, data_rem_length), where data_rem_length is the length of the chunks that still remain to be send. Currently the logic of the shared descriptor is broken: on every iteration the chunk length is instead computed as max(max_chunk_size, data_rem_length). This produces an error for the first chunk when buffer data length is greater than max_chunk_size + max_allowed_chunk_size = 65280 + 65535 = 130815. Signed-off-by: Radu Alexe <radu.alexe@nxp.com>
Diffstat (limited to 'net/rds')
0 files changed, 0 insertions, 0 deletions