Re: [PATCH v7] usb:serial:pl2303: add GPIOs interface on PL2303

2014-08-13 Thread Hannes Petermaier
Known issue: If gpios are in use(export to userspace through sysfs interface, etc), then call pl2303_release(unplug usb-serial convertor, modprobe -r, etc), will cause trouble, so we need to make sure there is no gpio user before call pl2303_release. This is a real problem that

Re: [PATCH v7] usb:serial:pl2303: add GPIOs interface on PL2303

2014-08-13 Thread Johan Hovold
On Wed, Aug 13, 2014 at 08:17:50AM +0200, Hannes Petermaier wrote: Known issue: If gpios are in use(export to userspace through sysfs interface, etc), then call pl2303_release(unplug usb-serial convertor, modprobe -r, etc), will cause trouble, so we need to make sure there is no

Re: [PATCH v7] usb:serial:pl2303: add GPIOs interface on PL2303

2014-08-13 Thread Greg KH
On Wed, Aug 13, 2014 at 09:05:09AM +0200, Johan Hovold wrote: On Wed, Aug 13, 2014 at 08:17:50AM +0200, Hannes Petermaier wrote: Known issue: If gpios are in use(export to userspace through sysfs interface, etc), then call pl2303_release(unplug usb-serial convertor, modprobe -r,

Re: [PATCH v4] usb: gadget: at91_udc: move prepare clk into process context

2014-08-13 Thread Boris BREZILLON
On Fri, 8 Aug 2014 11:42:42 +0200 Ronald Wahl ronald.w...@raritan.com wrote: Commit 7628083227b6bc4a7e33d7c381d7a4e558424b6b (usb: gadget: at91_udc: prepare clk before calling enable) added clock preparation in interrupt context. This is not allowed as it might sleep. Also setting the clock

Re: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Michael Grzeschik
On Wed, Aug 13, 2014 at 01:26:07AM +, Peter Chen wrote: On Mon, Aug 11, 2014 at 02:34:33PM +0200, Michael Grzeschik wrote: Hi Peter, On Mon, Aug 11, 2014 at 12:56:47AM +, Peter Chen wrote: I have seen this call is still returning EOPNOTSUPP which is also returned by

Re: [PATCH v4] usb: gadget: at91_udc: move prepare clk into process context

2014-08-13 Thread Nicolas Ferre
On 08/08/2014 11:42, Ronald Wahl : Commit 7628083227b6bc4a7e33d7c381d7a4e558424b6b (usb: gadget: at91_udc: prepare clk before calling enable) added clock preparation in interrupt context. This is not allowed as it might sleep. Also setting the clock rate is unsafe to call from there for the

Re: [PATCH] pl2303: use divisors for unsupported baud rates

2014-08-13 Thread Johan Hovold
On Wed, Aug 13, 2014 at 07:51:52AM +0300, Lauri Hintsala wrote: Please describe your change also in the message body. This change has been tested to work with PL-2303HX at 115200, 50, 100, 200, 250, 300 and 400 baud rates. 115200 and 3Mbaud can be set directly and are

Re: [PATCH] pl2303: use divisors for unsupported baud rates

2014-08-13 Thread Lauri Hintsala
On 08/13/2014 01:01 PM, Johan Hovold wrote: On Wed, Aug 13, 2014 at 07:51:52AM +0300, Lauri Hintsala wrote: Please describe your change also in the message body. OK This change has been tested to work with PL-2303HX at 115200, 50, 100, 200, 250, 300 and 400 baud

Re: [PATCH] pl2303: use divisors for unsupported baud rates

2014-08-13 Thread Johan Hovold
On Wed, Aug 13, 2014 at 01:21:28PM +0300, Lauri Hintsala wrote: On 08/13/2014 01:01 PM, Johan Hovold wrote: On Wed, Aug 13, 2014 at 07:51:52AM +0300, Lauri Hintsala wrote: The reason this hasn't been done already is partly that there are a bunch of devices out there that apparently cannot

Transient USB disconnects

2014-08-13 Thread David Laight
We are seeing some transient USB disconnects, these cause serious grief if we use the xhci driver, so the ports are all forced to use ehci (bios config). Even with ehci they are slightly problematic, partially resolved by using a 'bond' interface to stop the ethernet interface and address

Re: [PATCH v2] pl2303: use divisors for unsupported baud rates

2014-08-13 Thread Lauri Hintsala
Please ignore this patch. There was a typo. I sent it too early before testing it. My mistake. Sorry. Lauri On 08/13/2014 02:46 PM, Lauri Hintsala wrote: Use direct method for supported baud rates, otherwise use divisors. Limit baud rate to 12 Mbaud with HX type. This change has been tested

[PATCH v2] pl2303: use divisors for unsupported baud rates

2014-08-13 Thread Lauri Hintsala
Use direct method for supported baud rates, otherwise use divisors. Limit baud rate to 12 Mbaud with HX type. This change has been tested to work with PL-2303HX at 115200, 50, 100, 200, 250, 300 and 400 baud rates. Signed-off-by: Lauri Hintsala lauri.hints...@bluegiga.com

Re: [PATCH] usb: xhci: amd chipset also needs short TX quirk

2014-08-13 Thread Mathias Nyman
On 08/12/2014 05:13 PM, Huang Rui wrote: AMD xHC also needs short tx quirk after tested on most of chipset generations. That's because there is the same incorrect behavior like Fresco Logic host. Please see below message with on USB webcam attached on xHC host: [ 139.262944] xhci_hcd

[PATCH v3] pl2303: use divisors for unsupported baud rates

2014-08-13 Thread Lauri Hintsala
Use direct method for supported baud rates, otherwise use divisors. Limit baud rate to 12 Mbaud with HX type. This change has been tested to work with PL-2303HX at 115200, 50, 100, 200, 250, 300 and 400 baud rates. Signed-off-by: Lauri Hintsala lauri.hints...@bluegiga.com

Re: [PATCH] usb: xhci: amd chipset also needs short TX quirk

2014-08-13 Thread Huang Rui
Hi Mathias, On Wed, Aug 13, 2014 at 03:12:25PM +0300, Mathias Nyman wrote: On 08/12/2014 05:13 PM, Huang Rui wrote: AMD xHC also needs short tx quirk after tested on most of chipset generations. That's because there is the same incorrect behavior like Fresco Logic host. Please see below

[PATCH RFC] usb: gadget: dwc2: make driver run on a version 3.10a instance of DWC_OTG

2014-08-13 Thread Neil Armstrong
We are trying to make a driver run on our PCD only instance of Synopsys DWC_OTG IP with the following parameters : - Dedicated Fifos : Yes - Descriptor DMA : Yes - PHY : 8bit UTMI+ (may need also support for ULPI) - Endpoints : 6 (7 with ep0) - Periodic IN Endpoints : 0 - IN Endpoints : 3 (4 with

Re: [PATCH v3] pl2303: use divisors for unsupported baud rates

2014-08-13 Thread Johan Hovold
On Wed, Aug 13, 2014 at 03:02:53PM +0300, Lauri Hintsala wrote: Use direct method for supported baud rates, otherwise use divisors. Limit baud rate to 12 Mbaud with HX type. This change has been tested to work with PL-2303HX at 115200, 50, 100, 200, 250, 300 and 400

RE: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Alan Stern
On Wed, 13 Aug 2014, Peter Chen wrote: So here's what the UDC driver should do: If the pullup routine is called while Vbus is off, the driver should leave the D+ pullup disconnected but remember the call. Then when Vbus gets turned on, the driver should activate the pullup. In other

Re: Transient USB disconnects

2014-08-13 Thread Alan Stern
On Wed, 13 Aug 2014, David Laight wrote: We are seeing some transient USB disconnects, these cause serious grief if we use the xhci driver, so the ports are all forced to use ehci (bios config). Even with ehci they are slightly problematic, partially resolved by using a 'bond' interface to

Re: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Felipe Balbi
Hi, On Wed, Aug 13, 2014 at 10:02:08AM -0400, Alan Stern wrote: So here's what the UDC driver should do: If the pullup routine is called while Vbus is off, the driver should leave the D+ pullup disconnected but remember the call. Then when Vbus gets turned on, the driver should

Re: [PATCH v4] kconfig/symbol.c: handle choice_values that depend on 'm' symbols

2014-08-13 Thread Bin Liu
All, On Mon, Nov 18, 2013 at 12:08 PM, Yann E. MORIN yann.morin.1...@free.fr wrote: Dirk, All, On 2013-11-07 15:05 +0100, Dirk Gouders spake thusly: If choices consist of choice_values that depend on symbols set to 'm', those choice_values are not set to 'n' if the choice is changed from

Re: FTDI Kernel driver

2014-08-13 Thread Johan Hovold
On Wed, Aug 13, 2014 at 02:48:25PM +0200, Nicolas Alt wrote: Hi, there is a comment in the code ftdi_sio.c, saying that new device IDs should be reported to be added to the driver. I guess you are the current maintainer? I have a converter from Basic Micro, which uses 0x0403 / 0xa559.

[PATCH] USB: ftdi_sio: add Basic Micro ATOM Nano USB2Serial PID

2014-08-13 Thread Johan Hovold
Add device id for Basic Micro ATOM Nano USB2Serial adapters. Reported-by: Nicolas Alt n@mytum.de Cc: stable sta...@vger.kernel.org Signed-off-by: Johan Hovold jo...@kernel.org --- drivers/usb/serial/ftdi_sio.c | 1 + drivers/usb/serial/ftdi_sio_ids.h | 2 ++ 2 files changed, 3

RE: usbserial_generic

2014-08-13 Thread Kirk Madsen
I can try a patch, but the testing will have to fit in between the primary uses of the machine (we have entirely too few Linux boxes at work, and far too many Windows ones), so there might be a little latency in getting to it. Shouldn't be more than a couple of days though. I was unaware of

Re: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Alan Stern
On Wed, 13 Aug 2014, Felipe Balbi wrote: Keeping track of the pullup's state like that will just add complexity to the UDC drivers. There's really no problem in connecting pullups before VBUS is above session valid threshold. Except that doing so violates the hardware test suite Peter

Re: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Michael Grzeschik
On Wed, Aug 13, 2014 at 09:19:31AM -0500, Felipe Balbi wrote: Hi, On Wed, Aug 13, 2014 at 10:02:08AM -0400, Alan Stern wrote: So here's what the UDC driver should do: If the pullup routine is called while Vbus is off, the driver should leave the D+ pullup disconnected but

Re: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Felipe Balbi
On Wed, Aug 13, 2014 at 06:08:55PM +0200, Michael Grzeschik wrote: On Wed, Aug 13, 2014 at 09:19:31AM -0500, Felipe Balbi wrote: Hi, On Wed, Aug 13, 2014 at 10:02:08AM -0400, Alan Stern wrote: So here's what the UDC driver should do: If the pullup routine is called while

Re: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Felipe Balbi
Hi, On Wed, Aug 13, 2014 at 12:56:27PM -0400, Alan Stern wrote: If you want libcomposite to handle the pullups on behalf of the function drivers, there has to be a way for the UDC driver to tell libcomposite when Vbus turns on and off. Add a new callback to the usb_gadget_driver

RE: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Paul Zimmerman
From: linux-usb-ow...@vger.kernel.org [mailto:linux-usb-ow...@vger.kernel.org] On Behalf Of Felipe Balbi Sent: Wednesday, August 13, 2014 10:20 AM On Wed, Aug 13, 2014 at 12:56:27PM -0400, Alan Stern wrote: If you want libcomposite to handle the pullups on behalf of the function

Re: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Felipe Balbi
Hi, On Wed, Aug 13, 2014 at 07:15:37PM +, Paul Zimmerman wrote: From: linux-usb-ow...@vger.kernel.org [mailto:linux-usb-ow...@vger.kernel.org] On Behalf Of Felipe Balbi Sent: Wednesday, August 13, 2014 10:20 AM On Wed, Aug 13, 2014 at 12:56:27PM -0400, Alan Stern wrote: If

RE: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Paul Zimmerman
From: Felipe Balbi [mailto:ba...@ti.com] Sent: Wednesday, August 13, 2014 12:21 PM On Wed, Aug 13, 2014 at 07:15:37PM +, Paul Zimmerman wrote: From: linux-usb-ow...@vger.kernel.org [mailto:linux-usb-ow...@vger.kernel.org] On Behalf Of Felipe Balbi Sent: Wednesday, August 13,

RE: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Alan Stern
On Wed, 13 Aug 2014, Paul Zimmerman wrote: The UDC driver ought to know when Vbus turns on or off, without polling. It should get an interrupt when that happens, or its ops-vbus_session routine should be called. So at that time, the UDC driver could invoke a new usb_gadget_driver

RE: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Paul Zimmerman
From: Alan Stern [mailto:st...@rowland.harvard.edu] Sent: Wednesday, August 13, 2014 12:46 PM On Wed, 13 Aug 2014, Paul Zimmerman wrote: The UDC driver ought to know when Vbus turns on or off, without polling. It should get an interrupt when that happens, or its

RE: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Alan Stern
On Wed, 13 Aug 2014, Paul Zimmerman wrote: Is there a difference between a VBus on/off and a connect/disconnect? Because AFAIK the Synopsys USB 3.0 controller (unless it is configured for OTG mode) does not have a way to detect when VBus is enabled/ disabled, other than by a

Re: Kernel 3.16.0 USB crash

2014-08-13 Thread Matt
On Wed, Aug 13, 2014 at 10:24 PM, Matt jackdac...@gmail.com wrote: Hi Claudio, this issue is clearly caused by UAS. if zcat /proc/config.gz | grep UAS # CONFIG_USB_UAS is not set is de-selected, everything's fine when this is selected (usb is compiled as a module here) the system

RE: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Paul Zimmerman
From: Alan Stern [mailto:st...@rowland.harvard.edu] Sent: Wednesday, August 13, 2014 2:09 PM On Wed, 13 Aug 2014, Paul Zimmerman wrote: Is there a difference between a VBus on/off and a connect/disconnect? Because AFAIK the Synopsys USB 3.0 controller (unless it is configured

RE: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Paul Zimmerman
From: Felipe Balbi [mailto:ba...@ti.com] Sent: Wednesday, August 13, 2014 3:25 PM On Wed, Aug 13, 2014 at 09:41:17PM +, Paul Zimmerman wrote: From: Alan Stern [mailto:st...@rowland.harvard.edu] Sent: Wednesday, August 13, 2014 2:09 PM On Wed, 13 Aug 2014, Paul Zimmerman wrote:

Re: [RFC PATCH] Revert usb: chipidea: udc: .pullup is valid only when vbus is there

2014-08-13 Thread Peter Chen
On Wed, Aug 13, 2014 at 09:41:17PM +, Paul Zimmerman wrote: From: Alan Stern [mailto:st...@rowland.harvard.edu] Sent: Wednesday, August 13, 2014 2:09 PM On Wed, 13 Aug 2014, Paul Zimmerman wrote: Is there a difference between a VBus on/off and a connect/disconnect?