From: Liang He Date: Thu, 16 Jun 2022 01:46:36 +0000 (+0800) Subject: soc/tegra: fuse: Add missing of_node_put() in tegra_init_fuse() X-Git-Tag: v6.1-rc1~155^2~12^2~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e941712cccab8a96f03b5d3274159c1ed338efee;p=thirdparty%2Fkernel%2Flinux.git soc/tegra: fuse: Add missing of_node_put() in tegra_init_fuse() In this function, of_find_matching_node() will return a node pointer with refcount incremented. We should use of_node_put() when the "np" pointer is not used anymore. Signed-off-by: Liang He Signed-off-by: Thierry Reding --- diff --git a/drivers/soc/tegra/fuse/fuse-tegra.c b/drivers/soc/tegra/fuse/fuse-tegra.c index b0a8405dbdb19..6542267a224d2 100644 --- a/drivers/soc/tegra/fuse/fuse-tegra.c +++ b/drivers/soc/tegra/fuse/fuse-tegra.c @@ -568,6 +568,7 @@ static int __init tegra_init_fuse(void) np = of_find_matching_node(NULL, car_match); if (np) { void __iomem *base = of_iomap(np, 0); + of_node_put(np); if (base) { tegra_enable_fuse_clk(base); iounmap(base);