diff options
author | Fabio Estevam <fabio.estevam@freescale.com> | 2014-02-20 11:47:02 -0500 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-02-23 00:34:32 -0500 |
commit | 6428789e11f056d58ed59c0c0aa7d381d0bf50f8 (patch) | |
tree | 6c6d23313ea4d0bc4bdb5511f22112f4be25ce15 /drivers/regulator/pfuze100-regulator.c | |
parent | 3e01c75a45740ef4a0ec657d7ca25ad0aa2f50e0 (diff) |
pfuze100-regulator: Return error on of_node_get() failure
If of_node_get() fails, we should return an error.
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'drivers/regulator/pfuze100-regulator.c')
-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 9bd8b68f3d98..371a55374edc 100644 --- a/drivers/regulator/pfuze100-regulator.c +++ b/drivers/regulator/pfuze100-regulator.c | |||
@@ -252,7 +252,7 @@ static int pfuze_parse_regulators_dt(struct pfuze_chip *chip) | |||
252 | 252 | ||
253 | np = of_node_get(dev->of_node); | 253 | np = of_node_get(dev->of_node); |
254 | if (!np) | 254 | if (!np) |
255 | return 0; | 255 | return -EINVAL; |
256 | 256 | ||
257 | parent = of_get_child_by_name(np, "regulators"); | 257 | parent = of_get_child_by_name(np, "regulators"); |
258 | if (!parent) { | 258 | if (!parent) { |