Re: [PATCH 2/3] power: supply: Add driver for Microchip UCS1002

From: Guenter Roeck
Date: Fri Apr 26 2019 - 13:04:44 EST


On Fri, Apr 26, 2019 at 06:51:51PM +0200, Enric Balletbo Serra wrote:
> Hi Andrey,
>
> Many thanks to push this upstream. Actually this the fifth version [1]
> of this patchset. I think that is interesting for the maintainers
> maintain the history and the changelog.
>
> [1] https://lkml.org/lkml/2016/3/14/233
>
> Missatge de Andrey Smirnov <andrew.smirnov@xxxxxxxxx> del dia dc., 17
> dâabr. 2019 a les 10:46:
> >
> > Add driver for Microchip UCS1002 Programmable USB Port Power
> > Controller with Charger Emulation. The driver exposed a power supply
> > device to control/monitor various parameter of the device as well as a
> > regulator to allow controlling VBUS line.
> >
> > Signed-off-by: Andrey Smirnov <andrew.smirnov@xxxxxxxxx>
> > Cc: Chris Health <cphealy@xxxxxxxxx>
> > Cc: Lucas Stach <l.stach@xxxxxxxxxxxxxx>
> > Cc: Fabio Estevam <fabio.estevam@xxxxxxx>
> > Cc: Guenter Roeck <linux@xxxxxxxxxxxx>
> > Cc: Sebastian Reichel <sre@xxxxxxxxxx>
> > Cc: linux-kernel@xxxxxxxxxxxxxxx
> > Cc: linux-pm@xxxxxxxxxxxxxxx
> > ---

...

> > + static const int bit_weights_uAh[BITS_PER_TYPE(u32)] = {
> > + 0, 0, 0, 0, 0, 0, 3, 5,
> > +
>
> nit: I personally don't like these empty lines here.
>
I stumbled over those as well, but then I realized that they
split up the 32 bit into bytes, so it does make some sense.

Guenter