mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] arm-cci: Fix refcount leak in cci_probe
@ 2024-08-19  9:04 Ma Ke
  2024-08-19 14:28 ` Suzuki K Poulose
  0 siblings, 1 reply; 2+ messages in thread
From: Ma Ke @ 2024-08-19  9:04 UTC (permalink / raw)
  To: make24, nico, will, suzuki.poulose, punitagrawal, akpm
  Cc: linux-kernel, stable

Add the missing of_node_put() to release the refcount incremented
by of_find_matching_node().

Cc: stable@vger.kernel.org
Fixes: f6b9e83ce05e ("arm-cci: Rearrange code for splitting PMU vs driver code")
Signed-off-by: Ma Ke <make24@iscas.ac.cn>
---
 drivers/bus/arm-cci.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/bus/arm-cci.c b/drivers/bus/arm-cci.c
index b8184a903583..6be7b05b5ff1 100644
--- a/drivers/bus/arm-cci.c
+++ b/drivers/bus/arm-cci.c
@@ -548,6 +548,7 @@ static int cci_probe(void)
 	}
 	if (ret || !cci_ctrl_base) {
 		WARN(1, "unable to ioremap CCI ctrl\n");
+		of_node_put(np);
 		return -ENXIO;
 	}
 
-- 
2.25.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-08-19 14:28 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-08-19  9:04 [PATCH] arm-cci: Fix refcount leak in cci_probe Ma Ke
2024-08-19 14:28 ` Suzuki K Poulose

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®