[PATCH v2 15/41] dmaengine: mic_x100_dma: convert callback to helper function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Convert driver to use the new helper function for callback

Signed-off-by: Dave Jiang <dave.jiang@xxxxxxxxx>
Cc: Sudeep Dutt <sudeep.dutt@xxxxxxxxx>
---
 drivers/dma/mic_x100_dma.c |    9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/dma/mic_x100_dma.c b/drivers/dma/mic_x100_dma.c
index 1502b24..b8cf733 100644
--- a/drivers/dma/mic_x100_dma.c
+++ b/drivers/dma/mic_x100_dma.c
@@ -103,11 +103,12 @@ static void mic_dma_cleanup(struct mic_dma_chan *ch)
 	for (last_tail = ch->last_tail; tail != last_tail;) {
 		tx = &ch->tx_array[last_tail];
 		if (tx->cookie) {
+			struct dmaengine_desc_callback cb;
+
 			dma_cookie_complete(tx);
-			if (tx->callback) {
-				tx->callback(tx->callback_param);
-				tx->callback = NULL;
-			}
+			dmaengine_desc_get_callback(tx, &cb);
+			dmaengine_desc_callback_invoke(&cb, NULL);
+			tx->callback = NULL;
 		}
 		last_tail = mic_dma_hw_ring_inc(last_tail);
 	}

--
To unsubscribe from this list: send the line "unsubscribe dmaengine" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux PCI]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux