[PATCH v2] phy: rcar-gen3-usb2: add sysfs for usb role swap

2016-11-01 Thread Yoshihiro Shimoda
This patch adds sysfs "otg_inputs" for usb role swap. This parameter is write-only and if you use them as the following, you can swap the usb role. For example: 1) connect a usb cable using 2 salvator-x boards 2) On A-device (as host), you input the following command: # echo a_bus_req/ > /sys

Re: [PATCH 00/82] usb: patch bomb

2016-11-01 Thread Felipe Balbi
Hi, Bin Liu writes: > Hi Felipe, > > On Mon, Oct 31, 2016 at 12:47:52PM +0200, Felipe Balbi wrote: >> Hi guys, >> >> Sorry for the patch bomb, but I wanted to make sure everyoby knows which >> patches are already queued up for the next window. They are still >> sitting in my testing/next branch

Re: [PATCH 51/82] usb: dwc3: gadget: extract dwc3_gadget_get_irq()

2016-11-01 Thread Felipe Balbi
Hi, John Youn writes: > On 10/31/2016 3:51 AM, Felipe Balbi wrote: >> Cleanup only, no functional changes. >> >> Signed-off-by: Felipe Balbi >> --- >> drivers/usb/dwc3/gadget.c | 62 >> +-- >> 1 file changed, 38 insertions(+), 24 deletions(-) >> >

Re: usb: dwc2: NMI watchdog: BUG: soft lockup - CPU#0 stuck for 146s

2016-11-01 Thread Michael Zoran
On Mon, 2016-10-31 at 21:34 +0100, Stefan Wahren wrote: > I inspired by this issue [1] i build up a slightly modified setup > with a > Raspberry Pi B (mainline kernel 4.9rc3), a powered 7 port USB hub and > 5 Prolific > PL2303 USB to serial convertors. I modified the usb_test for dwc2 > [2], which

Re: [PATCH 52/82] usb: dwc3: host: extract dwc3_host_get_irq()

2016-11-01 Thread Felipe Balbi
Hi, John Youn writes: > On 10/31/2016 3:51 AM, Felipe Balbi wrote: >> Cleanup only, no functional changes. >> >> Signed-off-by: Felipe Balbi >> --- >> drivers/usb/dwc3/host.c | 68 >> + >> 1 file changed, 35 insertions(+), 33 deletions(-) >> >

Re: [PATCH 53/82] usb: dwc3: ep0: simplify dwc3_ep0_handle_feature()

2016-11-01 Thread Felipe Balbi
Hi, John Youn writes: >> +static int dwc3_ep0_handle_device(struct dwc3 *dwc, >> struct usb_ctrlrequest *ctrl, int set) >> { >> -struct dwc3_ep *dep; >> -u32 recip; >> +enum usb_device_state state; >> u32 wValue; >

[PATCH] USB: phy: am335x-control: fix device and of_node leaks

2016-11-01 Thread Johan Hovold
Make sure to drop the references taken by of_parse_phandle() and bus_find_device() before returning from am335x_get_phy_control(). Note that there is no guarantee that the devres-managed struct phy_control will be valid for the lifetime of the sibling phy device regardless of this change. Fixes:

Re: [RFC/PATCH 15/45] usb: chipidea: udc: make use of new usb_endpoint_maxp_mult()

2016-11-01 Thread Felipe Balbi
Hi, Peter Chen writes: > On Wed, Sep 28, 2016 at 04:05:24PM +0300, Felipe Balbi wrote: >> We have introduced a helper to calculate multiplier >> value from wMaxPacketSize. Start using it. >> >> Cc: Peter Chen >> Cc: >> Signed-off-by: Felipe Balbi >> --- >> drivers/usb/chipidea/udc.c | 2 +-

Re: [RFC/PATCH 27/45] usb: musb: make use of new usb_endpoint_maxp_mult()

2016-11-01 Thread Felipe Balbi
Hi, Bin Liu writes: > On Wed, Sep 28, 2016 at 04:05:36PM +0300, Felipe Balbi wrote: >> We have introduced a helper to calculate multiplier >> value from wMaxPacketSize. Start using it. >> >> Cc: Bin Liu >> Signed-off-by: Felipe Balbi >> --- >> drivers/usb/musb/musb_gadget.c | 6 +++--- >> dr

Re: [PATCH v2] usb: dwc3: gadget: wait for End Transfer to complete

2016-11-01 Thread Felipe Balbi
Hi, Baolin Wang writes: > Changes since v1: > - Move the suspend checking to right place to avoid checking twice. there is still one problem > @@ -1736,12 +1739,38 @@ static int dwc3_gadget_stop(struct usb_gadget *g) > { > struct dwc3 *dwc = gadget_to_dwc(g); > unsign

[PATCH] uwb: fix device reference leaks

2016-11-01 Thread Johan Hovold
This subsystem consistently fails to drop the device reference taken by class_find_device(). Note that some of these lookup functions already take a reference to the returned data, while others claim no reference is needed (or does not seem need one). Fixes: 183b9b592a62 ("uwb: add the UWB stack

Re: [PATCH] usb: dwc2: gadget: Update for new usb_endpoint_maxp()

2016-11-01 Thread Felipe Balbi
Hi, John Youn writes: > From: Vardan Mikayelyan > > Update the dwc2 driver for the new behavior of the usb_endpoint_maxp() > and also use the new usb_endpoint_maxp_mult() helper function. > > This commit fixes failures in high-badwith ISOC transfer tests. > > Signed-off-by: Vardan Mikayelyan >

Re: [PATCH 3/6] Documentation: devicetree: dwc3: Add interrupt moderation

2016-11-01 Thread Felipe Balbi
Hi, John Youn writes: >> I'm not sure that it makes sense for this to be in the DT, though I may >> have misunderstood. > > I'm ok omitting the DT binding until it is needed by someone. Since we > currently only need it for the workaround, which is detected > automatically. > > Felipe, are you o

Re: [PATCH v2] usb: dwc3: gadget: wait for End Transfer to complete

2016-11-01 Thread Baolin Wang
Hi, On 1 November 2016 at 19:01, Felipe Balbi wrote: > > Hi, > > Baolin Wang writes: >> Changes since v1: >> - Move the suspend checking to right place to avoid checking twice. > > there is still one problem > >> @@ -1736,12 +1739,38 @@ static int dwc3_gadget_stop(struct usb_gadget *g) >> { >>

Re: [PATCH 3/6] Documentation: devicetree: dwc3: Add interrupt moderation

2016-11-01 Thread Felipe Balbi
Hi, John Youn writes: John Youn writes: > Add interrupt moderation interval binding for dwc3. > > Signed-off-by: John Youn > --- > Documentation/devicetree/bindings/usb/dwc3.txt | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/Documentation/devicet

Re: [RFC/PATCH 15/45] usb: chipidea: udc: make use of new usb_endpoint_maxp_mult()

2016-11-01 Thread Peter Chen
On Tue, Nov 01, 2016 at 12:45:25PM +0200, Felipe Balbi wrote: > > Hi, > > Peter Chen writes: > > On Wed, Sep 28, 2016 at 04:05:24PM +0300, Felipe Balbi wrote: > >> We have introduced a helper to calculate multiplier > >> value from wMaxPacketSize. Start using it. > >> > >> Cc: Peter Chen > >>

[balbi-usb:testing/next 52/83] drivers/usb/dwc3/host.c:66:37: error: 'dwc3_pdev' undeclared

2016-11-01 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git testing/next head: 8e6064194bd2243f182c39708d5225b800ab5549 commit: f57045e5f6876c0460dd80d987f337c1eff5547a [52/83] usb: dwc3: host: extract dwc3_host_get_irq() config: i386-randconfig-x007-201644 (attached as .config) compi

[PATCH] usb: gadget: u_ether: remove interrupt throttling

2016-11-01 Thread Felipe Balbi
According to Dave Miller "the networking stack has a hard requirement that all SKBs which are transmitted must have their completion signalled in a fininte amount of time. This is because, until the SKB is freed by the driver, it holds onto socket, netfilter, and other subsystem resources." In sum

Re: [PATCH] Revert "usb: dwc3: gadget: use allocated/queued reqs for LST bit"

2016-11-01 Thread Felipe Balbi
Hi, David Miller writes: > From: Ville Syrjälä > Date: Fri, 28 Oct 2016 19:33:32 +0300 > >> On Fri, Oct 28, 2016 at 01:16:13PM +0300, Felipe Balbi wrote: >>> Yeah, I'm guessing we're gonna need some help from networking folks. The >>> only thing we did since v4.7 was actually respect req->no_in

Linux FTDI driver modifications

2016-11-01 Thread Meindert Sprang
Hello all, I am the developer of the ShipModul (CustomWare) MiniPlex products where we use FTDI chips for USB communications. I see that even the latest PID we use (FD4B) is already in the ftdi_sio.c driver and I'm glad to see the Linux community picks this up to fast. There is one thing how

Re: [PATCH v2] usb: dwc3: gadget: wait for End Transfer to complete

2016-11-01 Thread Felipe Balbi
Hi, Baolin Wang writes: > Hi, > > On 1 November 2016 at 19:01, Felipe Balbi wrote: >> >> Hi, >> >> Baolin Wang writes: >>> Changes since v1: >>> - Move the suspend checking to right place to avoid checking twice. >> >> there is still one problem >> >>> @@ -1736,12 +1739,38 @@ static int dwc3_

Re: [PATCH v2] phy: rcar-gen3-usb2: add sysfs for usb role swap

2016-11-01 Thread Peter Chen
On Tue, Nov 01, 2016 at 04:01:58PM +0900, Yoshihiro Shimoda wrote: > This patch adds sysfs "otg_inputs" for usb role swap. This parameter > is write-only and if you use them as the following, you can swap > the usb role. > > For example: > 1) connect a usb cable using 2 salvator-x boards > 2) On

Re: [PATCH 52/82] usb: dwc3: host: extract dwc3_host_get_irq()

2016-11-01 Thread Felipe Balbi
Hi, Felipe Balbi writes: >>> int dwc3_host_init(struct dwc3 *dwc) >>> { >>> struct property_entry props[2]; >>> struct platform_device *xhci; >>> int ret, irq; >>> struct resource *res; >>> - struct platform_device *dwc3_pdev = to_platform_devic

Re: [PATCH v2] usb: dwc3: gadget: wait for End Transfer to complete

2016-11-01 Thread Baolin Wang
Hi, On 1 November 2016 at 19:36, Felipe Balbi wrote: > > Hi, > > Baolin Wang writes: >> Hi, >> >> On 1 November 2016 at 19:01, Felipe Balbi wrote: >>> >>> Hi, >>> >>> Baolin Wang writes: Changes since v1: - Move the suspend checking to right place to avoid checking twice. >>> >>> th

Re: [PATCH] usb: gadget: u_ether: remove interrupt throttling

2016-11-01 Thread Ville Syrjälä
On Tue, Nov 01, 2016 at 01:29:59PM +0200, Felipe Balbi wrote: > According to Dave Miller "the networking stack has a > hard requirement that all SKBs which are transmitted > must have their completion signalled in a fininte > amount of time. This is because, until the SKB is > freed by the driver,

Re: Linux FTDI driver modifications

2016-11-01 Thread Johan Hovold
On Tue, Nov 01, 2016 at 12:33:45PM +0100, Meindert Sprang wrote: > Hello all, > > I am the developer of the ShipModul (CustomWare) MiniPlex products where > we use FTDI chips for USB communications. > I see that even the latest PID we use (FD4B) is already in the > ftdi_sio.c driver and I'm glad

Re: xhci_hcd crash on linux 4.7.0

2016-11-01 Thread Alex Damian
Hello, Coming back to this old thread. I enabled the xhci debug, with little success. I am running now kernel 4.8.4; there is no dmesg dump anymore, the system just reboots by itself. As I am running kernel crash dump, the system loads the kdump kernel, but doesn't find anything to save. The int

Re: [PATCH v18 0/4] Introduce usb charger framework to deal with the usb gadget power negotation

2016-11-01 Thread Baolin Wang
Hi, On 31 October 2016 at 08:00, NeilBrown wrote: > On Fri, Oct 28 2016, Baolin Wang wrote: > >>> >>> 3/ usb_charger_notify_state() does nothing if the state doesn't change. >>> When the extcon detects an SDP, it will be called to set the state >>> to USB_CHARGER_PRESENT. The value of cur.sd

[GIT PULL] USB fixes for v4.9-rc4

2016-11-01 Thread Felipe Balbi
Hi Greg, Here's another set of fixes for current -rc cycle. Let me know if you want anything to be changed. cheers The following changes since commit a909d3e636995ba7c349e2ca5dbb528154d4ac30: Linux 4.9-rc3 (2016-10-29 13:52:02 -0700) are available in the git repository at: git://git.kern

Re: [GIT PULL] USB fixes for v4.9-rc4

2016-11-01 Thread Greg Kroah-Hartman
On Tue, Nov 01, 2016 at 04:31:07PM +0200, Felipe Balbi wrote: > > Hi Greg, > > Here's another set of fixes for current -rc cycle. Let me know if you > want anything to be changed. Pulled and pushed out, thanks. greg k-h -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in

Re: [dmesg] usb 2-1.5:1.0: rebind failed: -517

2016-11-01 Thread sonofagun
"-517" is -EPROBE_DEFER, it means some resources for this device are not ready. Thanks for the info, I fell on it too on a completely different box but had no time to find what it is. Now it is clear what is going on. Here is how the bug reporter fell on it: dmesg shows that he performed an

Re: [dmesg] usb 2-1.5:1.0: rebind failed: -517

2016-11-01 Thread Cristian
Hello, Run _Always_ start Ubuntu -- Cristian Aravena Romero 2016-10-30 22:21 GMT-03:00 Peter Chen : > On Sat, Oct 29, 2016 at 03:53:24PM -0300, Cristian wrote: >> Hello, >> >> Report in https://bugzilla.kernel.org/show_bug.cgi?id=185591 >> > > You may provide more information about bug, eg, ho

Re: [PATCH v4] usb: musb: remove duplicated actions

2016-11-01 Thread Bin Liu
Hi, On Wed, Oct 26, 2016 at 09:10:07PM +0300, Kirill Esipov wrote: > Removing unnecessary duplicated actions that we've got while merging: > 19915e623458 ("Merge 4.1-rc7 into usb-next") > > Signed-off-by: Kirill Esipov Applied. Thanks. Regards, -Bin. > --- > drivers/usb/musb/musb_core.c | 5

Re: [PATCH] usb: musb: da8xx: Don't print phy error on -EPROBE_DEFER

2016-11-01 Thread Bin Liu
Hi, On Tue, Oct 25, 2016 at 02:02:50PM -0500, David Lechner wrote: > This suppresses printing the error message "failed to get phy" in the > kernel log when the error is -EPROBE_DEFER. This prevents usless noise > in the kernel log. > > Signed-off-by: David Lechner Applied. Thanks. Regards, -B

Re: musb: isoc pkt loss with pwc

2016-11-01 Thread Bin Liu
On Sat, Oct 15, 2016 at 10:25:42PM +0300, Matwey V. Kornilov wrote: [snip] > >>> > Which means without this commit your camera has been working without > >>> > issues, and this is a regression with this commit, right? > >>> > > >>> > >>> Right > >> > >> Okay, thanks for confirming. > >> > >> But

[PATCH 1/2] usb: musb: da8xx: Don't print phy error on -EPROBE_DEFER

2016-11-01 Thread Bin Liu
From: David Lechner This suppresses printing the error message "failed to get phy" in the kernel log when the error is -EPROBE_DEFER. This prevents usless noise in the kernel log. Signed-off-by: David Lechner Signed-off-by: Bin Liu --- drivers/usb/musb/da8xx.c | 3 ++- 1 file changed, 2 inser

[PATCH 0/2] musb-fixes for v4.9-rc4

2016-11-01 Thread Bin Liu
Hi Greg, Here are musb fixes for v4.9-rc4. They are minor cleanup in musb. Please let me know if any change is needed. Thanks, -Bin. --- David Lechner (1): usb: musb: da8xx: Don't print phy error on -EPROBE_DEFER Kirill Esipov (1): usb: musb: remove duplicated actions drivers/usb/musb/da8

[PATCH 2/2] usb: musb: remove duplicated actions

2016-11-01 Thread Bin Liu
From: Kirill Esipov Removing unnecessary duplicated actions that we've got while merging: Commit 19915e623458 ("Merge 4.1-rc7 into usb-next") [ b-...@ti.com: added 'Commit' in the commit message ] Signed-off-by: Kirill Esipov Signed-off-by: Bin Liu --- drivers/usb/musb/musb_core.c | 5 -

Re: [PATCH 0/2] musb-fixes for v4.9-rc2

2016-11-01 Thread Ladislav Michl
Hi, On Mon, Oct 24, 2016 at 11:07:08AM -0700, Tony Lindgren wrote: > Hi, > > * Tony Lindgren [161021 00:18]: > > * Ladislav Michl [161020 12:37]: > > > [ 186.457519] musb-hdrc musb-hdrc.0.auto: VBUS_ERROR in a_wait_bcon (90, > > > > > > > > And that's the end, since now it does not react on

RE: [PATCH v2] phy: rcar-gen3-usb2: add sysfs for usb role swap

2016-11-01 Thread Yoshihiro Shimoda
Hi Peter, > From: Peter Chen [mailto:hzpeterc...@gmail.com] > Sent: Tuesday, November 01, 2016 8:38 PM > > On Tue, Nov 01, 2016 at 04:01:58PM +0900, Yoshihiro Shimoda wrote: > > This patch adds sysfs "otg_inputs" for usb role swap. This parameter > > is write-only and if you use them as the follo

[PATCH 1/1] usb: xhci: remove the use of xhci->addr_dev

2016-11-01 Thread Lu Baolu
xhci->addr_dev is used for the completion of both address device and enable slot commands. It's shared by enumerations of all USB devices connected to an xhci host. Hence, it's just a source for possible races. Since we've introduced command structure and the command queue to xhci driver. It is ti

[PATCH v2 3/6] usb: ehci: fsl: use bus->sysdev for DMA configuration

2016-11-01 Thread Sriram Dash
From: Arnd Bergmann For the dual role ehci fsl driver, sysdev will handle the dma config. Signed-off-by: Arnd Bergmann Signed-off-by: Sriram Dash --- Changes in v2: - fix compile warnings drivers/usb/host/ehci-fsl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/d

[PATCH v2 5/6] usb: dwc3: use bus->sysdev for DMA configuration

2016-11-01 Thread Sriram Dash
From: Arnd Bergmann The dma ops for dwc3 devices are not set properly. So, use a physical device sysdev, which will be inherited from parent, to set the hardware / firmware parameters like dma. Signed-off-by: Arnd Bergmann Signed-off-by: Sriram Dash --- Changes in v2: - integrate dwc3 driver

[PATCH v2 1/6] usb: separate out sysdev pointer from usb_bus

2016-11-01 Thread Sriram Dash
From: Arnd Bergmann For xhci-hcd platform device, all the DMA parameters are not configured properly, notably dma ops for dwc3 devices. The idea here is that you pass in the parent of_node along with the child device pointer, so it would behave exactly like the parent already does. The differenc

[PATCH v2 2/6] usb: chipidea: use bus->sysdev for DMA configuration

2016-11-01 Thread Sriram Dash
From: Arnd Bergmann Set the dma for chipidea from sysdev. This is inherited from its parent node. Also, do not set dma mask for child as it is not required now. Signed-off-by: Arnd Bergmann Signed-off-by: Sriram Dash --- Changes in v2: - integrate chipidea driver changes together. drivers/

[PATCH v2 6/6] usb: dwc3: Do not set dma coherent mask

2016-11-01 Thread Sriram Dash
From: Arnd Bergmann The dma mask is correctly set up by the DT probe function, no need to override it any more. Signed-off-by: Arnd Bergmann Signed-off-by: Sriram Dash --- Changes in v2: - club the cleanup for dma coherent mask for device drivers/usb/dwc3/dwc3-exynos.c | 10 -- dri

[PATCH v2 0/6] inherit dma configuration from parent dev

2016-11-01 Thread Sriram Dash
For xhci-hcd platform device, all the DMA parameters are not configured properly, notably dma ops for dwc3 devices. The idea here is that you pass in the parent of_node along with the child device pointer, so it would behave exactly like the parent already does. The difference is that it also hand

Re: [PATCH] usb: gadget: u_ether: remove interrupt throttling

2016-11-01 Thread Peter Chen
On Tue, Nov 01, 2016 at 01:29:59PM +0200, Felipe Balbi wrote: > According to Dave Miller "the networking stack has a > hard requirement that all SKBs which are transmitted > must have their completion signalled in a fininte > amount of time. This is because, until the SKB is > freed by the driver,

Re: [PATCH v2 2/6] usb: chipidea: use bus->sysdev for DMA configuration

2016-11-01 Thread Peter Chen
On Wed, Nov 02, 2016 at 11:08:09AM +0530, Sriram Dash wrote: > From: Arnd Bergmann > > Set the dma for chipidea from sysdev. This is inherited from its > parent node. Also, do not set dma mask for child as it is not required > now. > > Signed-off-by: Arnd Bergmann > Signed-off-by: Sriram Dash

[PATCH v2 4/6] usb: xhci: use bus->sysdev for DMA configuration

2016-11-01 Thread Sriram Dash
From: Arnd Bergmann For xhci-hcd platform device, all the DMA parameters are not configured properly, notably dma ops for dwc3 devices. So, set the dma for xhci from sysdev. sysdev is pointing to device that is known to the system firmware or hardware. Signed-off-by: Arnd Bergmann Signed-off-by