[PATCH] usb: gadget: Convert use of __constant_cpu_to_le16 to cpu_to_le16

2015-06-05 Thread Vaishali Thakkar
In big endian cases, macro cpu_to_le16 unfolds to __swab16 which provides special case for constants. In little endian cases, __constant_cpu_to_le16 and cpu_to_le16 expand directly to the same expression. So, replace __constant_cpu_to_le16 with cpu_to_le16 with the goal of getting rid of the defini

Re: [PATCH 2/3] usb: chipidea: usbmisc_imx: delete clock information

2015-06-05 Thread Fabio Estevam
On Fri, Jun 5, 2015 at 2:58 PM, Maciej S. Szmigiero wrote: > That was a good lead, I've looked at imx6qdl-udoo.dtsi definition of usbh1 > USB host > device and it overrides clock property from imx6qdl.dtsi (USBOH3) with a > clock that is > used to drive on-board USB hub. > > After commenting ou

Re: USB3 external HDD not recognized [regression]

2015-06-05 Thread Ralf Jung
Hi, >>> I got some untested and not yet reviewed usb3 resume race fixes from Zhuang >>> Jin Can >>> If you can try them out and see if they help it would be great. >>> They are sitting in a topic branch called "xhci_usb3_pm_fixes" in my tree: >>> (5 extra patches on top of current usb-linus) >>>

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

2015-06-05 Thread Felipe Balbi
Hi, On Fri, Jun 05, 2015 at 10:09:03PM +0200, Pali Rohár wrote: > On Friday 29 May 2015 18:57:06 Felipe Balbi wrote: > > All right, I tried merging it and it added build breaks to the tree. > > I'll wait for another version for v4.3 merge window. > > > > cheers > > Hello, version below compiles

Re: SuperSpeed usb-storage, yet runs at 5Mbyte/sec

2015-06-05 Thread Alan Stern
On Fri, 5 Jun 2015, Mark Hills wrote: > On Fri, 5 Jun 2015, Alan Stern wrote: > > > On Fri, 5 Jun 2015, Mark Hills wrote: > > > > > I have a new USB 3.0 hard drive which appears to be throttled at > > > approx 5Mbyte/sec. > > > > > > Is there a mystery kernel option that is required to enable

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

2015-06-05 Thread Pali Rohár
On Friday 29 May 2015 18:57:06 Felipe Balbi wrote: > All right, I tried merging it and it added build breaks to the tree. > I'll wait for another version for v4.3 merge window. > > cheers Hello, version below compiles fine on top of linus tree. Please apply: diff --git a/drivers/usb/gadget/legac

[PATCH 0/7] musb-sunxi / phy-sun4i-usb: Add suppor for new SoCs

2015-06-05 Thread Hans de Goede
Hi Felipe and Kishon, This musb-sunxi / phy-sun4i-usb series adds supports for the otg and host usb-phys found on newer sunxi SoCs and for the musb ip found on newer sunxi SoCs. This series sits on top of the 2 still outstanding musb-sunxi / phy-sun4i-usb patches. These patches (and the 2 still

[PATCH 5/7] musb: sunxi: Remove special MUSB_SUN4I flag for clearing ep0 addr on disconnect

2015-06-05 Thread Hans de Goede
We can cleanly handle this inside the sunxi glue, instead of adding special casing to the core, but setting ep0 addr to 0 on a reset interrupt. Signed-off-by: Hans de Goede --- drivers/usb/musb/musb_core.h| 1 - drivers/usb/musb/musb_gadget.c | 6 -- drivers/usb/musb/musb_virthub.c | 6

[PATCH 6/7] musb: sunxi: Add support for musb controller in A31 SoC

2015-06-05 Thread Hans de Goede
The A31 SoC uses the same musb controller as found in earlier SoCs, but it is hooked up slightly different. Its SRAM is private and no longer controlled through the SRAM controller, and its reset is controlled via a separate reset controller. This commit adds support for this setup. Signed-off-by:

[PATCH 7/7] musb: sunxi: Add support for musb controller in A33 SoC

2015-06-05 Thread Hans de Goede
The A33 SoC uses the same musb controller as found on the A31 and later, but allwinner has removed the configdata register, this commit adds special handling for this. Signed-off-by: Hans de Goede --- .../devicetree/bindings/usb/allwinner,sun4i-a10-musb.txt | 3 ++- drivers/usb/musb/sunxi.c

[PATCH 4/7] phy-sun4i-usb: Add support for boards with broken Vusb-detection

2015-06-05 Thread Hans de Goede
On some boards we cannot detect the presence of an external Vusb, because e.g. the 5V of the otg connector is directly connected to the 5V of the board, and thus is always high. This commit adds support for using such boards by only looking at the id-detection pin. Signed-off-by: Hans de Goede -

[PATCH 1/7] phy-sun4i-usb: Swap check for disconnect threshold

2015-06-05 Thread Hans de Goede
Before this commit the code for determining the disconnect threshold was checking for "allwinner,sun4i-a10-usb-phy" or "allwinner,sun6i-a31-usb-phy" assuming that those where the exception and then newer SoCs would use a disconnect threshold of 2 like sun7i does. But it turns out that newer SoCs us

[PATCH 2/7] phy-sun4i-usb: Add support for the usb-phys on the sun8i-a23 SoC

2015-06-05 Thread Hans de Goede
The usb-phys on the sun8i-a23 SoC have the same setup wrt clocks as on the sun6i-a31 SoC, but there are only 2 instead of 3 like on the sun5i-a13 SoC. Signed-off-by: Hans de Goede --- Documentation/devicetree/bindings/phy/sun4i-usb-phy.txt | 2 ++ drivers/phy/phy-sun4i-usb.c

[PATCH 3/7] phy-sun4i-usb: Add support for the usb-phys on the sun8i-a33 SoC

2015-06-05 Thread Hans de Goede
The usb-phys on the sun8i-a33 SoC are mostly the same as sun8i-a23 but for some reason (hw bug?) the phyctl register was moved to a different address and is not initialized to 0 on reset. Signed-off-by: Hans de Goede --- .../devicetree/bindings/phy/sun4i-usb-phy.txt | 1 + drivers/phy/phy-

Re: SuperSpeed usb-storage, yet runs at 5Mbyte/sec

2015-06-05 Thread Mark Hills
On Fri, 5 Jun 2015, Alan Stern wrote: > On Fri, 5 Jun 2015, Mark Hills wrote: > > > I have a new USB 3.0 hard drive which appears to be throttled at > > approx 5Mbyte/sec. > > > > Is there a mystery kernel option that is required to enable full > > performance on these new drives? > > > > I h

Re: [PATCH 2/3] usb: chipidea: usbmisc_imx: delete clock information

2015-06-05 Thread Maciej S. Szmigiero
W dniu 05.06.2015 05:38, Peter Chen pisze: > On Fri, Jun 05, 2015 at 12:12:19AM +0200, Maciej S. Szmigiero wrote: >> Hi Peter, >> >>> All imx usb controller's non core registers uses the same clock gate with >>> core registers, the usbmisc_imx is the library for imx glue driver, the >>> glue keeps

Re: [ehci-orion] ETIMEOUT with ehci_setup()'s ehci_halt()

2015-06-05 Thread Andrew Lunn
On Fri, Jun 05, 2015 at 04:34:54PM +0200, Valentin Longchamp wrote: > Hello, > > I am currently bringing up the USB 2.0 Host controller of the Bobcat's > (98DX4122 > Marvell switch) internal kirkwood CPU on a variation of Keymile's km_kirwood > hardware (kirkwood-km_kirkwood.dts). > > When the d

Re: SuperSpeed usb-storage, yet runs at 5Mbyte/sec

2015-06-05 Thread Alan Stern
On Fri, 5 Jun 2015, Mark Hills wrote: > I have a new USB 3.0 hard drive which appears to be throttled at > approx 5Mbyte/sec. > > Is there a mystery kernel option that is required to enable full > performance on these new drives? > > I have tried changing following: > > * Switching onboard US

[ehci-orion] ETIMEOUT with ehci_setup()'s ehci_halt()

2015-06-05 Thread Valentin Longchamp
Hello, I am currently bringing up the USB 2.0 Host controller of the Bobcat's (98DX4122 Marvell switch) internal kirkwood CPU on a variation of Keymile's km_kirwood hardware (kirkwood-km_kirkwood.dts). When the driver registers its hcd, it fails with a timemout as it can be seen in the below log:

Re: [GIT PULL] USB-serial fixes for v4.1-rc7

2015-06-05 Thread Greg Kroah-Hartman
On Fri, Jun 05, 2015 at 03:32:37PM +0200, Johan Hovold wrote: > Hi Greg, > > Here are two new device ids for 4.1 (unless you prefer to wait until > 4.2-rc1). > > Thanks, > Johan > > > The following changes since commit e26081808edadfd257c6c9d81014e3b25e9a6118: > > Linux 4.1-rc4 (2015-05-18 1

[PATCH 0/3] usb: dwc2: fix sleep while atomic bugs

2015-06-05 Thread Mian Yousaf Kaukab
This series fixes 3 sources of sleep while atomic bugs. Including the one reported by Heiko Stuebner here: http://www.spinics.net/lists/linux-usb/msg125186.html Please review. Thank you, Best regards, Yousaf Mian Yousaf Kaukab (3): usb: dwc2: host: allocate qh before atomic enqueue usb: dwc

[PATCH 3/3] usb: dwc2: embed storage for reg backup in struct dwc2_hsotg

2015-06-05 Thread Mian Yousaf Kaukab
Register backup function can be called from atomic context. Instead of using atomic memory pool, embed backup storage space in struct dwc2_hsotg. Also add a valid flag in each struct as NULL pointer can't be used as the content validity check any more. Signed-off-by: Mian Yousaf Kaukab --- driv

[PATCH 2/3] usb: dwc2: host: allocate qtd before atomic enqueue

2015-06-05 Thread Mian Yousaf Kaukab
To avoid sleep while atomic bugs, allocate qtd before calling dwc2_hcd_urb_enqueue. No need to pass mem_flags to dwc2_hcd_urb_enqueue any more as no memory allocations are done in it. Signed-off-by: Mian Yousaf Kaukab --- drivers/usb/dwc2/hcd.c | 26 -- 1 file changed, 16

[PATCH 1/3] usb: dwc2: host: allocate qh before atomic enqueue

2015-06-05 Thread Mian Yousaf Kaukab
To avoid sleep while atomic bugs, allocate qh before calling dwc2_hcd_urb_enqueue. qh pointer can be used directly now instead of passing ep->hcpriv as double pointer. Signed-off-by: Mian Yousaf Kaukab --- drivers/usb/dwc2/hcd.c | 31 ++ drivers/usb/dwc2/hcd.h

Re: [GIT PULL] USB-serial updates for v4.2-rc1

2015-06-05 Thread Greg Kroah-Hartman
On Fri, Jun 05, 2015 at 03:29:39PM +0200, Johan Hovold wrote: > The following changes since commit e26081808edadfd257c6c9d81014e3b25e9a6118: > > Linux 4.1-rc4 (2015-05-18 10:13:47 -0700) > > are available in the git repository at: > > git://git.kernel.org/pub/scm/linux/kernel/git/johan/usb-s

[GIT PULL] USB-serial fixes for v4.1-rc7

2015-06-05 Thread Johan Hovold
Hi Greg, Here are two new device ids for 4.1 (unless you prefer to wait until 4.2-rc1). Thanks, Johan The following changes since commit e26081808edadfd257c6c9d81014e3b25e9a6118: Linux 4.1-rc4 (2015-05-18 10:13:47 -0700) are available in the git repository at: git://git.kernel.org/pub/sc

[GIT PULL] USB-serial updates for v4.2-rc1

2015-06-05 Thread Johan Hovold
The following changes since commit e26081808edadfd257c6c9d81014e3b25e9a6118: Linux 4.1-rc4 (2015-05-18 10:13:47 -0700) are available in the git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/johan/usb-serial.git tags/usb-serial-4.2-rc1 for you to fetch changes up to f05b7cb6f

SuperSpeed usb-storage, yet runs at 5Mbyte/sec

2015-06-05 Thread Mark Hills
I have a new USB 3.0 hard drive which appears to be throttled at approx 5Mbyte/sec. Is there a mystery kernel option that is required to enable full performance on these new drives? I have tried changing following: * Switching onboard USB 2.0 interfaces for a completely new USB 3.0 interfac

Re: [PATCH v3] usb: chipidea: Use extcon framework for VBUS and ID detect

2015-06-05 Thread Peter Chen
On Fri, Jun 05, 2015 at 10:37:07AM +0300, Ivan T. Ivanov wrote: > > On Fri, 2015-06-05 at 15:03 +0800, Peter Chen wrote: > > On Tue, Jun 02, 2015 at 04:14:33PM +0300, Ivan T. Ivanov wrote: > > > On recent Qualcomm platforms VBUS and ID lines are not routed to > > > USB PHY LINK controller. Use ext

[PATCH 0/2] handle thread in error case

2015-06-05 Thread Sanjay Singh Rawat
This patch set handles storage thread in error case. Sanjay Singh Rawat (2): usb: gadget: f_mass_storage: stop thread in bind failure case usb: gadget: f_mass_storage: defer storage thread wakeup drivers/usb/gadget/function/f_mass_storage.c | 12 1 file changed, 8 insertions(+),

[PATCH 2/2] usb: gadget: f_mass_storage: defer storage thread wakeup

2015-06-05 Thread Sanjay Singh Rawat
As the bind configuration is not complete during thread creation, defering the thread wake to end of bind. Signed-off-by: Sanjay Singh Rawat --- drivers/usb/gadget/function/f_mass_storage.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/usb/gadget/function/f_mas

[PATCH 1/2] usb: gadget: f_mass_storage: stop thread in bind failure case

2015-06-05 Thread Sanjay Singh Rawat
After the worker thread is launched, bind function is doing further configuration. In case of failure stop the thread. Signed-off-by: Sanjay Singh Rawat --- drivers/usb/gadget/function/f_mass_storage.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/usb/gadget/