summaryrefslogtreecommitdiff
path: root/drivers/dma/k3dma.c
diff options
context:
space:
mode:
authorVinod Koul <vinod.koul@intel.com>2016-07-28 07:40:37 +0300
committerVinod Koul <vinod.koul@intel.com>2016-07-28 07:40:37 +0300
commit4bb0439626983fdde5af3ce970bd0ba2070f5378 (patch)
tree081166e9a6bd98eef39f41171f2e2ef014413bb3 /drivers/dma/k3dma.c
parent89b90c09b5d505dcff1068054f1fc2d2704e909f (diff)
parent184ff2aa3c0ba7f1cd44ed7e8d766e12e43694e2 (diff)
downloadlinux-4bb0439626983fdde5af3ce970bd0ba2070f5378.tar.xz
Merge branch 'topic/dmaengine_cleanups' into for-linus
Diffstat (limited to 'drivers/dma/k3dma.c')
-rw-r--r--drivers/dma/k3dma.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/dma/k3dma.c b/drivers/dma/k3dma.c
index 563affd5cd06..39de8980128c 100644
--- a/drivers/dma/k3dma.c
+++ b/drivers/dma/k3dma.c
@@ -102,6 +102,7 @@ struct k3_dma_dev {
struct clk *clk;
u32 dma_channels;
u32 dma_requests;
+ unsigned int irq;
};
#define to_k3_dma(dmadev) container_of(dmadev, struct k3_dma_dev, slave)
@@ -703,6 +704,8 @@ static int k3_dma_probe(struct platform_device *op)
if (ret)
return ret;
+ d->irq = irq;
+
/* init phy channel */
d->phy = devm_kzalloc(&op->dev,
d->dma_channels * sizeof(struct k3_dma_phy), GFP_KERNEL);
@@ -787,6 +790,8 @@ static int k3_dma_remove(struct platform_device *op)
dma_async_device_unregister(&d->slave);
of_dma_controller_free((&op->dev)->of_node);
+ devm_free_irq(&op->dev, d->irq, d);
+
list_for_each_entry_safe(c, cn, &d->slave.channels, vc.chan.device_node) {
list_del(&c->vc.chan.device_node);
tasklet_kill(&c->vc.task);