summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2012-05-26 17:00:49 +0100
committerRussell King <rmk+kernel@arm.linux.org.uk>2012-07-01 14:16:10 +0100
commita068682cd69461911407411b4198248a87c583e2 (patch)
tree731b0ea4ebb03afad70d29e8d1e000496e92f884 /drivers
parent70f3ff434d7fc9a3cea5ebbb8a8d7aaa4c906125 (diff)
dmaengine: PL08x: ensure all descriptors are freed when channel is released
Ensure all queued descriptors are freed when the channel is released, ensuring we don't leak memory Acked-by: Linus Walleij <linus.walleij@linaro.org> Tested-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/dma/amba-pl08x.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/dma/amba-pl08x.c b/drivers/dma/amba-pl08x.c
index a5d85b101b8..6fbeebb9486 100644
--- a/drivers/dma/amba-pl08x.c
+++ b/drivers/dma/amba-pl08x.c
@@ -1117,6 +1117,8 @@ static int pl08x_alloc_chan_resources(struct dma_chan *chan)
static void pl08x_free_chan_resources(struct dma_chan *chan)
{
+ /* Ensure all queued descriptors are freed */
+ vchan_free_chan_resources(to_virt_chan(chan));
}
static struct dma_async_tx_descriptor *pl08x_prep_dma_interrupt(