mbox series

[0/8] regulator: support Silergy SY8824C/SY8824E etc.

Message ID 20190827163252.4982af95@xhacker.debian
Headers show
Series regulator: support Silergy SY8824C/SY8824E etc. | expand

Message

Jisheng Zhang Aug. 27, 2019, 8:44 a.m. UTC
Add support for Silergy SY8824C/SY8824E/SY20276/SY20278 regulator.

Jisheng Zhang (8):
  regulator: add binding for the SY8824C voltage regulator
  regulator: add support for SY8824C regulator
  dt-bindings: sy8824x: Document SY8824E support
  regulator: sy8824x: add SY8824E support
  dt-bindings: sy8824x: Document SY20276 support
  regulator: sy8824x: add SY20276 support
  dt-bindings: sy8824x: Document SY20278 support
  regulator: sy8824x: add SY20278 support

 .../devicetree/bindings/regulator/sy8824x.txt |  24 ++
 drivers/regulator/Kconfig                     |   7 +
 drivers/regulator/Makefile                    |   1 +
 drivers/regulator/sy8824x.c                   | 231 ++++++++++++++++++
 4 files changed, 263 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/regulator/sy8824x.txt
 create mode 100644 drivers/regulator/sy8824x.c

Comments

Mark Brown Aug. 27, 2019, 7:44 p.m. UTC | #1
On Tue, Aug 27, 2019 at 08:45:33AM +0000, Jisheng Zhang wrote:

This looks mostly good and I'll apply it, a couple of small
things though:

> @@ -0,0 +1,192 @@
> +// SPDX-License-Identifier: GPL-2.0
> +/*
> + * SY8824C regulator driver
> + *

Please send a patch which updates the entire comment block to be
C++ style so it looks consistent.

> +#define BUCK_EN		(1 << 7)
> +#define MODE		(1 << 6)
> +

Please also add prefixes to these to namespace them, especially
MODE is likely to collide with something later.
Jisheng Zhang Aug. 28, 2019, 3:38 a.m. UTC | #2
Hi Mark,

On Tue, 27 Aug 2019 20:44:37 +0100 Mark Brown wrote:

> On Tue, Aug 27, 2019 at 08:45:33AM +0000, Jisheng Zhang wrote:
> 
> This looks mostly good and I'll apply it, a couple of small
> things though:
> 
> > @@ -0,0 +1,192 @@
> > +// SPDX-License-Identifier: GPL-2.0
> > +/*
> > + * SY8824C regulator driver
> > + *  
> 
> Please send a patch which updates the entire comment block to be
> C++ style so it looks consistent.

Do you mean update the following style

A:

// SPDX-License-Identifier: GPL-2.0
/*
 * SY8824C regulator driver
 * ...


as B:

// SPDX-License-Identifier: GPL-2.0
// SY8824C regulator driver
// ...

I'm not sure which style is correct. But I see B is commonly used
in lots .c source files in other dirs, such as kernel/ mm/ etc.

Could you please clarify?

Thanks

> 
> > +#define BUCK_EN		(1 << 7)
> > +#define MODE		(1 << 6)
> > +  
> 
> Please also add prefixes to these to namespace them, especially
> MODE is likely to collide with something later.

good idea. Will do in newer version
Jisheng Zhang Aug. 28, 2019, 5:49 a.m. UTC | #3
On Wed, 28 Aug 2019 11:27:05 +0800 Jisheng Zhang wrote:

> Hi Mark,
> 
> On Tue, 27 Aug 2019 20:44:37 +0100 Mark Brown wrote:
> 
> > On Tue, Aug 27, 2019 at 08:45:33AM +0000, Jisheng Zhang wrote:
> > 
> > This looks mostly good and I'll apply it, a couple of small
> > things though:
> >   
> > > @@ -0,0 +1,192 @@
> > > +// SPDX-License-Identifier: GPL-2.0
> > > +/*
> > > + * SY8824C regulator driver
> > > + *    
> > 
> > Please send a patch which updates the entire comment block to be
> > C++ style so it looks consistent.  
> 
> Do you mean update the following style
> 
> A:
> 
> // SPDX-License-Identifier: GPL-2.0
> /*
>  * SY8824C regulator driver
>  * ...
> 
> 
> as B:
> 
> // SPDX-License-Identifier: GPL-2.0
> // SY8824C regulator driver
> // ...
> 
> I'm not sure which style is correct. But I see B is commonly used

sorry, typo. I mean "I see A is commonly used ..."

> in lots .c source files in other dirs, such as kernel/ mm/ etc.
> 
> Could you please clarify?
> 
> Thanks
> 
> >   
> > > +#define BUCK_EN		(1 << 7)
> > > +#define MODE		(1 << 6)
> > > +    
> > 
> > Please also add prefixes to these to namespace them, especially
> > MODE is likely to collide with something later.  
> 
> good idea. Will do in newer version
Mark Brown Aug. 28, 2019, 10:13 a.m. UTC | #4
On Wed, Aug 28, 2019 at 03:38:29AM +0000, Jisheng Zhang wrote:
> On Tue, 27 Aug 2019 20:44:37 +0100 Mark Brown wrote:

> > 
> > Please send a patch which updates the entire comment block to be
> > C++ style so it looks consistent.

> Do you mean update the following style

> A:
> 
> // SPDX-License-Identifier: GPL-2.0
> /*
>  * SY8824C regulator driver
>  * ...

> as B:

> // SPDX-License-Identifier: GPL-2.0
> // SY8824C regulator driver
> // ...

> I'm not sure which style is correct. But I see B is commonly used
> in lots .c source files in other dirs, such as kernel/ mm/ etc.

Yes, please - update to style B.