pfuze100-regulator: Fix of_node_get() parameter
authorFabio Estevam <fabio.estevam@freescale.com>
Wed, 19 Feb 2014 02:46:14 +0000 (23:46 -0300)
committerMark Brown <broonie@linaro.org>
Wed, 19 Feb 2014 04:15:02 +0000 (13:15 +0900)
Since commit d7857c42 (regulator: pfuze100: Use of_get_child_by_name) we get
the following probe failure:

pfuze100-regulator 1-0008: Full layer: 1, Metal layer: 0
pfuze100-regulator 1-0008: FAB: 0, FIN: 0
pfuze100-regulator 1-0008: regulators node not found
pfuze100-regulator: probe of 1-0008 failed with error -22

Now that of_get_child_by_name() is used we should adjust the device_node pointer
'np' to not get the parent node anymore.

Suggested-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@linaro.org>
drivers/regulator/pfuze100-regulator.c

index 3cb19aef475dec76c002d9b57fb3a51ae745f83f..9bd8b68f3d98ab4d73deca540a97b5d2ec2d2ba7 100644 (file)
@@ -250,7 +250,7 @@ static int pfuze_parse_regulators_dt(struct pfuze_chip *chip)
        struct device_node *np, *parent;
        int ret;
 
-       np = of_node_get(dev->parent->of_node);
+       np = of_node_get(dev->of_node);
        if (!np)
                return 0;
 
This page took 0.024813 seconds and 5 git commands to generate.