[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220511065548.3402408-1-yangyingliang@huawei.com>
Date: Wed, 11 May 2022 14:55:48 +0800
From: Yang Yingliang <yangyingliang@...wei.com>
To: <linux-kernel@...r.kernel.org>, <linux-media@...r.kernel.org>
CC: <mchehab@...nel.org>, <prabhakar.csengg@...il.com>
Subject: [PATCH] media: davinci: vpif: add missing of_node_put() in vpif_probe()
of_graph_get_next_endpoint() returns an 'endpoint' node pointer
with refcount incremented. The refcount should be decremented
before returning from vpif_probe().
Reported-by: Hulk Robot <hulkci@...wei.com>
Signed-off-by: Yang Yingliang <yangyingliang@...wei.com>
---
drivers/media/platform/ti/davinci/vpif.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/media/platform/ti/davinci/vpif.c b/drivers/media/platform/ti/davinci/vpif.c
index 97ef770266af..da27da4c165a 100644
--- a/drivers/media/platform/ti/davinci/vpif.c
+++ b/drivers/media/platform/ti/davinci/vpif.c
@@ -469,6 +469,7 @@ static int vpif_probe(struct platform_device *pdev)
endpoint);
if (!endpoint)
return 0;
+ of_node_put(endpoint);
/*
* For DT platforms, manually create platform_devices for
--
2.25.1
Powered by blists - more mailing lists