aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/dma/iop-adma.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/dma/iop-adma.c')
-rw-r--r--drivers/dma/iop-adma.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/dma/iop-adma.c b/drivers/dma/iop-adma.c
index f82b0906d466..21854cd7190f 100644
--- a/drivers/dma/iop-adma.c
+++ b/drivers/dma/iop-adma.c
@@ -63,7 +63,6 @@ iop_adma_run_tx_complete_actions(struct iop_adma_desc_slot *desc,
63 struct iop_adma_chan *iop_chan, dma_cookie_t cookie) 63 struct iop_adma_chan *iop_chan, dma_cookie_t cookie)
64{ 64{
65 BUG_ON(desc->async_tx.cookie < 0); 65 BUG_ON(desc->async_tx.cookie < 0);
66 spin_lock_bh(&desc->async_tx.lock);
67 if (desc->async_tx.cookie > 0) { 66 if (desc->async_tx.cookie > 0) {
68 cookie = desc->async_tx.cookie; 67 cookie = desc->async_tx.cookie;
69 desc->async_tx.cookie = 0; 68 desc->async_tx.cookie = 0;
@@ -101,7 +100,6 @@ iop_adma_run_tx_complete_actions(struct iop_adma_desc_slot *desc,
101 100
102 /* run dependent operations */ 101 /* run dependent operations */
103 async_tx_run_dependencies(&desc->async_tx); 102 async_tx_run_dependencies(&desc->async_tx);
104 spin_unlock_bh(&desc->async_tx.lock);
105 103
106 return cookie; 104 return cookie;
107} 105}
@@ -275,8 +273,11 @@ iop_adma_slot_cleanup(struct iop_adma_chan *iop_chan)
275 273
276static void iop_adma_tasklet(unsigned long data) 274static void iop_adma_tasklet(unsigned long data)
277{ 275{
278 struct iop_adma_chan *chan = (struct iop_adma_chan *) data; 276 struct iop_adma_chan *iop_chan = (struct iop_adma_chan *) data;
279 __iop_adma_slot_cleanup(chan); 277
278 spin_lock(&iop_chan->lock);
279 __iop_adma_slot_cleanup(iop_chan);
280 spin_unlock(&iop_chan->lock);
280} 281}
281 282
282static struct iop_adma_desc_slot * 283static struct iop_adma_desc_slot *