Re: [PATCH v2] USB:gadget: Fix a warning while loading g_mass_storage

2014-06-09 Thread Yang,Wei
Hi Alan, Sorry for my late response, as I was 000, Additionally, I am very grateful for your review. On 06/06/2014 02:08 AM, Alan Stern wrote: On Wed, 4 Jun 2014 wei.y...@windriver.com wrote: From: Yang Wei wei.y...@windriver.com While loading g_mass_storage module, the following warning

[PATCH v3] USB:gadget: Fix a warning while loading g_mass_storage

2014-06-09 Thread Wei.Yang
From: Yang Wei wei.y...@windriver.com While loading g_mass_storage module, the following warning is triggered. WARNING: at drivers/usb/gadget/composite.c: usb_composite_setup_continue: Unexpected call Modules linked in: fat vfat minix nls_cp437 nls_iso8859_1 g_mass_storage [800179cc]

Re: non-working UVC device 058f:5608

2014-06-09 Thread Johannes Berg
Hi Laurent, Thanks for the quick reply! and then the kernel message repeats forever, while I can't even exit uvccapture unless I kill it hard, at which point I get xhci_hcd :00:14.0: Signal while waiting for configure endpoint command usb 1-3.4.4.3: Not enough bandwidth for

RE: [PATCHv2 5/5] tools: ffs-test: add compatibility code for old kernels

2014-06-09 Thread Krzysztof Opasiak
Hi Michal, -Original Message- From: Michal Nazarewicz [mailto:min...@mina86.com] Sent: Friday, June 06, 2014 11:13 AM To: Felipe Balbi; Krzysztof Opasiak Cc: linux-usb@vger.kernel.org; linux-ker...@vger.kernel.org; Michal Nazarewicz Subject: [PATCHv2 5/5] tools: ffs-test: add

Re: [PATCH 4/9] usb: phy: add the Berlin USB PHY driver

2014-06-09 Thread Jisheng Zhang
Dear Sebastian and Antoine, On Fri, 6 Jun 2014 03:54:06 -0700 Sebastian Hesselbarth sebastian.hesselba...@gmail.com wrote: + +#define to_berlin_phy_priv(p) container_of((p), struct berlin_phy_priv, phy) + +struct berlin_phy_priv { + void __iomem*base; + struct

Re: non-working UVC device 058f:5608

2014-06-09 Thread Laurent Pinchart
Hi Johannes, On Monday 09 June 2014 09:33:06 Johannes Berg wrote: Hi Laurent, Thanks for the quick reply! You're welcome. and then the kernel message repeats forever, while I can't even exit uvccapture unless I kill it hard, at which point I get xhci_hcd :00:14.0: Signal

Re: Hardware bug in Intel USB-2 hub?

2014-06-09 Thread Toralf Förster
On 06/19/2013 09:03 PM, Alan Stern wrote: Sarah: This report surfaced in Bugzilla #59011 (see especially comments #38 and #39). Toralf reports, among other things, that the integrated rate-matching hub in his ThinkPad T420 (6 Series/C200 Series chipset) isn't behaving the way it should.

Re: non-working UVC device 058f:5608

2014-06-09 Thread Johannes Berg
On Mon, 2014-06-09 at 11:25 +0200, Laurent Pinchart wrote: Indeed, that works! Interestingly, it works neither on a USB3 port directly, nor on a USB2 hub behind the USB3 port. I would thus be tempted to classify this as an XHCI controller issue. linux- usb should be the right list to get

Re: [PATCH 4/9] usb: phy: add the Berlin USB PHY driver

2014-06-09 Thread Sebastian Hesselbarth
On 06/09/2014 10:26 AM, Jisheng Zhang wrote: Dear Sebastian and Antoine, On Fri, 6 Jun 2014 03:54:06 -0700 Sebastian Hesselbarth sebastian.hesselba...@gmail.com wrote: + +#define to_berlin_phy_priv(p) container_of((p), struct berlin_phy_priv, phy) + +struct berlin_phy_priv { +

Re: [PATCH 0/9] ARM: Berlin: USB support

2014-06-09 Thread Sebastian Hesselbarth
On 06/09/2014 06:30 AM, Peter Chen wrote: On Thu, Jun 05, 2014 at 05:48:37PM +0200, Antoine Ténart wrote: This series adds the support for the Marvell Berlin USB controllers, the USB PHYs and also adds a reset controller. The reset controller is used by the USB PHY driver and shares the

[PATCHv3] tools: ffs-test: add compatibility code for old kernels

2014-06-09 Thread Michal Nazarewicz
If ffs-test is used with a kernel prior to 3.14, which do not support the new descriptors format, it will fail when trying to write the descriptors. Add a function that converts the new descriptors to the legacy ones and use it to retry writing the descriptors using the legacy format. Also add

Re: non-working UVC device 058f:5608

2014-06-09 Thread Johannes Berg
On Mon, 2014-06-09 at 11:59 +0200, Johannes Berg wrote: Johannes, could you enable USB debugging in the linus/master kernel and provide a kernel log ? I'll try to get some logs (wasn't there tracing added to xhci too? will check) Here we go - log + tracing: log:

Re: non-working UVC device 058f:5608

2014-06-09 Thread Johannes Berg
On Mon, 2014-06-09 at 12:27 +0200, Johannes Berg wrote: Here we go - log + tracing: log: http://p.sipsolutions.net/d5926c43d531e3af.txt trace: http://johannes.sipsolutions.net/files/xhci.trace.dat.xz Oh, and this was the kernel diff to commit 963649d735c8b6eb0f97e82c54f02426ff3f1f45: diff

Re: [PATCH 4/9] usb: phy: add the Berlin USB PHY driver

2014-06-09 Thread Alexandre Belloni
On 09/06/2014 at 12:11:57 +0200, Sebastian Hesselbarth wrote : Some BG2Q boards hardwired the vbus to be always powered on, we should continue the probe if vbus gpio is missing. Yeah, the same applies for regulators. But with the comments above, it should move to the controller stub

Re: [PATCH v2] leds: USB: Add support for MSI GT683R led panels

2014-06-09 Thread Johan Hovold
On Sat, Jun 07, 2014 at 01:12:39PM +0300, Janne Kanniainen wrote: First of all, please reply to the original thread and make sure to not drop people or lists from CC. Sorry this is my first patch and i didn't know that. Now I know. For arrays you can use the ARRAY_SIZE() macro if that

slight regression in USB wakeup

2014-06-09 Thread Adam Borowski
Hi! Commit c1db30a2a79eb59997b13b8cabf2a50bea9f04e1 (USB: OHCI: fix problem with global suspend on ATI controllers) makes S4 hibernation no longer respond to wakeup signals that come from USB (such as pressing a key on the keyboard). Other ways to wake up (such as the power button) still work.

Re: [PATCH] USB: ftdi_sio: add GPIO support

2014-06-09 Thread One Thousand Gnomes
#include linux/kernel.h #include linux/errno.h +#ifdef CONFIG_GPIOLIB +#include linux/gpio.h +#endif Please create a new struct, a new file and put all the GPIO stuff in there rather than #if bombing the driver. You can then declare blank methods for the gpio stuff if GPIO is not

Re: [Patch V3 0/2] usb: gadget: zero: Add support for interrupt EP

2014-06-09 Thread Alan Stern
On Mon, 9 Jun 2014, Amit Virdi wrote: Felipe, Alan, On 5/23/2014 12:01 PM, Amit VIRDI wrote: This patchset adds support for interrupt EP and the corresponding test cases to gadget zero. The code has been rebased and tested on Kernel v3.15-rc5 V2 - V3 - Rectified wMaxPacketSize

Re: Hardware bug in Intel USB-2 hub?

2014-06-09 Thread Alan Stern
On Mon, 9 Jun 2014, Toralf Förster wrote: On 06/19/2013 09:03 PM, Alan Stern wrote: Sarah: This report surfaced in Bugzilla #59011 (see especially comments #38 and #39). Toralf reports, among other things, that the integrated rate-matching hub in his ThinkPad T420 (6 Series/C200

Re: [Patch V3 0/2] usb: gadget: zero: Add support for interrupt EP

2014-06-09 Thread gre...@linuxfoundation.org
On Mon, Jun 09, 2014 at 10:44:38AM +0530, Amit Virdi wrote: Felipe, Alan, On 5/23/2014 12:01 PM, Amit VIRDI wrote: This patchset adds support for interrupt EP and the corresponding test cases to gadget zero. The code has been rebased and tested on Kernel v3.15-rc5 V2 - V3 - Rectified

Re: sleeping function called with IRQs disabled

2014-06-09 Thread Mathias Nyman
On 06/08/2014 12:36 AM, Johannes Berg wrote: Just got the below when I plugged in a new webcam. Not sure it's a bug in xhci (using GFP_KERNEL presumably) or (less likely?) in the USB autosuspend code. Thanks, regression in XHCI xhci_stop_device() tries to allocate memory with GFP_KERNEL flag

[PATCH] xhci: Fix sleeping with IRQs disabled in xhci_stop_device()

2014-06-09 Thread Mathias Nyman
xhci_stop_device() allocates and issues stop commands for each active endpoint. This is done with spinlock held and interrupt disabled so we can't sleep during memory allocation. Use GFP_ATOMIC instead Regressiong from commit ddba5cd0aeff5bbed92ebdf4b1223300b0541e78 xhci: Use command structures

Re: [PATCH] xhci: Fix sleeping with IRQs disabled in xhci_stop_device()

2014-06-09 Thread Greg KH
On Mon, Jun 09, 2014 at 07:07:29PM +0300, Mathias Nyman wrote: xhci_stop_device() allocates and issues stop commands for each active endpoint. This is done with spinlock held and interrupt disabled so we can't sleep during memory allocation. Use GFP_ATOMIC instead Regressiong from commit

Re: [PATCH] xhci: Fix sleeping with IRQs disabled in xhci_stop_device()

2014-06-09 Thread Johannes Berg
On Mon, 2014-06-09 at 19:07 +0300, Mathias Nyman wrote: xhci_stop_device() allocates and issues stop commands for each active endpoint. This is done with spinlock held and interrupt disabled so we can't sleep during memory allocation. Use GFP_ATOMIC instead Regressiong from commit

Re: [PATCH] USB: ftdi_sio: add GPIO support

2014-06-09 Thread Sergei Shtylyov
Hello. On 06/09/2014 06:23 PM, One Thousand Gnomes wrote: #include linux/kernel.h #include linux/errno.h +#ifdef CONFIG_GPIOLIB +#include linux/gpio.h +#endif Please create a new struct, a new file and put all the GPIO stuff in there rather than #if bombing the driver. You can then

[PATCH 1/2] usb: gadget: pxa27x_udc: add devicetree support

2014-06-09 Thread Robert Jarzmik
Add support for device-tree device discovery. If devicetree is not provided, fallback to legacy platform data discovery. Signed-off-by: Robert Jarzmik robert.jarz...@free.fr --- drivers/usb/gadget/pxa27x_udc.c | 105 drivers/usb/gadget/pxa27x_udc.h | 4

[PATCH 2/2] usb: gadget: pxa27x_udc: use devm_* helpers

2014-06-09 Thread Robert Jarzmik
Use devm_* helpers in the probe function to simplify the error path and the remove path. Signed-off-by: Robert Jarzmik robert.jarz...@free.fr --- drivers/usb/gadget/pxa27x_udc.c | 51 +++-- 1 file changed, 14 insertions(+), 37 deletions(-) diff --git

Re: [PATCH 2/2] usb: gadget: pxa27x_udc: use devm_* helpers

2014-06-09 Thread Sergei Shtylyov
Hello. On 06/09/2014 11:52 PM, Robert Jarzmik wrote: Use devm_* helpers in the probe function to simplify the error path and the remove path. Signed-off-by: Robert Jarzmik robert.jarz...@free.fr --- drivers/usb/gadget/pxa27x_udc.c | 51 +++-- 1 file

Re: [PATCH 2/4] usb: host: xhci-plat: Add support to get PHYs

2014-06-09 Thread Julius Werner
diff --git a/drivers/usb/host/xhci.h b/drivers/usb/host/xhci.h index 9ffecd5..453d89e 100644 --- a/drivers/usb/host/xhci.h +++ b/drivers/usb/host/xhci.h @@ -1582,6 +1582,9 @@ struct xhci_hcd { u32 port_status_u0; /* Compliance Mode Timer Triggered every 2

Re: [PATCH] xhci: Fix sleeping with IRQs disabled in xhci_stop_device()

2014-06-09 Thread Dan Williams
On Mon, Jun 9, 2014 at 9:07 AM, Mathias Nyman mathias.ny...@linux.intel.com wrote: xhci_stop_device() allocates and issues stop commands for each active endpoint. This is done with spinlock held and interrupt disabled so we can't sleep during memory allocation. Use GFP_ATOMIC instead

Re: [PATCH 1/2] usb: gadget: pxa27x_udc: add devicetree support

2014-06-09 Thread Jingoo Han
On Tuesday, June 10, 2014 4:52 AM, Robert Jarzmik wrote: Add support for device-tree device discovery. If devicetree is not provided, fallback to legacy platform data discovery. Signed-off-by: Robert Jarzmik robert.jarz...@free.fr --- drivers/usb/gadget/pxa27x_udc.c | 105

RE: [PATCH 0/9] ARM: Berlin: USB support

2014-06-09 Thread Peter Chen
we are early in the cycle and I feel there will be a v2 of the chipidea stub. IMHO, controlling the vbus regulator should not be business of the phy driver, so ci will have to deal with it. vbus handling has already in chipidea common code, it treats vbus as a regulator. So, the glue

[PATCH v2 4/7] usb: gadget: remove __init from gadget driver bind function

2014-06-09 Thread Peter Chen
Since the .bind may not be called at the driver's initialization routine due to the udc is not ready, we remove __init marker for it. Signed-off-by: Peter Chen peter.c...@freescale.com --- drivers/usb/gadget/acm_ms.c |4 ++-- drivers/usb/gadget/audio.c|4 ++--

[PATCH v2 6/7] usb: gadget: core: delete udc_attach_driver API

2014-06-09 Thread Peter Chen
After gadget bus introducing, the user (configfs) of this API will use device-model's bind/unbind, so we can use delete it. Signed-off-by: Peter Chen peter.c...@freescale.com --- drivers/usb/gadget/udc-core.c | 44 - include/linux/usb/gadget.h|2

[PATCH v2 2/7] usb: gadget: core: add implementation of gadget bus

2014-06-09 Thread Peter Chen
At gadget bus, the device (udc) and the driver (gadget dirver) will try to match between each other, the automatically binding is designed at this patch. The rule of auto-binding is: if the udc is not in use and the gadget driver is not used by any udcs, it is matched successfully, and will be

[PATCH RFC 5/7] usb: gadget: configfs: changes for gadget bus introducing

2014-06-09 Thread Peter Chen
- Deciding configfs device_driver's name according to creating sequence, it is still RFC - Register gadget driver at gadgets_make - Delete gadget_cdev_desc_UDC_store and gadget_cdev_desc_UDC_show interface, we can use standard device-model bind/unbind entry to bind specific udc to gadgetfs driver

[PATCH v2 3/7] usb: gadget: core: add manual binding

2014-06-09 Thread Peter Chen
The user can bind any unused udc to specific gadget driver if there is no udc has already been binded to that gadget driver. For example: cd /sys/bus/usb_gadget/drivers echo udc-0 g_serial echo udc-1 g_mass_storage There are three solutions to do manual binding: 1. If the udc driver or gadget

[PATCH v2 1/7] usb: gadget: core: change udc class to gadget bus

2014-06-09 Thread Peter Chen
The udc will be the device at gadget bus, and the gadget driver will be the driver at this bus. With gadget bus, we can support below features: - udc driver is loaded later than gadget driver - Binding udc and gadget driver manually Signed-off-by: Peter Chen peter.c...@freescale.com ---

[PATCH v2 7/7] doc: usb: gadget_configfs: change for gadget bus introducing

2014-06-09 Thread Peter Chen
After gadget bus introducing, the bind/unbind udc to configfs driver will use standard device-model's usage, which are the entries of bind and unbind at device driver. Signed-off-by: Peter Chen peter.c...@freescale.com --- Documentation/usb/gadget_configfs.txt | 13 ++--- 1 files

[PATCH v2 0/7] Add Gadget Bus

2014-06-09 Thread Peter Chen
Changes for v2: - Felipe's comments: For example we don't want automatic binding, basically we might want to have g_mass_storage running on both ports and this series would prevent it. Currently, it is impossible to let g_mass_storage or other g_xxx gadgets run at both ports due to g_xxx gadget