lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Tue,  9 Sep 2014 19:07:05 +0800
From:	Guodong Xu <guodong.xu@...aro.org>
To:	broonie@...nel.org, lgirdwood@...il.com, shawn.guo@...aro.org,
	axel.lin@...ics.com, linux-arm-kernel@...ts.infradead.org,
	linux-kernel@...r.kernel.org, devicetree@...r.kernel.org
Cc:	Guodong Xu <guodong.xu@...aro.org>
Subject: [PATCH] regulator: mc13xxx: add missing of_node_get()

mc13xxx_parse_regulators_dt() goes through dt tree to search for regulator
sub-nodes. For each matched node, later on it will be used and registered
into a regulator_dev.

of_node_get() should be called to increase its refcount.

Signed-off-by: Guodong Xu <guodong.xu@...aro.org>
---
 drivers/regulator/mc13xxx-regulator-core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/mc13xxx-regulator-core.c b/drivers/regulator/mc13xxx-regulator-core.c
index afba024..ebc8ff1 100644
--- a/drivers/regulator/mc13xxx-regulator-core.c
+++ b/drivers/regulator/mc13xxx-regulator-core.c
@@ -195,7 +195,7 @@ struct mc13xxx_regulator_init_data *mc13xxx_parse_regulators_dt(
 				p->id = i;
 				p->init_data = of_get_regulator_init_data(
 							&pdev->dev, child);
-				p->node = child;
+				p->node = of_node_get(child);
 				p++;
 
 				parsed++;
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ