diff options
Diffstat (limited to 'drivers/dma/at_hdmac.c')
| -rw-r--r-- | drivers/dma/at_hdmac.c | 28 |
1 files changed, 2 insertions, 26 deletions
diff --git a/drivers/dma/at_hdmac.c b/drivers/dma/at_hdmac.c index c787f38a186a..e2c04dc81e2a 100644 --- a/drivers/dma/at_hdmac.c +++ b/drivers/dma/at_hdmac.c | |||
| @@ -344,31 +344,7 @@ atc_chain_complete(struct at_dma_chan *atchan, struct at_desc *desc) | |||
| 344 | /* move myself to free_list */ | 344 | /* move myself to free_list */ |
| 345 | list_move(&desc->desc_node, &atchan->free_list); | 345 | list_move(&desc->desc_node, &atchan->free_list); |
| 346 | 346 | ||
| 347 | /* unmap dma addresses (not on slave channels) */ | 347 | dma_descriptor_unmap(txd); |
| 348 | if (!atchan->chan_common.private) { | ||
| 349 | struct device *parent = chan2parent(&atchan->chan_common); | ||
| 350 | if (!(txd->flags & DMA_COMPL_SKIP_DEST_UNMAP)) { | ||
| 351 | if (txd->flags & DMA_COMPL_DEST_UNMAP_SINGLE) | ||
| 352 | dma_unmap_single(parent, | ||
| 353 | desc->lli.daddr, | ||
| 354 | desc->len, DMA_FROM_DEVICE); | ||
| 355 | else | ||
| 356 | dma_unmap_page(parent, | ||
| 357 | desc->lli.daddr, | ||
| 358 | desc->len, DMA_FROM_DEVICE); | ||
| 359 | } | ||
| 360 | if (!(txd->flags & DMA_COMPL_SKIP_SRC_UNMAP)) { | ||
| 361 | if (txd->flags & DMA_COMPL_SRC_UNMAP_SINGLE) | ||
| 362 | dma_unmap_single(parent, | ||
| 363 | desc->lli.saddr, | ||
| 364 | desc->len, DMA_TO_DEVICE); | ||
| 365 | else | ||
| 366 | dma_unmap_page(parent, | ||
| 367 | desc->lli.saddr, | ||
| 368 | desc->len, DMA_TO_DEVICE); | ||
| 369 | } | ||
| 370 | } | ||
| 371 | |||
| 372 | /* for cyclic transfers, | 348 | /* for cyclic transfers, |
| 373 | * no need to replay callback function while stopping */ | 349 | * no need to replay callback function while stopping */ |
| 374 | if (!atc_chan_is_cyclic(atchan)) { | 350 | if (!atc_chan_is_cyclic(atchan)) { |
| @@ -1102,7 +1078,7 @@ atc_tx_status(struct dma_chan *chan, | |||
| 1102 | int bytes = 0; | 1078 | int bytes = 0; |
| 1103 | 1079 | ||
| 1104 | ret = dma_cookie_status(chan, cookie, txstate); | 1080 | ret = dma_cookie_status(chan, cookie, txstate); |
| 1105 | if (ret == DMA_SUCCESS) | 1081 | if (ret == DMA_COMPLETE) |
| 1106 | return ret; | 1082 | return ret; |
| 1107 | /* | 1083 | /* |
| 1108 | * There's no point calculating the residue if there's | 1084 | * There's no point calculating the residue if there's |
