[PATCH 1/4 v2] dmaengine: add a tx_free method to structdma_async_tx_descriptor

From: Guennadi Liakhovetski
Date: Wed Dec 10 2008 - 05:36:25 EST


From: Guennadi Liakhovetski <lg@xxxxxxx>

Some users reuse DMA transaction descriptors multiple times and need an
explicit call to release them. An example of such a user is Video4Linux, which
has to be able to release descriptors on ioctl(VIDIOC_DQBUF).

Signed-off-by: Guennadi Liakhovetski <lg@xxxxxxx>
---
include/linux/dmaengine.h | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/include/linux/dmaengine.h b/include/linux/dmaengine.h
index 64dea2a..58b2268 100644
--- a/include/linux/dmaengine.h
+++ b/include/linux/dmaengine.h
@@ -183,6 +183,7 @@ typedef void (*dma_async_tx_callback)(void *dma_async_param);
* descriptors
* @chan: target channel for this operation
* @tx_submit: set the prepared descriptor(s) to be executed by the engine
+ * @tx_free: release a transaction descriptor
* @callback: routine to call after this operation is complete
* @callback_param: general parameter to pass to the callback routine
* ---async_tx api specific fields---
@@ -197,6 +198,7 @@ struct dma_async_tx_descriptor {
struct list_head tx_list;
struct dma_chan *chan;
dma_cookie_t (*tx_submit)(struct dma_async_tx_descriptor *tx);
+ void (*tx_free)(struct dma_async_tx_descriptor *tx);
dma_async_tx_callback callback;
void *callback_param;
struct dma_async_tx_descriptor *next;
--
1.5.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/