regulator: pass regulator_register of_node in fixed voltage driver
authorRichard Zhao <richard.zhao@linaro.org>
Sat, 31 Dec 2011 12:51:16 +0000 (20:51 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 2 Jan 2012 12:45:37 +0000 (12:45 +0000)
regulator_get needs of_node to find right regulator.

Signed-off-by: Richard Zhao <richard.zhao@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
drivers/regulator/fixed.c

index a44a017..393f039 100644 (file)
@@ -246,7 +246,8 @@ static int __devinit reg_fixed_voltage_probe(struct platform_device *pdev)
        }
 
        drvdata->dev = regulator_register(&drvdata->desc, &pdev->dev,
-                                         config->init_data, drvdata, NULL);
+                                         config->init_data, drvdata,
+                                         pdev->dev.of_node);
        if (IS_ERR(drvdata->dev)) {
                ret = PTR_ERR(drvdata->dev);
                dev_err(&pdev->dev, "Failed to register regulator: %d\n", ret);