Re: [PATCH v3 5/7] USB: EHCI: make ehci-atmel a separate driver

2013-03-30 Thread Nicolas Ferre
On 03/29/2013 09:02 PM, Alan Stern : On Thu, 28 Mar 2013, Arnd Bergmann wrote: From: Manjunath Goudar manjunath.gou...@linaro.org Separate the Atmel host controller driver from ehci-hcd host code so that it can be built as a separate driver module. This work is part of enabling

Re: [PATCH 00/27] usb: chipidea: updates for v3.10

2013-03-30 Thread Alexander Shishkin
Greg KH gre...@linuxfoundation.org writes: On Sat, Mar 30, 2013 at 02:46:16AM +0200, Alexander Shishkin wrote: Hi Greg, This is an update for chipidea usb controller driver for usb-next. Some of these patches, though mostly mine, date as far back as november 2012. Why would you hold onto

Re: [PATCH 04/27] usb: chipidea: convert events to tracepoints

2013-03-30 Thread Alexander Shishkin
Greg KH gre...@linuxfoundation.org writes: On Sat, Mar 30, 2013 at 02:46:20AM +0200, Alexander Shishkin wrote: As part of the legacy from the original driver design, we retain home-grown tracing infrastructure, complete with own ring buffer and timestamps. While it is useful for debugging

Re: [PATCH 12/27] usb: chipidea: usbmisc: rename file, struct and functions to usbmisc_imx

2013-03-30 Thread Alexander Shishkin
Greg KH gre...@linuxfoundation.org writes: On Sat, Mar 30, 2013 at 02:46:28AM +0200, Alexander Shishkin wrote: From: Michael Grzeschik m.grzesc...@pengutronix.de This driver will be used for every Freescale SoC which has this misc memory layout to control the basic usb handling. So better

Re: [PATCH 09/27] usb: chipidea: fix precedence bug in ci_requests_show()

2013-03-30 Thread Alexander Shishkin
Greg KH gre...@linuxfoundation.org writes: On Sat, Mar 30, 2013 at 02:46:25AM +0200, Alexander Shishkin wrote: From: Dan Carpenter dan.carpen...@oracle.com The intent here was to have parenthesis around the (ci-hw_ep_max / 2) so that it counts like 0 1 2 0 1 2. In the current code, the mod

[PATCH v2 00/21] usb: chipidea: updates for v3.10

2013-03-30 Thread Alexander Shishkin
Hi, Let's try again. Rebased it on top of usb-next and dropped the whole tracepoint thing, but kept the part that removes the old event buffer and other debug cleanups. So everything else is rebased on top of that and a couple of commit messages amended. Alexander Shishkin (5): usb: chipidea:

[PATCH v2 01/21] usb: chipidea: remove home-grown tracing facility

2013-03-30 Thread Alexander Shishkin
As part of the legacy from the original driver design, we retain home-grown tracing infrastructure, complete with own ring buffer and timestamps, which among other things has a performance penalty. This patch removes it. Signed-off-by: Alexander Shishkin alexander.shish...@linux.intel.com ---

[PATCH v2 03/21] usb: chipidea: move role to debugfs

2013-03-30 Thread Alexander Shishkin
Manual role switching function is there for debugging purposes, so has to move to debugfs. Signed-off-by: Alexander Shishkin alexander.shish...@linux.intel.com --- drivers/usb/chipidea/core.c | 39 -- drivers/usb/chipidea/debug.c | 54

[PATCH v2 05/21] usb: chipidea: fix precedence bug in ci_requests_show()

2013-03-30 Thread Alexander Shishkin
From: Dan Carpenter dan.carpen...@oracle.com The intent here was to have parenthesis around the (ci-hw_ep_max / 2) so that it counts like 0 1 2 0 1 2. In the current code, the mod operation happens first so it counts like 0 0 1 1 2 2. Signed-off-by: Dan Carpenter dan.carpen...@oracle.com

[PATCH v2 04/21] usb: chipidea: move debug files creation/removal to the core

2013-03-30 Thread Alexander Shishkin
Create and remove debugfs entries in hdrc probe/remove instead of start/stop of the device controller. Gadget specific will not export anything while the controller is in host mode. Signed-off-by: Alexander Shishkin alexander.shish...@linux.intel.com --- drivers/usb/chipidea/core.c |6 +-

[PATCH v2 06/21] usb: chipidea: don't redefine __ffs()

2013-03-30 Thread Alexander Shishkin
From: Felipe Balbi ba...@ti.com chipidea's ffs_nr() is pretty much what __ffs() does. Use that one instead. Signed-off-by: Felipe Balbi ba...@ti.com [rebased on top of debug infrastructure rework] Signed-off-by: Alexander Shishkin alexander.shish...@linux.intel.com ---

[PATCH v2 07/21] usb: chipidea: usbmisc: rename file, struct and functions to usbmisc_imx

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de This driver will be used for every Freescale SoC which has this misc memory layout to control the basic usb handling. So better name this driver, function and struct names in a more generic way. Reported-by: Fabio Estevam feste...@gmail.com

[PATCH v2 08/21] usb: chipidea: usbmisc: unset global varibale usbmisc on driver remove

2013-03-30 Thread Alexander Shishkin
From: Marc Kleine-Budde m...@pengutronix.de The probe function checks usbmisc to be NULL in the beginning. Without this patch the can only be loaded once. Signed-off-by: Marc Kleine-Budde m...@pengutronix.de Signed-off-by: Michael Grzeschik m.grzesc...@pengutronix.de Signed-off-by: Alexander

[PATCH v2 09/21] usb: chipidea: usbmisc: fix a potential race condition

2013-03-30 Thread Alexander Shishkin
From: Marc Kleine-Budde m...@pengutronix.de This fixes a potential race condition where the ci13xxx_imx glue code could be fast enough to call one of the usbmisc_ops before he got a valid value on the static usbmisc pointer. To fix that we first set usbmisc, then call usbmisc_set_ops().

[PATCH v2 10/21] usb: chipidea: usbmisc: prepare driver to handle more than one soc

2013-03-30 Thread Alexander Shishkin
From: Marc Kleine-Budde m...@pengutronix.de This attaches the usbmisc_ops to the of_device_id data and makes it possible to define special functions per soc. Signed-off-by: Marc Kleine-Budde m...@pengutronix.de Signed-off-by: Michael Grzeschik m.grzesc...@pengutronix.de [Alex: fixed one case of

[PATCH v2 11/21] usb: chipidea: usbmisc: add mx53 support

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de This adds mx53 as the next user of the usbmisc driver and makes it possible to disable the overcurrent-detection of the internal phy. Signed-off-by: Michael Grzeschik m.grzesc...@pengutronix.de Signed-off-by: Marc Kleine-Budde

[PATCH v2 12/21] usb: chipidea: usbmisc: add post handling and errata fix for mx25

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de This adds a post handling routine which is called after ci13xxx_add_device was called. The first user is the mx25, which has to disable the external-vbus-divider after the udc has started. Signed-off-by: Michael Grzeschik

[PATCH v2 13/21] usb: chipidea: make pci platform datas static

2013-03-30 Thread Alexander Shishkin
PCI chipideas' platform datas are not static as all such things should be. Fix it. Reported-by: Marc Kleine-Budde m...@pengutronix.de Signed-off-by: Alexander Shishkin alexander.shish...@linux.intel.com --- drivers/usb/chipidea/ci13xxx_pci.c |6 +++--- 1 file changed, 3 insertions(+), 3

[PATCH v2 14/21] usb: chipidea: big-endian support

2013-03-30 Thread Alexander Shishkin
From: Svetoslav Neykov svetos...@neykov.name Convert between big-endian and little-endian format when accessing the usb controller structures which are little-endian by specification. Fix cases where the little-endian memory layout is taken for granted. The patch doesn't have any effect on the

[PATCH v2 16/21] usb: chipidea: udc: rework ep_enable cap setting

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de This patch reworks the cap value from several read and write operations to one single operation. Signed-off-by: Michael Grzeschik m.grzesc...@pengutronix.de Reviewed-by: Felipe Balbi ba...@ti.com [Alex: removed useless isoc-related bit of code]

[PATCH v2 17/21] usb: chipidea: udc: move ZLT flag change to ep_enable

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de Its not necessary and also not specified in the datasheet to change the ZLT flag before every ep_prime. This patch moves this to the ep_enable and applies it only for non configuration endpoints. Signed-off-by: Michael Grzeschik

[PATCH v2 18/21] usb: chipidea: udc: read status of td only once in hardware_dequeue

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de This patch changes the read of the td status to one atomic operation to analyse coherent bits. Signed-off-by: Michael Grzeschik m.grzesc...@pengutronix.de [Alex: fixed backwards endianness conversion] Signed-off-by: Alexander Shishkin

[PATCH v2 19/21] usb: chipidea: udc: don't truncate requests to single tds

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de It is not safe to truncate requests to the maximum possible size the controller can handle with one td and to keep working. That patch fixes that with proper error handling instead. Reported-by: Felipe Balbi ba...@ti.com Signed-off-by: Michael

[PATCH v2 15/21] usb: chipidea: udc: only clear active and halted bits in qhead

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de The datasheet of the synopsys core describes only to overwrite the active and halted bits in the qhead before priming any endpoint. Signed-off-by: Michael Grzeschik m.grzesc...@pengutronix.de Reviewed-by: Felipe Balbi ba...@ti.com [Alex: fixed a

[PATCH v2 20/21] usb: chipidea: udc: move _ep_queue into an unlocked function

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de There is no need to call ep_queue unlocked inside the own driver. We move its functionionality into an unlocked version. This patch removes potential unlocked timeslots inside isr_setup_status_phase and isr_get_status_response, in which the lock

[PATCH v2 21/21] usb: chipidea: udc: add the define TD_PAGE_COUNT and fix all users

2013-03-30 Thread Alexander Shishkin
From: Michael Grzeschik m.grzesc...@pengutronix.de A static count of transfer descriptors was used everywhere in the driver with the fixed number 5. This patch adds a define, named TD_PAGE_COUNT, and replaces all users of this value. This way its possible to have only one parameter to change and

Re: [PATCH v3 1/7] USB: EHCI: make ehci-orion a separate driver

2013-03-30 Thread Arnd Bergmann
On Friday 29 March 2013, Alan Stern wrote: I don't know about this last phrase. When someone is running make menuconfig, for example, what shows up is the symbol's description, not the symbol's name. That person would see EHCI support for Marvell on-chip controller, not USB_EHCI_MV. In

Re: [PATCH 12/27] usb: chipidea: usbmisc: rename file, struct and functions to usbmisc_imx

2013-03-30 Thread Marc Kleine-Budde
On 03/30/2013 01:46 AM, Alexander Shishkin wrote: From: Michael Grzeschik m.grzesc...@pengutronix.de This driver will be used for every Freescale SoC which has this misc memory layout to control the basic usb handling. So better name this driver, function and struct names in a more generic

Re: [PATCH v3 2/7] USB: EHCI: make ehci-spear a separate driver

2013-03-30 Thread Arnd Bergmann
On Friday 29 March 2013, Alan Stern wrote: On Thu, 28 Mar 2013, Arnd Bergmann wrote: From: Manjunath Goudar manjunath.gou...@linaro.org Separate the SPEAr host controller driver from ehci-hcd host code so that it can be built as a separate driver module. This work is part of enabling

Re: [PATCH v3 3/7] USB: EHCI: make ehci-s5p a separate driver

2013-03-30 Thread Arnd Bergmann
On Friday 29 March 2013, Alan Stern wrote: On Thu, 28 Mar 2013, Arnd Bergmann wrote: Personally, I would have left these two functions the way they were and relied on the compiler to inline them when appropriate. Eliminating them just makes the code more complicated. Yes, makes sense.

Re: [PATCH v3 5/7] USB: EHCI: make ehci-atmel a separate driver

2013-03-30 Thread Arnd Bergmann
On Friday 29 March 2013, Alan Stern wrote: While not absolutely necessary, it would be nice to have the #include files in alphabetical order. + +#include ehci.h + +#define DRIVER_DESC EHCI atmel driver atmel should have a capital 'A'. Ok, added these changes for v4 along with

Re: [PATCH v3 6/7] USB: EHCI: make ehci-msm a separate driver

2013-03-30 Thread Arnd Bergmann
On Friday 29 March 2013, Alan Stern wrote: On Thu, 28 Mar 2013, Arnd Bergmann wrote: This patch is good. However the ehci-msm driver itself is not. While checking through the code, I was struck by the fact that it never calls usb_add_hcd() or usb_remove_hcd(). Obviously the driver cannot

Re: [PATCH v3 7/7] USB: OHCI: avoid conflicting platform drivers

2013-03-30 Thread Arnd Bergmann
On Friday 29 March 2013, Alan Stern wrote: I have not checked the details of all the changes; however, the basic idea is okay as a stop-gap measure. Ok, thanks. I guess this means the onus is now on me to split up ohci-hcd into a central library and separate bus drivers, like ehci-hcd...

[PATCH v4 1/6] USB: EHCI: make ehci-orion a separate driver

2013-03-30 Thread Arnd Bergmann
From: Manjunath Goudar manjunath.gou...@linaro.org Separate the Orion host controller driver from ehci-hcd host code into its own driver module because of following reason. With the multiplatform changes in arm-soc tree, it becomes possible to enable the mvebu platform (which uses ehci-orion) at

[PATCH v4 3/6] USB: EHCI: make ehci-s5p a separate driver

2013-03-30 Thread Arnd Bergmann
From: Manjunath Goudar manjunath.gou...@linaro.org Separate the Samsung S5P/EXYNOS host controller driver from ehci-hcd host code so that it can be built as a separate driver module. This work is part of enabling multi-platform kernels on ARM; however, note that other changes are still needed

[PATCH v4 5/6] USB: EHCI: make ehci-msm a separate driver

2013-03-30 Thread Arnd Bergmann
From: Manjunath Goudar manjunath.gou...@linaro.org Separate the Qualcomm QSD/MSM on-chip host controller driver from ehci-hcd host code so that it can be built as a separate driver module. This work is part of enabling multi-platform kernels on ARM; however, note that other changes are still

[PATCH v4 2/6] USB: EHCI: make ehci-spear a separate driver

2013-03-30 Thread Arnd Bergmann
From: Manjunath Goudar manjunath.gou...@linaro.org Separate the SPEAr host controller driver from ehci-hcd host code so that it can be built as a separate driver module. This work is part of enabling multi-platform kernels on ARM; however, note that other changes are still needed before SPEAr can

[PATCH v4 0/6] USB EHCI multiplatform conversion

2013-03-30 Thread Arnd Bergmann
Hi Alan, This is a quick update to v3, addressing all issues you pointed in yesterday's review. Thanks for taking a thorough look on short notice on a public holiday! Arnd Arnd Bergmann (1): USB: OHCI: avoid conflicting platform drivers Manjunath Goudar (5): USB: EHCI: make

[PATCH v4 4/6] USB: EHCI: make ehci-atmel a separate driver

2013-03-30 Thread Arnd Bergmann
From: Manjunath Goudar manjunath.gou...@linaro.org Separate the Atmel host controller driver from ehci-hcd host code so that it can be built as a separate driver module. This work is part of enabling multi-platform kernels on ARM; however, note that other changes are still needed before Atmel can

[PATCH v4 6/6] USB: OHCI: avoid conflicting platform drivers

2013-03-30 Thread Arnd Bergmann
Like the EHCI driver, OHCI supports a large number of different platform glue drivers by directly including them, which causes problems with conflicting macro definitions in some cases. As more ARM architecture specific back-ends are required to coexist in a single build, we should split those out

Re: [PATCH] USB: EHCI: fix regression during bus resume

2013-03-30 Thread Matthijs Kooijman
Hi Alan, This patch (as1663) fixes a regression caused by commit 6e0c3339a6f19d748f16091d0a05adeb1e1f822b (USB: EHCI: unlink one async QH at a time). [...] The symptom is that when the root hub is resumed, USB communications don't work for some period of time. This is because ehci-hcd

Re: [PATCH] USB: EHCI: fix regression during bus resume

2013-03-30 Thread Alan Stern
On Sat, 30 Mar 2013, Matthijs Kooijman wrote: Hi Alan, This patch (as1663) fixes a regression caused by commit 6e0c3339a6f19d748f16091d0a05adeb1e1f822b (USB: EHCI: unlink one async QH at a time). [...] The symptom is that when the root hub is resumed, USB communications don't work

Re: [PATCH] USB: EHCI: fix regression during bus resume

2013-03-30 Thread Matthijs Kooijman
Hi Alan, The same sort of thing has happened to me. Often you're better off looking to see if someone has already fixed a problem than trying to fix it yourself. :-) I started debugging this before rc4 was out, and it was still broken in rc3 (but since the lockup only occured with an SD

Re: [PATCH 12/27] usb: chipidea: usbmisc: rename file, struct and functions to usbmisc_imx

2013-03-30 Thread Alexander Shishkin
Marc Kleine-Budde m...@pengutronix.de writes: On 03/30/2013 01:46 AM, Alexander Shishkin wrote: From: Michael Grzeschik m.grzesc...@pengutronix.de This driver will be used for every Freescale SoC which has this misc memory layout to control the basic usb handling. So better name this

Re: [PATCH 12/27] usb: chipidea: usbmisc: rename file, struct and functions to usbmisc_imx

2013-03-30 Thread Marc Kleine-Budde
On 03/30/2013 05:11 PM, Alexander Shishkin wrote: Marc Kleine-Budde m...@pengutronix.de writes: On 03/30/2013 01:46 AM, Alexander Shishkin wrote: From: Michael Grzeschik m.grzesc...@pengutronix.de This driver will be used for every Freescale SoC which has this misc memory layout to control

Re: [PATCH v2 00/21] usb: chipidea: updates for v3.10

2013-03-30 Thread Greg KH
On Sat, Mar 30, 2013 at 12:53:49PM +0200, Alexander Shishkin wrote: Hi, Let's try again. Rebased it on top of usb-next and dropped the whole tracepoint thing, but kept the part that removes the old event buffer and other debug cleanups. So everything else is rebased on top of that and a

Re: cdc_acm device - unexpected characters sent to USB device

2013-03-30 Thread Oliver Neukum
On Saturday 30 March 2013 03:20:15 Mike Verstegen wrote: - Downloaded the source code for the cdc_acm driver. - Added a bunch of printk debug messages and stack_dumps to follow what's going on. - I rmmod'd the stock cdc_acm and insmod'd my instrumented module. - All the device

Re: [PATCH] usb: gadget: nokia: Add mass storage driver to g_nokia

2013-03-30 Thread Pavel Machek
On Mon 2013-01-21 10:05:06, Felipe Balbi wrote: Hi, On Sun, Jan 20, 2013 at 11:17:31AM +0100, Pali Rohár wrote: On Sunday 20 January 2013 10:25:37 Felipe Balbi wrote: On Sun, Jan 20, 2013 at 03:58:13AM +0100, Pali Rohár wrote: Signed-off-by: Pali Rohár pali.ro...@gmail.com NAK

Re: [PATCH net-next] cdc_ncm: return -ENOMEM if kzalloc fails

2013-03-30 Thread David Miller
From: Devendra Naga devendra.a...@gmail.com Date: Sat, 30 Mar 2013 14:33:22 +0530 return -ENOMEM instead if kzalloc of cdc_ncm_ctx structure is failed. and also remove the comparision of ctx structure with NULL and make it as !ctx. Signed-off-by: Devendra Naga devendra.a...@gmail.com

Re: EHCI: port power regression when canceling suspend-to-disk

2013-03-30 Thread Alan Stern
On Sat, 30 Mar 2013, Matthijs Kooijman wrote: Hi guys, I recently noticed a problem with suspend-to-disk on my Thinkpad X201. I'm using swsusp, which offers a press backspace to cancel while it is writing out the suspend image to the swap partition. When I do this, the system mostly

Multiple usb_storage problems

2013-03-30 Thread Andy Lutomirski
I have a Corsair Flash Voyager GT and a Lenovo x220 running Fedora's 3.8.2 kernel. It doesn't work very well, and the problems vary depending on whether I'm using usb2 or usb3. - On usb3, the device node can't be opened with O_DIRECT (using, for example, dd oflag=direct). It returns -EINVAL.

Re: Multiple usb_storage problems

2013-03-30 Thread Andy Lutomirski
On Sat, Mar 30, 2013 at 8:21 PM, Andy Lutomirski l...@amacapital.net wrote: I have a Corsair Flash Voyager GT and a Lenovo x220 running Fedora's 3.8.2 kernel. It doesn't work very well, and the problems vary depending on whether I'm using usb2 or usb3. - On usb3, the device node can't be