diff options
author | Dave Jiang <dave.jiang@intel.com> | 2016-07-20 23:12:24 +0300 |
---|---|---|
committer | Vinod Koul <vinod.koul@intel.com> | 2016-08-08 05:41:40 +0300 |
commit | 0024b2ac374490de46bfd35c43002c7800ad14ed (patch) | |
tree | e9a2ddca5e538bc1a8150aea17767c261025db6d /drivers/dma | |
parent | 064370c6a1d97dda4b8827c02782587023c5c227 (diff) | |
download | linux-0024b2ac374490de46bfd35c43002c7800ad14ed.tar.xz |
dmaengine: nbpfaxi: convert callback to helper function
This is in preperation of moving to a callback that provides results to the
callback for the transaction. The conversion will maintain current behavior
and the driver must convert to new callback mechanism at a later time in
order to receive results.
Signed-off-by: Dave Jiang <dave.jiang@intel.com>
Reviewed-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'drivers/dma')
-rw-r--r-- | drivers/dma/nbpfaxi.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/dma/nbpfaxi.c b/drivers/dma/nbpfaxi.c index 08c45c185549..09de71519d37 100644 --- a/drivers/dma/nbpfaxi.c +++ b/drivers/dma/nbpfaxi.c @@ -1102,8 +1102,7 @@ static void nbpf_chan_tasklet(unsigned long data) { struct nbpf_channel *chan = (struct nbpf_channel *)data; struct nbpf_desc *desc, *tmp; - dma_async_tx_callback callback; - void *param; + struct dmaengine_desc_callback cb; while (!list_empty(&chan->done)) { bool found = false, must_put, recycling = false; @@ -1151,14 +1150,12 @@ static void nbpf_chan_tasklet(unsigned long data) must_put = false; } - callback = desc->async_tx.callback; - param = desc->async_tx.callback_param; + dmaengine_desc_get_callback(&desc->async_tx, &cb); /* ack and callback completed descriptor */ spin_unlock_irq(&chan->lock); - if (callback) - callback(param); + dmaengine_desc_callback_invoke(&cb, NULL); if (must_put) nbpf_desc_put(desc); |