diff options
author | Vinod Koul <vinod.koul@intel.com> | 2013-11-16 01:24:17 -0500 |
---|---|---|
committer | Vinod Koul <vinod.koul@intel.com> | 2013-11-16 01:32:36 -0500 |
commit | df12a3178d340319b1955be6b973a4eb84aff754 (patch) | |
tree | 2b9c68f8a6c299d1e5a4026c60117b5c00d46008 /drivers/dma/amba-pl08x.c | |
parent | 2f986ec6fa57a5dcf77f19f5f0d44b1f680a100f (diff) | |
parent | 82a1402eaee5dab1f3ab2d5aa4c316451374c5af (diff) |
Merge commit 'dmaengine-3.13-v2' of git://git.kernel.org/pub/scm/linux/kernel/git/djbw/dmaengine
Pull dmaengine changes from Dan
1/ Bartlomiej and Dan finalized a rework of the dma address unmap
implementation.
2/ In the course of testing 1/ a collection of enhancements to dmatest
fell out. Notably basic performance statistics, and fixed / enhanced
test control through new module parameters 'run', 'wait', 'noverify',
and 'verbose'. Thanks to Andriy and Linus for their review.
3/ Testing the raid related corner cases of 1/ triggered bugs in the
recently added 16-source operation support in the ioatdma driver.
4/ Some minor fixes / cleanups to mv_xor and ioatdma.
Conflicts:
drivers/dma/dmatest.c
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'drivers/dma/amba-pl08x.c')
-rw-r--r-- | drivers/dma/amba-pl08x.c | 32 |
1 files changed, 1 insertions, 31 deletions
diff --git a/drivers/dma/amba-pl08x.c b/drivers/dma/amba-pl08x.c index 4ee6533108f6..f2917e2035ba 100644 --- a/drivers/dma/amba-pl08x.c +++ b/drivers/dma/amba-pl08x.c | |||
@@ -1164,42 +1164,12 @@ static void pl08x_free_txd(struct pl08x_driver_data *pl08x, | |||
1164 | kfree(txd); | 1164 | kfree(txd); |
1165 | } | 1165 | } |
1166 | 1166 | ||
1167 | static void pl08x_unmap_buffers(struct pl08x_txd *txd) | ||
1168 | { | ||
1169 | struct device *dev = txd->vd.tx.chan->device->dev; | ||
1170 | struct pl08x_sg *dsg; | ||
1171 | |||
1172 | if (!(txd->vd.tx.flags & DMA_COMPL_SKIP_SRC_UNMAP)) { | ||
1173 | if (txd->vd.tx.flags & DMA_COMPL_SRC_UNMAP_SINGLE) | ||
1174 | list_for_each_entry(dsg, &txd->dsg_list, node) | ||
1175 | dma_unmap_single(dev, dsg->src_addr, dsg->len, | ||
1176 | DMA_TO_DEVICE); | ||
1177 | else { | ||
1178 | list_for_each_entry(dsg, &txd->dsg_list, node) | ||
1179 | dma_unmap_page(dev, dsg->src_addr, dsg->len, | ||
1180 | DMA_TO_DEVICE); | ||
1181 | } | ||
1182 | } | ||
1183 | if (!(txd->vd.tx.flags & DMA_COMPL_SKIP_DEST_UNMAP)) { | ||
1184 | if (txd->vd.tx.flags & DMA_COMPL_DEST_UNMAP_SINGLE) | ||
1185 | list_for_each_entry(dsg, &txd->dsg_list, node) | ||
1186 | dma_unmap_single(dev, dsg->dst_addr, dsg->len, | ||
1187 | DMA_FROM_DEVICE); | ||
1188 | else | ||
1189 | list_for_each_entry(dsg, &txd->dsg_list, node) | ||
1190 | dma_unmap_page(dev, dsg->dst_addr, dsg->len, | ||
1191 | DMA_FROM_DEVICE); | ||
1192 | } | ||
1193 | } | ||
1194 | |||
1195 | static void pl08x_desc_free(struct virt_dma_desc *vd) | 1167 | static void pl08x_desc_free(struct virt_dma_desc *vd) |
1196 | { | 1168 | { |
1197 | struct pl08x_txd *txd = to_pl08x_txd(&vd->tx); | 1169 | struct pl08x_txd *txd = to_pl08x_txd(&vd->tx); |
1198 | struct pl08x_dma_chan *plchan = to_pl08x_chan(vd->tx.chan); | 1170 | struct pl08x_dma_chan *plchan = to_pl08x_chan(vd->tx.chan); |
1199 | 1171 | ||
1200 | if (!plchan->slave) | 1172 | dma_descriptor_unmap(txd); |
1201 | pl08x_unmap_buffers(txd); | ||
1202 | |||
1203 | if (!txd->done) | 1173 | if (!txd->done) |
1204 | pl08x_release_mux(plchan); | 1174 | pl08x_release_mux(plchan); |
1205 | 1175 | ||