Re: Query: Phy: How to find consumer device on dt platform

2014-01-29 Thread Pratyush Anand
On Wed, Jan 29, 2014 at 10:24:35PM +0800, Arnd Bergmann wrote: > On Wednesday 29 January 2014, Pratyush Anand wrote: > > On Wed, Jan 29, 2014 at 01:41:56PM +0800, Kishon Vijay Abraham I wrote: > > > > > > > > I would instead recommend making the mode of the PHY device the > > > > argument to the p

Re: Query: Phy: How to find consumer device on dt platform

2014-01-29 Thread Arnd Bergmann
On Wednesday 29 January 2014, Pratyush Anand wrote: > On Wed, Jan 29, 2014 at 01:41:56PM +0800, Kishon Vijay Abraham I wrote: > > > > > > I would instead recommend making the mode of the PHY device the > > > argument to the phy handle in DT, so that the sata node uses > > > > > > phys = <&phyA

Re: Query: Phy: How to find consumer device on dt platform

2014-01-29 Thread Arnd Bergmann
On Wednesday 29 January 2014, Kishon Vijay Abraham I wrote: > Hi, > > On Wednesday 29 January 2014 02:56 AM, Arnd Bergmann wrote: > > On Tuesday 28 January 2014, Kishon Vijay Abraham I wrote: > >>> I have a common set of registers, which need to be programmed > >>> differently for PCIe and SATA du

Re: Query: Phy: How to find consumer device on dt platform

2014-01-29 Thread Pratyush Anand
Hi Arnd / Kishon, Thanks for your inputs. On Wed, Jan 29, 2014 at 01:41:56PM +0800, Kishon Vijay Abraham I wrote: > Hi, > > On Wednesday 29 January 2014 02:56 AM, Arnd Bergmann wrote: > > On Tuesday 28 January 2014, Kishon Vijay Abraham I wrote: > >>> I have a common set of registers, which need

Re: Query: Phy: How to find consumer device on dt platform

2014-01-28 Thread Kishon Vijay Abraham I
Hi, On Wednesday 29 January 2014 02:56 AM, Arnd Bergmann wrote: > On Tuesday 28 January 2014, Kishon Vijay Abraham I wrote: >>> I have a common set of registers, which need to be programmed >>> differently for PCIe and SATA during phy init/exit. >> >> One way is differentiate using different compa

Re: Query: Phy: How to find consumer device on dt platform

2014-01-28 Thread Arnd Bergmann
On Tuesday 28 January 2014, Kishon Vijay Abraham I wrote: > > I have a common set of registers, which need to be programmed > > differently for PCIe and SATA during phy init/exit. > > One way is differentiate using different compatible strings fro pcie and sata > and use of_device_is_compatible to

Re: Query: Phy: How to find consumer device on dt platform

2014-01-28 Thread Kishon Vijay Abraham I
Hi, On Tuesday 28 January 2014 07:43 PM, Pratyush Anand wrote: > Hi Kishon, > > I have a phy driver which has to be used by two different consumer > driver, say pcie and sata. I assume you have multiple instances of the same IP and you have a single driver for it? > > I have a common set of reg