summaryrefslogtreecommitdiff
path: root/drivers/regulator/max77693.c
diff options
context:
space:
mode:
authorSachin Kamat <sachin.kamat@linaro.org>2014-02-14 15:49:48 +0400
committerMark Brown <broonie@linaro.org>2014-02-15 01:08:31 +0400
commit4fa43a4a6f8d1b7a8f32e7ba654f36ef86ab1e56 (patch)
treede4dcc79b2d3398f7e5a7334f806000c3393a003 /drivers/regulator/max77693.c
parent38dbfb59d1175ef458d006556061adeaa8751b72 (diff)
downloadlinux-4fa43a4a6f8d1b7a8f32e7ba654f36ef86ab1e56.tar.xz
regulator: max77693: 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>
Diffstat (limited to 'drivers/regulator/max77693.c')
-rw-r--r--drivers/regulator/max77693.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/regulator/max77693.c b/drivers/regulator/max77693.c
index 5fb899f461d0..057d040e6feb 100644
--- a/drivers/regulator/max77693.c
+++ b/drivers/regulator/max77693.c
@@ -170,7 +170,7 @@ static int max77693_pmic_dt_parse_rdata(struct device *dev,
struct max77693_regulator_data *tmp;
int i, matched = 0;
- np = of_find_node_by_name(dev->parent->of_node, "regulators");
+ np = of_get_child_by_name(dev->parent->of_node, "regulators");
if (!np)
return -EINVAL;