Skip to content

Commit

Permalink
dmaengine: at_hdmac: fix buffer transfer size specification
Browse files Browse the repository at this point in the history
Buffer transfer size is the number of transfers to be performed in
relation with the width of the _source_ interface.
So in the DMA_FROM_DEVICE case, it should be the register width that
should be taken into account.

Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
  • Loading branch information
Nicolas Ferre authored and Dan Williams committed Dec 14, 2010
1 parent f3c677b commit 59a609d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/dma/at_hdmac.c
Original file line number Diff line number Diff line change
Expand Up @@ -722,7 +722,7 @@ atc_prep_slave_sg(struct dma_chan *chan, struct scatterlist *sgl,
desc->lli.daddr = mem;
desc->lli.ctrla = ctrla
| ATC_DST_WIDTH(mem_width)
| len >> mem_width;
| len >> reg_width;
desc->lli.ctrlb = ctrlb;

if (!first) {
Expand Down

0 comments on commit 59a609d

Please sign in to comment.