Skip to contentSkip to conversation

cpufreq: tegra124: add missing of_node_put()

PATCH Applied Yangtao Li 3 participants 3 messages Feb 4, 2019

Subsystems (3)
lore
Share & tools
lore

Yangtao Li

author
#0 lore raw

PATCH v2 1/1 cpufreq: tegra124: add missing of_node_put()

of_cpu_device_node_get() will increase the refcount of device_node, it is necessary to call of_node_put() at the end to release the refcount.

Fixes 9eb15dbbfa1a2 ("cpufreq: Add cpufreq driver for Tegra124")
Cc <[email protected]> # 4.4+

---
v2:
- move of_node_put() to the very end

---
 drivers/cpufreq/tegra124-cpufreq.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/cpufreq/tegra124-cpufreq.c +2 -0
index 43530254201a..4bb154f6c54c 100644
@@ -134,6 +134,8 @@ static int tegra124_cpufreq_probe(struct platform_device *pdev)
 
 	platform_set_drvdata(pdev, priv);
 
+	of_node_put(np);
+
 	return 0;
 
 out_switch_to_pllx:
Signature · 1 line
2.17.0
Acked-by on v2 1/1
#1 lore raw
Quoted 7 lines · Yangtao Li

of_cpu_device_node_get() will increase the refcount of device_node, it is necessary to call of_node_put() at the end to release the refcount.

Fixes 9eb15dbbfa1a2 ("cpufreq: Add cpufreq driver for Tegra124")
Cc <[email protected]> # 4.4+
Quoted 6 lines

---
v2:
- move of_node_put() to the very end

---
 drivers/cpufreq/tegra124-cpufreq.c | 2 ++
 1 file changed, 2 insertions(+)
maintainer Applied
#2 lore raw
Quoted 15 lines · Thierry Reding
Quoted 7 lines · Yangtao Li

of_cpu_device_node_get() will increase the refcount of device_node, it is necessary to call of_node_put() at the end to release the refcount.

Fixes 9eb15dbbfa1a2 ("cpufreq: Add cpufreq driver for Tegra124")
Cc <[email protected]> # 4.4+
Quoted 6 lines

---
v2:
- move of_node_put() to the very end

---
 drivers/cpufreq/tegra124-cpufreq.c | 2 ++
 1 file changed, 2 insertions(+)
Quoted 1 line

Applied. Thanks.

Signature · 1 line
viresh