Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-26 Thread Rafael J. Wysocki
On Sunday, May 22, 2011, Russell King - ARM Linux wrote: On Sat, May 21, 2011 at 11:42:34AM -0600, Grant Likely wrote: Russell, it seems to me that the primary behaviour that amba_bus has over platform_bus is the clock management, and secondarily verification of the type of device by the

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-26 Thread Linus Walleij
2011/5/22 Arnd Bergmann a...@arndb.de: On Saturday 21 May 2011 19:42:34 Grant Likely wrote: 1) drop amba-bus entirely and use platform_device everywhere, similar to what OMAP has done 2) strictly create amba_devices for nodes compatible with arm,amba-device 3) be intelligent about amba device

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-26 Thread Linus Walleij
2011/5/24 Rob Herring robherri...@gmail.com: I think having arm,amba-deviceid is not needed. The current code does nothing but warn if it doesn't match the h/w value. The drivers already have a list of id's that they support and the amba bus only matches against the h/w id value. The only use

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-24 Thread Rob Herring
Grant, On 05/23/2011 10:09 AM, Grant Likely wrote: On Mon, May 23, 2011 at 3:58 AM, Russell King - ARM Linux li...@arm.linux.org.uk wrote: On Mon, May 23, 2011 at 11:37:04AM +0200, Kristoffer Glembo wrote: Grant Likely wrote: In the case we're talking about the bus really is an AMBA bus,

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-24 Thread Shawn Guo
On Tue, May 24, 2011 at 10:03:35AM -0500, Rob Herring wrote: Grant, On 05/23/2011 10:09 AM, Grant Likely wrote: On Mon, May 23, 2011 at 3:58 AM, Russell King - ARM Linux li...@arm.linux.org.uk wrote: On Mon, May 23, 2011 at 11:37:04AM +0200, Kristoffer Glembo wrote: Grant Likely wrote:

RE: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-23 Thread Stephen Neuendorffer
: [PATCH 2/2] drivers/amba: probe via device tree On Fri, May 20, 2011 at 09:08:17AM -0700, Stephen Neuendorffer wrote: That is how it is currently, but the reality is that I only have 1 bus with both ARM Primecell peripherals and other peripherals which are standard platform bus devices. i2c

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-23 Thread Grant Likely
On Mon, May 23, 2011 at 3:58 AM, Russell King - ARM Linux li...@arm.linux.org.uk wrote: On Mon, May 23, 2011 at 11:37:04AM +0200, Kristoffer Glembo wrote: Grant Likely wrote: In the case we're talking about the bus really is an AMBA bus, and all the devices on it are in some sense real amba

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-23 Thread Russell King - ARM Linux
On Mon, May 23, 2011 at 08:00:15AM -0700, Stephen Neuendorffer wrote: To be specific (whether this is 'to shreds' or not, you can decide). 1. amba_bus expects the old ARM primcell ID. The one in the new A9 IP appears to be different. (b105900d instead of b105f00d) Ok, so we can update to

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-22 Thread Arnd Bergmann
On Saturday 21 May 2011 19:42:34 Grant Likely wrote: 1) drop amba-bus entirely and use platform_device everywhere, similar to what OMAP has done 2) strictly create amba_devices for nodes compatible with arm,amba-device 3) be intelligent about amba device creation; create an amba_device only

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-22 Thread Rob Herring
On 05/21/2011 06:47 PM, Russell King - ARM Linux wrote: On Sat, May 21, 2011 at 11:42:34AM -0600, Grant Likely wrote: Russell, it seems to me that the primary behaviour that amba_bus has over platform_bus is the clock management, and secondarily verification of the type of device by the device

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-21 Thread Rob Herring
On 05/20/2011 11:00 PM, Segher Boessenkool wrote: The ARM definition of AMBA encompasses a lot of things. It is the definition of the AXI, AHB and APB buses. So the device tree, which describes the hardware, should call the buses axi, ahb or apb as appropriate, and describe the actual physical

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-21 Thread Segher Boessenkool
Identifying actual AMBA devices is already done. The question is how to scan the tree for them and how that relates to regular platform devices. The AMBA devices have a binding like this: compatible = arm,pl011, arm,amba-device; arm,amba-deviceid = 0x00341011; Excellent -- so you just find

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-21 Thread Grant Likely
- discuss-bounces+stephen.neuendorffer=xilinx@lists.ozlabs.org] On Behalf Of Rob Herring Sent: Friday, May 20, 2011 8:18 AM To: Arnd Bergmann Cc: devicetree-discuss@lists.ozlabs.org; Jeremy Kerr; linux-arm-ker...@lists.infradead.org Subject: Re: [PATCH 2/2] drivers/amba: probe via device tree

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-21 Thread Grant Likely
On Sat, May 21, 2011 at 9:18 AM, Segher Boessenkool seg...@kernel.crashing.org wrote: Identifying actual AMBA devices is already done. The question is how to scan the tree for them and how that relates to regular platform devices. The AMBA devices have a binding like this: compatible =

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-21 Thread Russell King - ARM Linux
On Sat, May 21, 2011 at 11:42:34AM -0600, Grant Likely wrote: Russell, it seems to me that the primary behaviour that amba_bus has over platform_bus is the clock management, and secondarily verification of the type of device by the device id. Am I correct, or am I missing something? It

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-20 Thread Arnd Bergmann
On Friday 20 May 2011 15:24:26 Rob Herring wrote: Maybe we are looking this in the wrong way. AMBA is not really the bus, but certain types of devices on the bus. Granted, it may actually be an AMBA bus vs. vendor bus (i.MX AIPS), but that is really transparent to s/w. Separating AMBA

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-20 Thread Rob Herring
Arnd, On 05/20/2011 09:21 AM, Arnd Bergmann wrote: On Friday 20 May 2011 15:24:26 Rob Herring wrote: Maybe we are looking this in the wrong way. AMBA is not really the bus, but certain types of devices on the bus. Granted, it may actually be an AMBA bus vs. vendor bus (i.MX AIPS), but that is

RE: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-20 Thread Stephen Neuendorffer
-discuss@lists.ozlabs.org; Jeremy Kerr; linux-arm-ker...@lists.infradead.org Subject: Re: [PATCH 2/2] drivers/amba: probe via device tree Arnd, On 05/20/2011 09:21 AM, Arnd Bergmann wrote: On Friday 20 May 2011 15:24:26 Rob Herring wrote: Maybe we are looking this in the wrong way. AMBA

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-20 Thread Segher Boessenkool
The ARM definition of AMBA encompasses a lot of things. It is the definition of the AXI, AHB and APB buses. So the device tree, which describes the hardware, should call the buses axi, ahb or apb as appropriate, and describe the actual physical connections. The Linux kernel is free to ignore

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-19 Thread Grant Likely
On Thu, May 19, 2011 at 01:28:24PM -0500, Rob Herring wrote: From: Rob Herring rob.herr...@calxeda.com Add functions to parse the AMBA bus through the device tree. Based on the original version by Jeremy Kerr. This reworks the original amba bus device tree probing to be more inline with

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-19 Thread Rob Herring
Grant, On 05/19/2011 03:01 PM, Grant Likely wrote: On Thu, May 19, 2011 at 01:28:24PM -0500, Rob Herring wrote: From: Rob Herringrob.herr...@calxeda.com Add functions to parse the AMBA bus through the device tree. Based on the original version by Jeremy Kerr. This reworks the original amba

Re: [PATCH 2/2] drivers/amba: probe via device tree

2011-05-19 Thread Grant Likely
On Thu, May 19, 2011 at 06:30:23PM -0500, Rob Herring wrote: Grant, On 05/19/2011 03:01 PM, Grant Likely wrote: On Thu, May 19, 2011 at 01:28:24PM -0500, Rob Herring wrote: From: Rob Herringrob.herr...@calxeda.com Add functions to parse the AMBA bus through the device tree. Based on