[PATCH 1/1] usb: chipidea: using one inline function to cover queue work operations

2014-05-21 Thread Peter Chen
The otg queue work include operations: one is disable interrupt, another one is call kernel queue work API. Many codes do this operation, using one inline function to instead of them. Signed-off-by: Peter Chen peter.c...@freescale.com --- drivers/usb/chipidea/core.c|6 +--

Re: [PATCH 02/10] xhci: 'noxhci_port_switch' kernel parameter

2014-05-21 Thread Dan Williams
On Tue, May 20, 2014 at 5:27 PM, Greg KH gre...@linuxfoundation.org wrote: Greg, Sorry, I don't think it is fair to users to force them to re-compile their kernel to get their device to work. I totally agree. Granted, I'm new to USB development, but the rate of reports of endpoint devices

Re: [PATCH 02/10] xhci: 'noxhci_port_switch' kernel parameter

2014-05-21 Thread Greg KH
On Tue, May 20, 2014 at 11:21:03PM -0700, Dan Williams wrote: On Tue, May 20, 2014 at 5:27 PM, Greg KH gre...@linuxfoundation.org wrote: Greg, Sorry, I don't think it is fair to users to force them to re-compile their kernel to get their device to work. I totally agree. Granted,

Re: [PATCH 2/3] usb: host: xhci-plat: add support for the R-Car H2 and M2 xHCI controllers

2014-05-21 Thread Yoshihiro Shimoda
Hi, (2014/05/20 19:11), Arnd Bergmann wrote: On Monday 19 May 2014 19:08:05 Yoshihiro Shimoda wrote: #include xhci.h #include xhci-mvebu.h +#include xhci-rcar.h static void xhci_plat_quirks(struct device *dev, struct xhci_hcd *xhci) { @@ -39,6 +40,12 @@ static int

Re: [PATCH 2/3] usb: host: xhci-plat: add support for the R-Car H2 and M2 xHCI controllers

2014-05-21 Thread Yoshihiro Shimoda
Hi Geert-san, Thank you for the reply again. (2014/05/20 19:14), Geert Uytterhoeven wrote: Hi Shimoda-san, On Tue, May 20, 2014 at 11:35 AM, Yoshihiro Shimoda yoshihiro.shimoda...@renesas.com wrote: (2014/05/19 20:58), Geert Uytterhoeven wrote: On Mon, May 19, 2014 at 12:08 PM, Yoshihiro

Re: [PATCH 2/3] usb: host: xhci-plat: add support for the R-Car H2 and M2 xHCI controllers

2014-05-21 Thread Arnd Bergmann
On Wednesday 21 May 2014 16:54:00 Yoshihiro Shimoda wrote: (2014/05/20 19:11), Arnd Bergmann wrote: On Monday 19 May 2014 19:08:05 Yoshihiro Shimoda wrote: #include xhci.h #include xhci-mvebu.h +#include xhci-rcar.h static void xhci_plat_quirks(struct device *dev, struct

Re: [PATCH] option: add device ID

2014-05-21 Thread Johan Hovold
On Tue, May 20, 2014 at 04:27:40PM +0200, oneu...@suse.de wrote: From: Oliver Neukum oneu...@suse.de Reported by Alif Mubarak Ahmad: This device vendor and product id is 1c9e:9800 It is working as serial interface with generic usbserial driver. I thought it is more suitable to use

USB 3.0 - Synopsis DWC Host-AHB - on Linux Kernel 3.10.28

2014-05-21 Thread krishnamurthy holla
Hello, I am using Linux kernel 3.10.28 - MIPS processor (BIG Endian) I see that XHCI fails during xhci_device_alloc() because of wait_for_completion_interruptible_timeout () when I connect a device. So, I thought of initializing host controller as BE as my host is BE. But this time, it failed

[PATCH] usb: gadget: FunctionFS: Return -ENOENT instead of -ENODEV when device not found.

2014-05-21 Thread Krzysztof Opasiak
Syscall mount returns -ENODEV error if requested FS type has not been found. Returning the same error from FFS mount callback makes value returned to userspace misleading. Other file systems returns -ENOENT if requested device has not been found. Adjust FFS to this convention to make error codes

[PATCH] usb: gadget: FunctionFS: Change returned error when device not found.

2014-05-21 Thread Krzysztof Opasiak
Dear Michal and Felipe, According to my last conversation with Michal[1] I have prepared patch which adjust error returning policy in function FS. Previously when FunctionFS was unable to find device configured via ConfigFS returned -ENODEV. This error looks quite suitable there but by default

[patch] usb: gadget: return -ENOMEM on allocation failure

2014-05-21 Thread Dan Carpenter
The error handling is confusing in this function, but if you look closely it is returning success after the allocation fails. I have changed it to return -ENOMEM and re-written it to be more clear. Fixes: 37a3a533429e ('usb: gadget: OS Feature Descriptors support') Signed-off-by: Dan Carpenter

[patch] usb: gadget: f_rndis: fix an error code on allocation failure

2014-05-21 Thread Dan Carpenter
This should be return -ENOMEM. The current code returns successs. Fixes: de7a8d2d534f ('usb: gadget: f_rndis: OS descriptors support') Signed-off-by: Dan Carpenter dan.carpen...@oracle.com diff --git a/drivers/usb/gadget/f_rndis.c b/drivers/usb/gadget/f_rndis.c index eed3ad8..31274f7 100644 ---

Re: [PATCH v6 00/17] USB support for Armada 38x and Armada 375

2014-05-21 Thread Gregory CLEMENT
Hi Greg, On 15/05/2014 12:17, Gregory CLEMENT wrote: Hello, This patch set adds the USB support for the Armada 38x and Armada 375 SOCs. These SoCs use an xHCI but still need specific initialization, mainly to setup the MBus memory windows. They also have another USB controller for EHCI,

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Catalin Marinas
On Tue, May 20, 2014 at 08:37:10PM +0100, Arnd Bergmann wrote: On Tuesday 20 May 2014 15:12:49 Catalin Marinas wrote: On Tue, May 20, 2014 at 12:08:58PM +0100, Arnd Bergmann wrote: On Tuesday 20 May 2014 12:02:46 Catalin Marinas wrote: On Mon, May 19, 2014 at 05:55:56PM +0100, Arnd

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Arnd Bergmann
On Wednesday 21 May 2014 14:56:36 Catalin Marinas wrote: On Tue, May 20, 2014 at 08:37:10PM +0100, Arnd Bergmann wrote: On Tuesday 20 May 2014 15:12:49 Catalin Marinas wrote: On Tue, May 20, 2014 at 12:08:58PM +0100, Arnd Bergmann wrote: On Tuesday 20 May 2014 12:02:46 Catalin Marinas

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Rob Herring
On Wed, May 21, 2014 at 9:43 AM, Arnd Bergmann a...@arndb.de wrote: On Wednesday 21 May 2014 14:56:36 Catalin Marinas wrote: On Tue, May 20, 2014 at 08:37:10PM +0100, Arnd Bergmann wrote: On Tuesday 20 May 2014 15:12:49 Catalin Marinas wrote: On Tue, May 20, 2014 at 12:08:58PM +0100, Arnd

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Catalin Marinas
On Wed, May 21, 2014 at 03:43:39PM +0100, Arnd Bergmann wrote: On Wednesday 21 May 2014 14:56:36 Catalin Marinas wrote: On Tue, May 20, 2014 at 08:37:10PM +0100, Arnd Bergmann wrote: On Tuesday 20 May 2014 15:12:49 Catalin Marinas wrote: So what we need is setting the default dma mask

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Arnd Bergmann
On Wednesday 21 May 2014 10:26:01 Rob Herring wrote: On Wed, May 21, 2014 at 9:43 AM, Arnd Bergmann a...@arndb.de wrote: On Wednesday 21 May 2014 14:56:36 Catalin Marinas wrote: On Tue, May 20, 2014 at 08:37:10PM +0100, Arnd Bergmann wrote: On Tuesday 20 May 2014 15:12:49 Catalin Marinas

Mass storage disconnects after few seconds of unuse

2014-05-21 Thread Mildred Ki'Lya
Hi, I have a problem with a USB device (4255:1000), running various kernels from 3.12.6 (Fedora) up to 2.14.4 (ArchLinux). When I connect the device, it appears all right. But after a few seconds of idle, it disconnects itself. When I manage to use the device (read or write files to the mounted

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Arnd Bergmann
On Wednesday 21 May 2014 16:32:16 Catalin Marinas wrote: On Wed, May 21, 2014 at 03:43:39PM +0100, Arnd Bergmann wrote: On Wednesday 21 May 2014 14:56:36 Catalin Marinas wrote: On Tue, May 20, 2014 at 08:37:10PM +0100, Arnd Bergmann wrote: On Tuesday 20 May 2014 15:12:49 Catalin Marinas

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Rob Herring
On Wed, May 21, 2014 at 10:48 AM, Arnd Bergmann a...@arndb.de wrote: On Wednesday 21 May 2014 10:26:01 Rob Herring wrote: On Wed, May 21, 2014 at 9:43 AM, Arnd Bergmann a...@arndb.de wrote: On Wednesday 21 May 2014 14:56:36 Catalin Marinas wrote: On Tue, May 20, 2014 at 08:37:10PM +0100,

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Catalin Marinas
On Wed, May 21, 2014 at 05:15:06PM +0100, Rob Herring wrote: On Wed, May 21, 2014 at 10:48 AM, Arnd Bergmann a...@arndb.de wrote: On Wednesday 21 May 2014 10:26:01 Rob Herring wrote: What are you checking against to cause a failure and what do you do on failure? I'm guessing that PCI masks

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Rob Herring
On Wed, May 21, 2014 at 11:35 AM, Catalin Marinas catalin.mari...@arm.com wrote: On Wed, May 21, 2014 at 05:15:06PM +0100, Rob Herring wrote: On Wed, May 21, 2014 at 10:48 AM, Arnd Bergmann a...@arndb.de wrote: On Wednesday 21 May 2014 10:26:01 Rob Herring wrote: What are you checking

Re: [PATCH] usb: ehci: Enable support for 64bit EHCI host controllers in arm64

2014-05-21 Thread Arnd Bergmann
On Wednesday 21 May 2014 12:01:29 Rob Herring wrote: On Wed, May 21, 2014 at 11:35 AM, Catalin Marinas catalin.mari...@arm.com wrote: On Wed, May 21, 2014 at 05:15:06PM +0100, Rob Herring wrote: On Wed, May 21, 2014 at 10:48 AM, Arnd Bergmann a...@arndb.de wrote: On Wednesday 21 May 2014

Re: ASMedia AS2105 interface on USB 3.0 corrupts data

2014-05-21 Thread Alan Stern
On Tue, 20 May 2014, Heinz Diehl wrote: On 20.05.2014, Heinz Diehl wrote: The usbmon dump of the whole process is here: http://www.fritha.org/usblog.zip And here's another one, while popping in and out. http://www.fritha.org/usblog2.zip Nothing very informative stands out in those

Re: [PATCH 02/10] xhci: 'noxhci_port_switch' kernel parameter

2014-05-21 Thread Dan Williams
On Tue, May 20, 2014 at 11:31 PM, Greg KH gre...@linuxfoundation.org wrote: On Tue, May 20, 2014 at 11:21:03PM -0700, Dan Williams wrote: On Tue, May 20, 2014 at 5:27 PM, Greg KH gre...@linuxfoundation.org wrote: Greg, Sorry, I don't think it is fair to users to force them to re-compile

Re: ASMedia AS2105 interface on USB 3.0 corrupts data

2014-05-21 Thread Heinz Diehl
On 21.05.2014, Alan Stern wrote: Your problems were probably caused by those spontaneous disconnects. Yes, I got the same impression while encountering this. They could be caused by a small electrical incompatibility between the computer and the device. In this case, most probably all of

Re: Mass storage disconnects after few seconds of unuse

2014-05-21 Thread Alan Stern
On Wed, 21 May 2014, Mildred Ki'Lya wrote: Hi, I have a problem with a USB device (4255:1000), running various kernels from 3.12.6 (Fedora) up to 2.14.4 (ArchLinux). When I connect the device, it appears all right. But after a few seconds of idle, it disconnects itself. When I manage to

Re: [PATCH 02/10] xhci: 'noxhci_port_switch' kernel parameter

2014-05-21 Thread Alan Stern
On Wed, 21 May 2014, Dan Williams wrote: On Tue, May 20, 2014 at 11:31 PM, Greg KH gre...@linuxfoundation.org wrote: On Tue, May 20, 2014 at 11:21:03PM -0700, Dan Williams wrote: On Tue, May 20, 2014 at 5:27 PM, Greg KH gre...@linuxfoundation.org wrote: Greg, Sorry, I don't think

Re: ASMedia AS2105 interface on USB 3.0 corrupts data

2014-05-21 Thread Alan Stern
On Wed, 21 May 2014, Heinz Diehl wrote: On 21.05.2014, Alan Stern wrote: Your problems were probably caused by those spontaneous disconnects. Yes, I got the same impression while encountering this. They could be caused by a small electrical incompatibility between the computer and

Re: [PATCH v10 09/19] usb: make usb_port flags atomic, rename did_runtime_put to child_usage

2014-05-21 Thread Alan Stern
On Tue, 20 May 2014, Dan Williams wrote: We want to manipulate -did_runtime_put in usb_port_runtime_resume(), but we don't want that to collide with other updates. Move usb_port flags to new port-bitmap fields in usb_hub. did_runtime_put is renamed child_usage_bits to reflect that it is

[PATCH] tools: ffs-test: convert to new descriptor format fixing compilation error

2014-05-21 Thread Michal Nazarewicz
Commit [ac8dde11: “usb: gadget: f_fs: Add flags to descriptors block”] which introduced a new descriptor format for FunctionFS removed the usb_functionfs_descs_head structure, which is still used by ffs-test. tool. Convert ffs-test by converting it to use the new header format. For testing

Re: ASMedia AS2105 interface on USB 3.0 corrupts data

2014-05-21 Thread Heinz Diehl
On 21.05.2014, Alan Stern wrote: Maybe the problem involves USB-3 Link Power Management. Unfortunately there isn't any way I know of to disable it without rebuilding the kernel. No problem. The patch below will disable LPM for all devices. You can try it and see if it helps.

Re: [PATCH] usb: gadget: FunctionFS: Return -ENOENT instead of -ENODEV when device not found.

2014-05-21 Thread Michal Nazarewicz
On Wed, May 21 2014, Krzysztof Opasiak k.opas...@samsung.com wrote: Syscall mount returns -ENODEV error if requested FS type has not been found. Returning the same error from FFS mount callback makes value returned to userspace misleading. Other file systems returns -ENOENT if requested

Re: [PATCH v10 18/19] usb: force warm reset to break link re-connect livelock

2014-05-21 Thread Alan Stern
On Tue, 20 May 2014, Dan Williams wrote: Resuming a powered down port sometimes results in the port state being stuck in the training sequence. hub 3-0:1.0: debounce: port 1: total 2000ms stable 0ms status 0x2e0 port1: can't get reconnection after setting port power on, status -110 hub

Re: [PATCH v10 19/19] usb: documentation for usb port power off mechanisms

2014-05-21 Thread Alan Stern
On Tue, 20 May 2014, Dan Williams wrote: From: Lan Tianyu tianyu@intel.com describe the mechanisms for controlling port power policy and discovering the port power state. +Example of the relevant files for port power control. + + child device link + +

Re: ASMedia AS2105 interface on USB 3.0 corrupts data

2014-05-21 Thread Alan Stern
On Wed, 21 May 2014, Heinz Diehl wrote: On 21.05.2014, Alan Stern wrote: Maybe the problem involves USB-3 Link Power Management. Unfortunately there isn't any way I know of to disable it without rebuilding the kernel. No problem. The patch below will disable LPM for all

Re: [PATCH 02/10] xhci: 'noxhci_port_switch' kernel parameter

2014-05-21 Thread Greg KH
On Wed, May 21, 2014 at 10:29:09AM -0700, Dan Williams wrote: On Tue, May 20, 2014 at 11:31 PM, Greg KH gre...@linuxfoundation.org wrote: On Tue, May 20, 2014 at 11:21:03PM -0700, Dan Williams wrote: On Tue, May 20, 2014 at 5:27 PM, Greg KH gre...@linuxfoundation.org wrote: Greg,

Re: [PATCH v6 00/17] USB support for Armada 38x and Armada 375

2014-05-21 Thread Greg Kroah-Hartman
On Wed, May 21, 2014 at 03:50:47PM +0200, Gregory CLEMENT wrote: Hi Greg, On 15/05/2014 12:17, Gregory CLEMENT wrote: Hello, This patch set adds the USB support for the Armada 38x and Armada 375 SOCs. These SoCs use an xHCI but still need specific initialization, mainly to setup the

[GIT PULL] USB patches for v3.16 merge window

2014-05-21 Thread Felipe Balbi
Hi Greg, Here's my big dump for v3.16 merge window. Even though we have a lot of patches, most of them are just doing cleanups and small bug fixes. Consider merging it to your usb-next branch. There will be a conflict with drivers/usb/phy/phy-mv-u3d.c (deleted in your tree, modified on mine).

[PATCH v3 0/6] Cleanup and fixes for dwc3-omap

2014-05-21 Thread George Cherian
The series does some refactoring on dwc3_probe() Patch 1 - Now that we use driver compatible for revision check, remove the unnecessary logic. Patch 2-4 - reduce the size of dwc3_probe() Patch 5 - Fix the crash on dwc3_omap removal Patch 6 - Addresses the issue of xhci hang while resuming from

[PATCH v3 3/6] usb: dwc3: dwc3-omap: Add dwc3_omap_set_utmi_mode() function

2014-05-21 Thread George Cherian
Move find and set the utmi mode to its own seperate function. Improve code readability, decrease the dwc3_probe() size. Signed-off-by: George Cherian george.cher...@ti.com --- drivers/usb/dwc3/dwc3-omap.c | 44 +--- 1 file changed, 25 insertions(+), 19

[PATCH v3 5/6] usb: dwc3: dwc3-omap: Fix the crash on module removal

2014-05-21 Thread George Cherian
Following crash is seen on dwc3_omap removal Unable to handle kernel NULL pointer dereference at virtual address 0018 pgd = ec098000 [0018] *pgd=ad1f9831, *pte=, *ppte= Internal error: Oops: 17 [#1] SMP ARM Modules linked in: usb_f_ss_lb g_zero usb_f_acm u_serial usb_f_ecm

[PATCH v3 4/6] usb: dwc3: dwc3-omap: Add dwc3_omap_extcon_register function

2014-05-21 Thread George Cherian
Move the extcon related code to its own function. Improve code readability, decrease the dwc3_probe() size. Signed-off-by: George Cherian george.cher...@ti.com --- drivers/usb/dwc3/dwc3-omap.c | 65 ++-- 1 file changed, 39 insertions(+), 26 deletions(-)

[PATCH v3 2/6] usb: dwc3: dwc3-omap: Add dwc3_omap_map_offset() function

2014-05-21 Thread George Cherian
Move map offset to its own seperate function. Improve code readability, decrease the dwc3_probe() size. Signed-off-by: George Cherian george.cher...@ti.com --- drivers/usb/dwc3/dwc3-omap.c | 33 - 1 file changed, 20 insertions(+), 13 deletions(-) diff --git

[PATCH v3 6/6] usb: dwc3: dwc3-omap: Disable/Enable only wrapper interrupts in prepare/complete

2014-05-21 Thread George Cherian
The dwc3 wrapper driver should not be fiddling with the core interrupts. Disabling the core interrupts in prepare stops xhci from proper operation. So remove disable/enable of core interrupts from prepare/complete. Signed-off-by: George Cherian george.cher...@ti.com ---

[PATCH v3 1/6] usb: dwc3: dwc3-omap: Remove x_major calculation from revision register

2014-05-21 Thread George Cherian
Remove the x_major calculation logic from the wrapper revision register to differentiate between OMAP5 and AM437x. This was done to find the register offsets of wrapper register. Now that We do it using dt compatible, remove the whole logic. Signed-off-by: George Cherian george.cher...@ti.com ---

Re: [patch] usb: gadget: f_rndis: fix an error code on allocation failure

2014-05-21 Thread Andrzej Pietrasiewicz
W dniu 21.05.2014 14:26, Dan Carpenter pisze: This should be return -ENOMEM. The current code returns successs. Fixes: de7a8d2d534f ('usb: gadget: f_rndis: OS descriptors support') Signed-off-by: Dan Carpenter dan.carpen...@oracle.com Acked-by: Andrzej Pietrasiewicz andrze...@samsung.com

Re: [patch] usb: gadget: return -ENOMEM on allocation failure

2014-05-21 Thread Andrzej Pietrasiewicz
W dniu 21.05.2014 14:26, Dan Carpenter pisze: The error handling is confusing in this function, but if you look closely it is returning success after the allocation fails. I have changed it to return -ENOMEM and re-written it to be more clear. Fixes: 37a3a533429e ('usb: gadget: OS Feature