aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@linaro.org>2011-02-10 10:10:47 -0500
committerChris Ball <cjb@laptop.org>2011-03-15 13:49:21 -0400
commitd7554caa2c3410c07a1889a08c66288edbdc216a (patch)
tree82777655fc7fccca49c155ceff320c75f6270814 /drivers
parent2dc7ddc1e7e68ee7793dda0ca0d659367d035e3d (diff)
mmc: tmio_mmc: unmap with the proper sglen
According to the DMA-API you shall unmap the sglists with the same sglist length as passed into the mapping function, not the returned value from the mapping function. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/mmc/host/tmio_mmc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mmc/host/tmio_mmc.c b/drivers/mmc/host/tmio_mmc.c
index 0d36fa9c629e..1b9fa21c2bdc 100644
--- a/drivers/mmc/host/tmio_mmc.c
+++ b/drivers/mmc/host/tmio_mmc.c
@@ -983,11 +983,11 @@ static void tmio_tasklet_fn(unsigned long arg)
983 983
984 if (host->data->flags & MMC_DATA_READ) 984 if (host->data->flags & MMC_DATA_READ)
985 dma_unmap_sg(host->chan_rx->device->dev, 985 dma_unmap_sg(host->chan_rx->device->dev,
986 host->sg_ptr, host->dma_sglen, 986 host->sg_ptr, host->sg_len,
987 DMA_FROM_DEVICE); 987 DMA_FROM_DEVICE);
988 else 988 else
989 dma_unmap_sg(host->chan_tx->device->dev, 989 dma_unmap_sg(host->chan_tx->device->dev,
990 host->sg_ptr, host->dma_sglen, 990 host->sg_ptr, host->sg_len,
991 DMA_TO_DEVICE); 991 DMA_TO_DEVICE);
992 992
993 tmio_mmc_do_data_irq(host); 993 tmio_mmc_do_data_irq(host);