[PATCH 4/4] regulator: add max8925 support

Liam Girdwood lrg at slimlogic.co.uk
Mon Jan 4 10:47:18 EST 2010


On Fri, 2009-12-25 at 00:27 -0500, Haojian Zhuang wrote:
> On Wed, Dec 23, 2009 at 9:30 AM, Mark Brown
> <broonie at opensource.wolfsonmicro.com> wrote:
> > On Wed, Dec 23, 2009 at 04:39:59AM -0500, Haojian Zhuang wrote:
> >
> >> +#define MAX8925_REGULATOR_DRIVER(_name)                              \
> >> +{                                                            \
> >> +     .driver         = {                                     \
> >> +             .name   = "max8925-" #_name,                    \
> >> +             .owner  = THIS_MODULE,                          \
> >> +     },                                                      \
> >> +     .probe          = max8925_regulator_probe,              \
> >> +     .remove         = __devexit_p(max8925_regulator_remove),\
> >> +}
> >> +
> >> +static struct platform_driver max8925_regulator_driver[] = {
> >> +     MAX8925_REGULATOR_DRIVER(sd1),
> >> +     MAX8925_REGULATOR_DRIVER(sd2),
> >> +     MAX8925_REGULATOR_DRIVER(sd3),
> >> +     MAX8925_REGULATOR_DRIVER(ldo1),
> >> +     MAX8925_REGULATOR_DRIVER(ldo2),
> >
> > Since these driver structures differ only in name there seems to be no
> > need to define more than one for the bucks and one for the LDOs - the
> > code in the driver doesn't actually seem to need it.  The .id field of
> > the driver structure can be set to give the device numbers.
> >
> >> +}
> >> +module_init(max8925_regulator_init);
> >
> > subsys_initcall()
> >
> >> +MODULE_LICENSE("GPL");
> >> +MODULE_AUTHOR("Haojian Zhuang <haojian.zhuang at marvell.com>");
> >> +MODULE_DESCRIPTION("Regulator Driver for Maxim 8925 PMIC");
> >> +MODULE_ALIAS("platform:max8925-regulator");
> >
> > This MODULE_ALIAS won't actually work - the name doesn't match up with
> > the names of the drivers or the devices.
> >
> 
> Updated the serie of patches.

I'm fine with this now but it doesn't apply against voltage for-next.
Could you recreate against for-next.

Btw, what is the status of the other PMIC regulator patch you have.
Iirc, it was waiting on some PMIC core change in it's mfd driver ?

Thanks

Liam




More information about the linux-arm-kernel mailing list