diff options
author | Sachin Kamat <sachin.kamat@linaro.org> | 2014-02-14 17:20:00 +0530 |
---|---|---|
committer | Robin Gong <b38343@freescale.com> | 2014-05-26 14:01:21 +0800 |
commit | ce1917efa634a653e8a6f28e6b544084bbde05a2 (patch) | |
tree | 2a146af96ad4d29f31ffc96638358c761376eaeb /drivers | |
parent | 097577d59625e2544eb8269c043f61eac2086352 (diff) |
regulator: pfuze100: Use of_get_child_by_name
of_find_node_by_name walks the allnodes list, and can thus walk
outside of the parent node. Use of_get_child_by_name instead.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@linaro.org>
(cherry picked from commit 4d286178d55cc5811d50750a44eb729252adef11)
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/regulator/pfuze100-regulator.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/regulator/pfuze100-regulator.c b/drivers/regulator/pfuze100-regulator.c index 21114f7aaced..15059c74cc8e 100644 --- a/drivers/regulator/pfuze100-regulator.c +++ b/drivers/regulator/pfuze100-regulator.c @@ -299,7 +299,7 @@ static int pfuze_parse_regulators_dt(struct pfuze_chip *chip) if (!np) return 0; - parent = of_find_node_by_name(np, "regulators"); + parent = of_get_child_by_name(np, "regulators"); if (!parent) { dev_err(dev, "regulators node not found\n"); return -EINVAL; |