summaryrefslogtreecommitdiff
path: root/drivers/dma
diff options
context:
space:
mode:
authorChuhong Yuan <hslester96@gmail.com>2019-11-15 16:31:53 +0800
committerVinod Koul <vkoul@kernel.org>2019-11-22 10:51:30 +0530
commit39716c560c75619e174221d72f850d44166ef3ae (patch)
tree3cb5e60824096900984c38cb7019256708e361ee /drivers/dma
parentc236ba4ae7183c1add8dbce91b27c700f7ef4168 (diff)
dmaengine: mmp_pdma: add missed of_dma_controller_free
The driver calls of_dma_controller_register in probe but does not free it in remove. Add the call to fix it. Signed-off-by: Chuhong Yuan <hslester96@gmail.com> Link: https://lore.kernel.org/r/20191115083153.12334-1-hslester96@gmail.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/dma')
-rw-r--r--drivers/dma/mmp_pdma.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/dma/mmp_pdma.c b/drivers/dma/mmp_pdma.c
index 7fe494fc50d4..ad06f260e907 100644
--- a/drivers/dma/mmp_pdma.c
+++ b/drivers/dma/mmp_pdma.c
@@ -945,6 +945,8 @@ static int mmp_pdma_remove(struct platform_device *op)
struct mmp_pdma_phy *phy;
int i, irq = 0, irq_num = 0;
+ if (op->dev.of_node)
+ of_dma_controller_free(op->dev.of_node);
for (i = 0; i < pdev->dma_channels; i++) {
if (platform_get_irq(op, i) > 0)