Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1525549

Re: [PATCH v3 3/5] i2c: designware: Add slave definitions

From Rob Herring <robh@kernel.org>
Newsgroups linux.kernel
Subject Re: [PATCH v3 3/5] i2c: designware: Add slave definitions
Date 2016-11-18 18:10 +0100
Message-ID <sEUPM-1xM-27@gated-at.bofh.it> (permalink)
References <sEPwJ-6s7-5@gated-at.bofh.it> <sEPwJ-6s7-3@gated-at.bofh.it> <sEQCu-75C-45@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, Nov 18, 2016 at 02:35:52PM +0200, Andy Shevchenko wrote:
> On Fri, 2016-11-18 at 11:19 +0000, Luis Oliveira wrote:
> >  - Add slave defintitions to i2c-designware-core
> >  - Changes in Kconfig to auto-enable I2C_SLAVE when compiling the
> > modules
> >  - Add compatible string to designware-core.txt explaining the
> > devicetree bindings
> > 
> 
> 
> > --- a/Documentation/devicetree/bindings/i2c/i2c-designware.txt
> > +++ b/Documentation/devicetree/bindings/i2c/i2c-designware.txt
> > @@ -2,7 +2,9 @@
> >  
> >  Required properties :
> >  
> > - - compatible : should be "snps,designware-i2c"
> > + - compatible : should be:
> > +   - "snps,designware-i2c" to setup the hardware block as I2C master.
> > +   - "snps,designware-i2c-slave" to setup the hardware block as I2C
> > slave.
> 
> Not sure about this one.
> 
> Compatible string is more generic than list of modes. Basically you have
> to add a property which selects mode.

Yes, agreed. And come up with a common property.

> DT people's ACK is a must for this change.
> 
> 
> --- a/drivers/i2c/busses/Kconfig
> > +++ b/drivers/i2c/busses/Kconfig
> > @@ -470,6 +470,7 @@ config I2C_DESIGNWARE_CORE
> >  config I2C_DESIGNWARE_PLATFORM
> >  	tristate "Synopsys DesignWare Platform"
> >  	select I2C_DESIGNWARE_CORE
> > +	select I2C_SLAVE
> > 
> 
> Common rule, generic dependencies usually go first
> 
> 	select I2C_SLAVE
>  	select I2C_DESIGNWARE_CORE
> 
> -- 
> Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> Intel Finland Oy

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v3 3/5] i2c: designware: Add slave definitions Luis Oliveira <Luis.Oliveira@synopsys.com> - 2016-11-18 12:30 +0100
  Re: [PATCH v3 3/5] i2c: designware: Add slave definitions Andy Shevchenko <andriy.shevchenko@linux.intel.com> - 2016-11-18 13:40 +0100
    Re: [PATCH v3 3/5] i2c: designware: Add slave definitions Rob Herring <robh@kernel.org> - 2016-11-18 18:10 +0100
      Re: [PATCH v3 3/5] i2c: designware: Add slave definitions Luis Oliveira <Luis.Oliveira@synopsys.com> - 2016-11-23 15:50 +0100

csiph-web