Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1417229

[PATCH] iommu/mediatek: Do not call of_node_put in mtk_iommu_of_xlate

From <honghui.zhang@mediatek.com>
Newsgroups linux.kernel
Subject [PATCH] iommu/mediatek: Do not call of_node_put in mtk_iommu_of_xlate
Date 2016-06-08 12:00 +0200
Message-ID <rHIrh-6Wr-61@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


From: Honghui Zhang <honghui.zhang@mediatek.com>

The device_node will be released in of_iommu_configure, it may be double
released if call of_node_put in mtk_iommu_of_xlate.

Signed-off-by: Honghui Zhang <honghui.zhang@mediatek.com>
---
 drivers/iommu/mtk_iommu.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c
index c3043d8..493bd3e 100644
--- a/drivers/iommu/mtk_iommu.c
+++ b/drivers/iommu/mtk_iommu.c
@@ -455,7 +455,6 @@ static int mtk_iommu_of_xlate(struct device *dev, struct of_phandle_args *args)
 	if (!dev->archdata.iommu) {
 		/* Get the m4u device */
 		m4updev = of_find_device_by_node(args->np);
-		of_node_put(args->np);
 		if (WARN_ON(!m4updev))
 			return -EINVAL;
 
-- 
1.8.1.1.dirty

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

[PATCH] iommu/mediatek: Do not call of_node_put in mtk_iommu_of_xlate <honghui.zhang@mediatek.com> - 2016-06-08 12:00 +0200

csiph-web