Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-27 Thread Matthijs Kooijman
Hi folks, I don't think we are consistent in any way. PowerPC sets up a 32 bit DMA mask for all devices during DT probe from arch code, while the common code sets up coherent_dma_mask but not dma_mask, except for AMBA devices, which also get the 32 bit mask. The MIPS Octeon and PowerPC PS3

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-27 Thread Peter Vasil
Hi again, the patch works fine on my WM8850 netbook. I didn't get any unused-function warning on build, most likely because I have CONFIG_PM set in kernel config. Regards, Peter -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-26 Thread Tony Prisk
On Mon, 2013-03-25 at 19:03 +, Arnd Bergmann wrote: On Monday 25 March 2013, Tony Prisk wrote: I'll take a look at this and get back to you before Easter. Great, thanks a lot! Arnd I couldn't get this patch to apply cleanly on 3.9-rc2, -rc3 or -rc4 for some reason. Applied

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-26 Thread Peter Vasil
On Tue, Mar 26, 2013 at 7:34 AM, Tony Prisk li...@prisktech.co.nz wrote: On Mon, 2013-03-25 at 19:03 +, Arnd Bergmann wrote: On Monday 25 March 2013, Tony Prisk wrote: I'll take a look at this and get back to you before Easter. Great, thanks a lot! Arnd I couldn't get

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-26 Thread Tony Prisk
Hi Alan, I noticed when testing Arnd's patch that I get an unused function warning: drivers/usb/host/ehci-q.c:1320:13: warning: ‘unlink_empty_async_suspended’ defined but not used [-Wunused-function] It looks like this function is called from ehci-hub.c:ehci_bus_suspend() which is wrapped in a

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-26 Thread Alan Stern
On Tue, 26 Mar 2013, Tony Prisk wrote: Hi Alan, I noticed when testing Arnd's patch that I get an unused function warning: drivers/usb/host/ehci-q.c:1320:13: warning: ‘unlink_empty_async_suspended’ defined but not used [-Wunused-function] It looks like this function is called from

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-26 Thread Alan Stern
On Mon, 25 Mar 2013, Arnd Bergmann wrote: On Monday 25 March 2013, Alan Stern wrote: + if (!dev-dev.platform_data) { + dev-dev.platform_data = ehci_platform_defaults; + dev-dev.dma_mask = dev-dev.coherent_dma_mask; +

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-26 Thread Arnd Bergmann
On Tuesday 26 March 2013, Alan Stern wrote: That's up to platform guys. I wasn't aware of any common practice whereby drivers would fill in a missing dma_mask, except in the DT case. I don't think we are consistent in any way. PowerPC sets up a 32 bit DMA mask for all devices during DT

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-26 Thread Alan Stern
On Tue, 26 Mar 2013, Arnd Bergmann wrote: I think it's a horrible mess and if anyone has an idea of what the right solution is, we should probably implement that, but from what I see here, setting a 32-bit dma mask unless there is already one is a reasonable choice. Okay. Don't forget

[PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Arnd Bergmann
This lets us use the ehci-generic driver on platforms without special requirements for their ehci controllers. In particular, this is true for the vt8500/wm8x50 platforms, which currently have a separate driver that causes problems with multiplatform configurations. Cc: Tony Prisk

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Felipe Balbi
Hi, On Mon, Mar 25, 2013 at 04:20:42PM +, Arnd Bergmann wrote: This lets us use the ehci-generic driver on platforms without special requirements for their ehci controllers. In particular, this is true for the vt8500/wm8x50 platforms, which currently have a separate driver that causes

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Alan Stern
On Mon, 25 Mar 2013, Felipe Balbi wrote: @@ -62,22 +64,26 @@ static const struct ehci_driver_overrides platform_overrides __initdata = { .reset =ehci_platform_reset, }; +static struct usb_ehci_pdata ehci_platform_defaults; this ehci_platform_defaults is quite a

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Tony Prisk
On Mon, 2013-03-25 at 16:20 +, Arnd Bergmann wrote: This lets us use the ehci-generic driver on platforms without special requirements for their ehci controllers. In particular, this is true for the vt8500/wm8x50 platforms, which currently have a separate driver that causes problems with

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Arnd Bergmann
On Monday 25 March 2013, Tony Prisk wrote: I'll take a look at this and get back to you before Easter. Great, thanks a lot! Arnd -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Felipe Balbi
On Mon, Mar 25, 2013 at 01:47:19PM -0400, Alan Stern wrote: On Mon, 25 Mar 2013, Felipe Balbi wrote: @@ -62,22 +64,26 @@ static const struct ehci_driver_overrides platform_overrides __initdata = { .reset =ehci_platform_reset, }; +static struct usb_ehci_pdata

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Arnd Bergmann
On Monday 25 March 2013, Alan Stern wrote: On Mon, 25 Mar 2013, Felipe Balbi wrote: this ehci_platform_defaults is quite a hack. Would be much better to see a proper re-factoring of the code so that it actually learns about DT and platform_data. So, if dev-dev.platform_data is NULL,

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Alan Stern
On Mon, 25 Mar 2013, Arnd Bergmann wrote: This lets us use the ehci-generic driver on platforms without special requirements for their ehci controllers. In particular, this is true for the vt8500/wm8x50 platforms, which currently have a separate driver that causes problems with multiplatform

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Arnd Bergmann
On Monday 25 March 2013, Alan Stern wrote: + if (!dev-dev.platform_data) { + dev-dev.platform_data = ehci_platform_defaults; + dev-dev.dma_mask = dev-dev.coherent_dma_mask; + dev-dev.coherent_dma_mask = DMA_BIT_MASK(32); In view of Felipe's

Re: [PATCH] USB: EHCI: DT support for generic bus glue

2013-03-25 Thread Tony Prisk
On Mon, 2013-03-25 at 22:23 +, Arnd Bergmann wrote: On Monday 25 March 2013, Alan Stern wrote: + if (!dev-dev.platform_data) { + dev-dev.platform_data = ehci_platform_defaults; + dev-dev.dma_mask = dev-dev.coherent_dma_mask; +