Hi ,

Pls find my comments below

Regards


> -----Original Message-----
> From: Mark Brown [mailto:[email protected]]
> Sent: Wednesday, January 14, 2009 3:38 AM
> To: Pillai, Manikandan
> Cc: [email protected]
> Subject: Re: [PATCH 1/2] Include TPS6235x based Power regulator support
> 
> On Tue, Jan 13, 2009 at 01:11:08PM +0530, Manikandan Pillai wrote:
> 
> > +static
> > +int tps_6235x_probe(struct i2c_client *client, const struct i2c_device_id
> *id)
> > +{
> > +   struct  regulator_dev           *rdev = NULL;
> > +   unsigned char reg_val;
> > +   struct device *dev_child = NULL;
> 
> ...
> 
> > +   /* Register the regulators */
> > +   dev_child = device_find_child(client->adapter->dev.parent,
> > +                   (void *)regulator_consumer_name[id->driver_data],
> > +                   omap_i2c_match_child);
> > +   rdev = regulator_register(&regulators[id->driver_data],
> > +                   dev_child, client);
> 
> With current mainline this should be rewritten as:
> 
>       rdev = regulator_register(&regulators[id->driver_data],
>                                 &client->dev, client);
> 
> though I'm not sure what's currently merged up into the OMAP trees.
[Pillai, Manikandan] 
The issue is that passing the initial value for regulators is done by

struct regulator_init_data *init_data = dev->platform_data;

in regulator_register() function. Do we have a way to initialize the
platform data for the i2c client struct.

> 
> As discussed in the followup to your previous patch the register I/O
> functions should also be moved into this driver.

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to