aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/dma
diff options
context:
space:
mode:
authorShawn Guo <shawn.guo@freescale.com>2011-01-19 16:50:37 -0500
committerSascha Hauer <s.hauer@pengutronix.de>2011-01-31 06:41:59 -0500
commit8a9659114c7be6f88253618252881ea6fe0588b4 (patch)
tree4845609a6f7c48391ec1fee2a01c854590855415 /drivers/dma
parent4b2ce9ddb370c4eb573540611c347d78ac4b54a0 (diff)
dmaengine: imx-sdma: return sdmac->status in sdma_tx_status()
The sdmac->status was designed to reflect the status of the tx, so simply return it in sdma_tx_status(). Then dma client can call dma_async_is_tx_complete() to know the status of the tx. Signed-off-by: Shawn Guo <shawn.guo@freescale.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/dma')
-rw-r--r--drivers/dma/imx-sdma.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/dma/imx-sdma.c b/drivers/dma/imx-sdma.c
index 6fc04d85be6b..f331ae0f7ec3 100644
--- a/drivers/dma/imx-sdma.c
+++ b/drivers/dma/imx-sdma.c
@@ -1061,14 +1061,12 @@ static enum dma_status sdma_tx_status(struct dma_chan *chan,
1061{ 1061{
1062 struct sdma_channel *sdmac = to_sdma_chan(chan); 1062 struct sdma_channel *sdmac = to_sdma_chan(chan);
1063 dma_cookie_t last_used; 1063 dma_cookie_t last_used;
1064 enum dma_status ret;
1065 1064
1066 last_used = chan->cookie; 1065 last_used = chan->cookie;
1067 1066
1068 ret = dma_async_is_complete(cookie, sdmac->last_completed, last_used);
1069 dma_set_tx_state(txstate, sdmac->last_completed, last_used, 0); 1067 dma_set_tx_state(txstate, sdmac->last_completed, last_used, 0);
1070 1068
1071 return ret; 1069 return sdmac->status;
1072} 1070}
1073 1071
1074static void sdma_issue_pending(struct dma_chan *chan) 1072static void sdma_issue_pending(struct dma_chan *chan)