regulator: tps62360: dt: initialize of_node param for regulator register.
authorLaxman Dewangan <ldewangan@nvidia.com>
Sun, 20 May 2012 16:18:47 +0000 (21:48 +0530)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Sun, 20 May 2012 17:22:41 +0000 (18:22 +0100)
Initialize config.of_node for regulator before registering.
This is needed for DT based regulator support.
Regulator stores this of_node value in rdev->dev.of_node
and used for lookup when client ask for regulator_get().

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
drivers/regulator/tps62360-regulator.c

index b5be0d0f9f12d68ba3e5937b3100aa55acb83038..e534269ed44aa2afebcd4cc1c7e509354aa92877 100644 (file)
@@ -490,6 +490,7 @@ static int __devinit tps62360_probe(struct i2c_client *client,
        config.dev = &client->dev;
        config.init_data = pdata->reg_init_data;
        config.driver_data = tps;
+       config.of_node = client->dev.of_node;
 
        /* Register the regulators */
        rdev = regulator_register(&tps->desc, &config);