[PATCH] [media] Prefer gspca_sonixb over sn9c102 for all devices

2014-04-11 Thread Jean Delvare
The sn9c102 driver is deprecated. It was moved to staging in anticipation of its removal in a future kernel version. However, USB devices 0C45:6024 and 0C45:6025 are still handled by sn9c102 when both sn9c102 and gspca_sonixb are enabled. We must migrate all the users of these devices to the

Re: [PATCH] cdc-acm: some enhancement on acm delayed write

2014-04-11 Thread Johan Hovold
[ +CC: Jiri and Peter ] On Thu, Apr 10, 2014 at 10:02:03AM +0200, Oliver Neukum wrote: On Wed, 2014-04-09 at 22:57 +0800, Xiao Jin wrote: Thanks all for the review. We meet with the problems when developing product. I would like to explain my understanding. On 04/08/2014 11:05 AM, Xiao

[RFC 1/2] n_tty: fix dropped output characters

2014-04-11 Thread Johan Hovold
Fix characters being dropped by n_tty_write() due to a failure to check the return value of tty_put_char() in do_output_char(). Characters are currently being dropped by write if a tty driver claims to have write room available, but still fails to buffer any data (e.g. if a driver without

[RFC 2/2] USB: cdc-acm: fix broken runtime suspend

2014-04-11 Thread Johan Hovold
The current runtime suspend implementation is broken in several ways: Firstly, it buffers only the first write request being made while suspended -- any further writes are silently dropped. Secondly, writes being dropped also leak write urbs which are never reclaimed (until the device is

Re: [PATCH] cdc-acm: some enhancement on acm delayed write

2014-04-11 Thread Johan Hovold
On Tue, Apr 08, 2014 at 12:22:22PM +0200, Oliver Neukum wrote: On Tue, 2014-04-08 at 09:33 +0200, Johan Hovold wrote: On Tue, Apr 08, 2014 at 11:05:20AM +0800, Xiao Jin wrote: We find two problems on acm tty write delayed mechanism. Then you should split this into two patches. (1)

[PATCH net] r8152: check RTL8152_UNPLUG

2014-04-11 Thread Hayes Wang
When the device is unplugged, the driver would try to disable the device. Add checking the flag of RTL8152_UNPLUG to skip setting the device when it is unplugged. This could shorten the time of unloading the driver. Signed-off-by: Hayes Wang hayesw...@realtek.com --- drivers/net/usb/r8152.c | 48

[PATCH] usb: gadget: f_subset: replace PTR_RET with PTR_ERR_OR_ZERO

2014-04-11 Thread Duan Jiong
PTR_RET is deprecated. Do not recommend its usage anymore. Use PTR_ERR_OR_ZERO instead. Signed-off-by: Duan Jiong duanj.f...@cn.fujitsu.com --- drivers/usb/gadget/f_subset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/gadget/f_subset.c

Re: [PATCH] cdc-acm: some enhancement on acm delayed write

2014-04-11 Thread Oliver Neukum
On Fri, 2014-04-11 at 06:51 +0800, Xiao Jin wrote: Hi, Oliver, On 04/10/2014 04:02 PM, Oliver Neukum wrote: On Wed, 2014-04-09 at 22:57 +0800, Xiao Jin wrote: Thanks all for the review. We meet with the problems when developing product. I would like to explain my understanding. On

Deadlock v3.10.35 with FTD_SIO usb-serial adapter

2014-04-11 Thread Matteo Fortini
We are experiencing stuck processes (D state) which are talking to an FTD_SIO usb_serial adapter. The process sometimes has to close the serial device when it detects an error or a timeout. We rebuilt the kernel with the CONFIG_DEBUG_USB option and the stuck processes reporting enabled. The

[RFC 0/4] Enable U1/U2 initiation from dwc3 xhci host

2014-04-11 Thread Pratyush Anand
These patches provides support of LPM capability to the dwc3 xhci hosts. LPM capability is disabled by default. Any dwc3 based platform can enable it through device tree. Patches have been tested on STih407 by Aymen BOUATTAY. Pratyush Anand (4): dwc3: dts: Binding information for an optional

[RFC 1/4] dwc3: dts: Binding information for an optional property lpm_capable

2014-04-11 Thread Pratyush Anand
If a dwc3 host implementation is lpm capable then enable lpm_capable in device tree. Signed-off-by: Pratyush Anand pratyush.an...@st.com --- Documentation/devicetree/bindings/usb/dwc3.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/usb/dwc3.txt

[RFC 4/4] xhci: Platform: Add (en/dis)able_usb3_lpm_timeout

2014-04-11 Thread Pratyush Anand
To use auto U0-U1/U2 transition by xhci platform device add (en/dis)able_usb3_lpm_timeout function to the xhci_plat_xhci_driver struct. Signed-off-by: Pratyush Anand pratyush.an...@st.com --- drivers/usb/host/xhci-plat.c | 3 +++ 1 file changed, 3 insertions(+) diff --git

[RFC 2/4] dwc3: host: Set xhci quirk for LPM if a platform supports it

2014-04-11 Thread Pratyush Anand
If a platform supports LPM then enable quirk in XHCI for the same. Signed-off-by: Pratyush Anand pratyush.an...@st.com --- drivers/usb/dwc3/core.c | 1 + drivers/usb/dwc3/core.h | 1 + drivers/usb/dwc3/host.c | 2 ++ 3 files changed, 4 insertions(+) diff --git a/drivers/usb/dwc3/core.c

[RFC 3/4] xhci: A default implementation for Ux timeout calculation and tier policy check

2014-04-11 Thread Pratyush Anand
As best case, a host controller should support U0 to U1 switching for the devices connected below any tier of hub level supported by usb specification. Therefore xhci_check_default_tier_policy always returns success. A host should be able to issue LGO_Ux after the timeout calculated as per

[RFC 0/2] Support for Super Speed Link Layer Test

2014-04-11 Thread Pratyush Anand
Lecroy's USB Compliance suites provide option to test Link Layer Tests for Super Speed device as well as host. As of now there is no standard way to test embedded host for these tests. These patches modifies Linux USB host stack to carry out these tests for embedded hosts. Modifications are

[RFC 2/2] USB: Add LVS Test device driver

2014-04-11 Thread Pratyush Anand
There are many Link Layer Tests which needs host to generate specific traffic. This driver provides a way to do that. For root hub n there would be different sysfs nodes corresponding to each specific traffic generation case. For example: 1. To issue Get Device descriptor command for TD.7.06:

[RFC 1/2] USB: Core: Quirk to prevent enumeration of LVS devices

2014-04-11 Thread Pratyush Anand
For an xhci host's downstream port, Link Validation System (LVS) is a hardware which acts as device and used to run link layer tests. Most of the link layer tests only expects link to be in U0. If a host sends a setup packet, it is NAKed by LVS. However, there are some tests which ask host to send

RE: i.MX51 ChipIdea USB device endpoints questions

2014-04-11 Thread Ebright, Dave
Peter, Thanks for your response. I understand that currently for the i.MX51 in the ChipIdea drivers that the DEN value is 8 which results in defining endpoints ep[0-7]in and ep[0-7]out. I am looking to develop a piece of automated test equipment and drivers that emulates an existing device

Re: Deadlock v3.10.35 with FTD_SIO usb-serial adapter

2014-04-11 Thread Greg KH
On Fri, Apr 11, 2014 at 12:19:55PM +0200, Matteo Fortini wrote: We are experiencing stuck processes (D state) which are talking to an FTD_SIO usb_serial adapter. The process sometimes has to close the serial device when it detects an error or a timeout. Does this also happen with 3.14?

Re: [PATCH] [media] Prefer gspca_sonixb over sn9c102 for all devices

2014-04-11 Thread Greg Kroah-Hartman
On Fri, Apr 11, 2014 at 09:15:32AM +0200, Jean Delvare wrote: The sn9c102 driver is deprecated. It was moved to staging in anticipation of its removal in a future kernel version. However, USB devices 0C45:6024 and 0C45:6025 are still handled by sn9c102 when both sn9c102 and gspca_sonixb are

RE: libusbg and vbus detection for UDC driver

2014-04-11 Thread Krzysztof Opasiak
Hey, Nice to know that someone else is also interested in usage of libusbg library:) -Original Message- From: linux-usb-ow...@vger.kernel.org [mailto:linux-usb- ow...@vger.kernel.org] On Behalf Of Matt Porter Sent: Thursday, April 10, 2014 11:14 PM To: Philippe De Swert Cc:

Re: libusbg and vbus detection for UDC driver

2014-04-11 Thread 'Matt Porter'
On Fri, Apr 11, 2014 at 06:20:42PM +0200, Krzysztof Opasiak wrote: 1. It seems that libusbg from Matt Porter seems the library to use. Is that correct? I saw patches on the mailing list, but they did not seem to have made it to: https://github.com/libusbg/libusbg I think it's the

Re: [RFC 2/4] dwc3: host: Set xhci quirk for LPM if a platform supports it

2014-04-11 Thread Felipe Balbi
On Fri, Apr 11, 2014 at 03:50:04PM +0530, Pratyush Anand wrote: If a platform supports LPM then enable quirk in XHCI for the same. Signed-off-by: Pratyush Anand pratyush.an...@st.com --- drivers/usb/dwc3/core.c | 1 + drivers/usb/dwc3/core.h | 1 + drivers/usb/dwc3/host.c | 2 ++ 3 files

Re: [RFC 1/4] dwc3: dts: Binding information for an optional property lpm_capable

2014-04-11 Thread Felipe Balbi
On Fri, Apr 11, 2014 at 03:50:03PM +0530, Pratyush Anand wrote: If a dwc3 host implementation is lpm capable then enable lpm_capable in device tree. Signed-off-by: Pratyush Anand pratyush.an...@st.com --- Documentation/devicetree/bindings/usb/dwc3.txt | 2 ++ 1 file changed, 2

Re: [PATCHv5 2/4] usb: s3c-hsotg: Move s3c-hsotg into dwc2 folder

2014-04-11 Thread Felipe Balbi
On Fri, Mar 14, 2014 at 01:51:50PM -0500, dingu...@altera.com wrote: From: Dinh Nguyen dingu...@altera.com Moves the s3c-hsotg driver into the dwc2 folder and use the dwc2 defines in hw.h. Renamed the s3c-hsotg.c to gadget.c. Signed-off-by: Dinh Nguyen dingu...@altera.com Tested-by:

Re: [PATCHv5 3/4] usb: s3c-hsotg: Move s3c-hsotg data structures

2014-04-11 Thread Felipe Balbi
On Fri, Mar 14, 2014 at 01:51:51PM -0500, dingu...@altera.com wrote: From: Dinh Nguyen dingu...@altera.com This patch moves the data structures that are in the s3c-hsotg source into core.h. This is a necessary step towards unifying the s3c-hsotg and dwc2 into a single DRD. Signed-off-by:

Re: [RFC 3/4] xhci: A default implementation for Ux timeout calculation and tier policy check

2014-04-11 Thread Felipe Balbi
On Fri, Apr 11, 2014 at 03:50:05PM +0530, Pratyush Anand wrote: As best case, a host controller should support U0 to U1 switching for the devices connected below any tier of hub level supported by usb specification. Therefore xhci_check_default_tier_policy always returns success. A host

Re: [PATCHv5 4/4] usb: dwc2: Edit the Kconfig and Makefile to build dwc2_gadget driver

2014-04-11 Thread Felipe Balbi
On Fri, Mar 14, 2014 at 01:51:52PM -0500, dingu...@altera.com wrote: From: Dinh Nguyen dingu...@altera.com Modify the dwc2 Kconfig and Makefile so that it will build the dwc2_gadget driver when peripheral only mode is selected. The dwc_platform.ko and dwc2.ko will get built when dynamic

Re: [RFC 1/4] dwc3: dts: Binding information for an optional property lpm_capable

2014-04-11 Thread Pratyush Anand
On Fri, Apr 11, 2014 at 11:24 PM, Felipe Balbi ba...@ti.com wrote: On Fri, Apr 11, 2014 at 03:50:03PM +0530, Pratyush Anand wrote: If a dwc3 host implementation is lpm capable then enable lpm_capable in device tree. Signed-off-by: Pratyush Anand pratyush.an...@st.com ---

Re: [PATCHv5 2/4] usb: s3c-hsotg: Move s3c-hsotg into dwc2 folder

2014-04-11 Thread Felipe Balbi
On Fri, Apr 11, 2014 at 01:01:31PM -0500, Felipe Balbi wrote: On Fri, Mar 14, 2014 at 01:51:50PM -0500, dingu...@altera.com wrote: From: Dinh Nguyen dingu...@altera.com Moves the s3c-hsotg driver into the dwc2 folder and use the dwc2 defines in hw.h. Renamed the s3c-hsotg.c to gadget.c.

Re: [RFC 2/4] dwc3: host: Set xhci quirk for LPM if a platform supports it

2014-04-11 Thread Pratyush Anand
On Fri, Apr 11, 2014 at 11:26 PM, Felipe Balbi ba...@ti.com wrote: On Fri, Apr 11, 2014 at 03:50:04PM +0530, Pratyush Anand wrote: If a platform supports LPM then enable quirk in XHCI for the same. Signed-off-by: Pratyush Anand pratyush.an...@st.com --- drivers/usb/dwc3/core.c | 1 +

Re: [RFC 1/4] dwc3: dts: Binding information for an optional property lpm_capable

2014-04-11 Thread Felipe Balbi
On Fri, Apr 11, 2014 at 11:36:18PM +0530, Pratyush Anand wrote: On Fri, Apr 11, 2014 at 11:24 PM, Felipe Balbi ba...@ti.com wrote: On Fri, Apr 11, 2014 at 03:50:03PM +0530, Pratyush Anand wrote: If a dwc3 host implementation is lpm capable then enable lpm_capable in device tree.

RE: [RFC 1/4] dwc3: dts: Binding information for an optional property lpm_capable

2014-04-11 Thread Paul Zimmerman
From: Pratyush Anand [mailto:pratyush.an...@gmail.com] Sent: Friday, April 11, 2014 11:06 AM On Fri, Apr 11, 2014 at 11:24 PM, Felipe Balbi ba...@ti.com wrote: On Fri, Apr 11, 2014 at 03:50:03PM +0530, Pratyush Anand wrote: If a dwc3 host implementation is lpm capable then enable

Re: [RFC 3/4] xhci: A default implementation for Ux timeout calculation and tier policy check

2014-04-11 Thread Pratyush Anand
On Fri, Apr 11, 2014 at 11:29 PM, Felipe Balbi ba...@ti.com wrote: On Fri, Apr 11, 2014 at 03:50:05PM +0530, Pratyush Anand wrote: As best case, a host controller should support U0 to U1 switching for the devices connected below any tier of hub level supported by usb specification. Therefore

RE: [PATCHv5 2/4] usb: s3c-hsotg: Move s3c-hsotg into dwc2 folder

2014-04-11 Thread Paul Zimmerman
From: Felipe Balbi [mailto:ba...@ti.com] Sent: Friday, April 11, 2014 11:04 AM On Fri, Apr 11, 2014 at 01:01:31PM -0500, Felipe Balbi wrote: On Fri, Mar 14, 2014 at 01:51:50PM -0500, dingu...@altera.com wrote: From: Dinh Nguyen dingu...@altera.com Moves the s3c-hsotg driver into

Re: [PATCHv5 2/4] usb: s3c-hsotg: Move s3c-hsotg into dwc2 folder

2014-04-11 Thread Felipe Balbi
On Fri, Apr 11, 2014 at 06:40:36PM +, Paul Zimmerman wrote: From: Felipe Balbi [mailto:ba...@ti.com] Sent: Friday, April 11, 2014 11:04 AM On Fri, Apr 11, 2014 at 01:01:31PM -0500, Felipe Balbi wrote: On Fri, Mar 14, 2014 at 01:51:50PM -0500, dingu...@altera.com wrote: From:

Re: [RFC 3/4] xhci: A default implementation for Ux timeout calculation and tier policy check

2014-04-11 Thread Felipe Balbi
Hi, On Sat, Apr 12, 2014 at 12:04:27AM +0530, Pratyush Anand wrote: +static u16 xhci_calculate_default_u1_timeout(struct usb_device *udev, + struct usb_endpoint_descriptor *desc) +{ + unsigned long long timeout_ns; + + timeout_ns = udev-u1_params.sel; + +

Re: [PATCH 0/3] Fix USB deadlock caused by SCSI error handling

2014-04-11 Thread Andreas Reis
I did set the scsi_logging_level as you wrote, but it still resulted into exactly the same dmesg (resp. sudo journalctl -b 0) output with the entire patchset (including the scmd-eh_eflags = 0;). Except for the reverted do nothings, for course. However, I did miss to mention the following

[PATCH] USB: cdc-acm: fix double usb_autopm_put_interface() in acm_port_activate()

2014-04-11 Thread Alexey Khoroshilov
If acm_submit_read_urbs() fails in acm_port_activate(), error handling code calls usb_autopm_put_interface() while it is already called before acm_submit_read_urbs(). The patch reorganizes error handling code to avoid double decrement of USB interface's PM-usage counter. Found by Linux Driver

Re: About the DRD mode implementation of DWC3 driver]

2014-04-11 Thread Felipe Balbi
Hi, On Fri, Apr 11, 2014 at 10:23:38AM +0800, Wang, Yu wrote: Hi Balbi, At first, thank you to help give the response in patience. Hi, On Wed, Apr 09, 2014 at 02:08:32PM +0800, Wang, Yu wrote: Glad to see the OTG mode is prepare to support in your dwc3-role-switch branch. But it

Re: [PATCH] phy: exynos5-usbdrd: Add facility to toggle vbus gpio on/off

2014-04-11 Thread Felipe Balbi
On Wed, Apr 09, 2014 at 05:24:45PM +0530, Vivek Gautam wrote: Adding support to enable/disable VBUS hooked to a gpio to enable vbus supply on the port. Signed-off-by: Vivek Gautam gautam.vi...@samsung.com --- Based on 'phy-exynos5-usbdrd' patches: [PATCH V4 0/5] Add Exynos5 USB 3.0 phy

[PATCH v4] Add support for using a MAX3421E chip as a host driver.

2014-04-11 Thread David Mosberger
This is v4 of the patch. Compared to v3, the only changes are: - addition of a platform-data header file which allows a platform to define which general-purpose output pin controls Vbus (if any) - spi_wr_fifo/spi_rd_fifo got renamed to spi_wr_buf/spi_rd_buf,