Skip to contentSkip to conversation

arch: arm: mach-keystone: Add missing of_node_put() in pm_domain.c

PATCH Superseded heliang 1 participant 1 message Jun 15, 2022

Subsystems (3)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

heliang

author
#0 lore raw

PATCH 1/1 arch: arm: mach-keystone: Add missing of_node_put() in pm_domain.c

In keystone_pm_runtime_init(), of_find_matching_node() will return a node pointer with refcount incremented. We should use of_node_put() when it is not used anymore.

---
 arch/arm/mach-keystone/pm_domain.c | 2 ++
 1 file changed, 2 insertions(+)
arch/arm/mach-keystone/pm_domain.c +2 -0
index 5eea01cbecf0..50a08721a8d8 100644
@@ -44,6 +44,8 @@ int __init keystone_pm_runtime_init(void)
 	if (!np)
 		return 0;
 
+	of_node_put(np);
+
 	pm_clk_add_notifier(&platform_bus_type, &platform_domain_notifier);
 
 	return 0;
Signature · 1 line
2.25.1