Fwd: Antwort: Re: vUDC

2016-12-09 Thread Krzysztof Opasiak
FYI to the list for next generations;) Forwarded Message Subject: Antwort: Re: vUDC Date: Fri, 9 Dec 2016 09:00:04 +0100 From: Elen Niedermeyer To: Krzysztof Opasiak Hi, so your script solved my problem. I didn't know that I should start the daemon with 'usbipd --device' af

[GIT PULL] USB-serial fixes for v4.10-rc1

2016-12-09 Thread Johan Hovold
Hi Greg, Here are some more device ids that could go into v4.10-rc1 unless you prefer I resend these after rc1 is out. Both commits have been in linux-next for a couple of days. Thanks, Johan The following changes since commit 3e5de27e940d00d8d504dfb96625fb654f641509: Linux 4.9-rc8 (2016-12-

Re: [RFC][PATCH] HACK: usb: dwc2: Workaround case where GOTGCTL state is wrong

2016-12-09 Thread Chen Yu
On 2016/12/9 15:32, John Stultz wrote: > On Thu, Dec 8, 2016 at 11:09 PM, Chen Yu wrote: >> On 2016/12/9 7:29, John Youn wrote: >>> On 12/8/2016 2:43 PM, John Stultz wrote: On Tue, Dec 6, 2016 at 7:52 PM, John Youn wrote: > On 12/6/2016 5:48 PM, John Stultz wrote: >> This patch wor

Re: ch341

2016-12-09 Thread Aidan Thornton
On Fri, Dec 9, 2016 at 3:26 AM, Russell Senior wrote: > On Thu, Dec 8, 2016 at 10:02 AM, Johan Hovold wrote: >> On Thu, Dec 08, 2016 at 04:41:44AM -0800, Russell Senior wrote: >>> > "Johan" == Johan Hovold writes: >>> >>> [...] >>> >>> Johan> Ok, and you were using a terminal program such as

Re: [GIT PULL] USB-serial fixes for v4.10-rc1

2016-12-09 Thread Greg Kroah-Hartman
On Fri, Dec 09, 2016 at 11:00:27AM +0100, Johan Hovold wrote: > Hi Greg, > > Here are some more device ids that could go into v4.10-rc1 unless you > prefer I resend these after rc1 is out. Both commits have been in > linux-next for a couple of days. > > Thanks, > Johan > > > The following chang

Re: [GIT PULL] USB-serial fixes for v4.10-rc1

2016-12-09 Thread Johan Hovold
On Fri, Dec 09, 2016 at 11:45:06AM +0100, Greg Kroah-Hartman wrote: > On Fri, Dec 09, 2016 at 11:00:27AM +0100, Johan Hovold wrote: > > Hi Greg, > > > > Here are some more device ids that could go into v4.10-rc1 unless you > > prefer I resend these after rc1 is out. Both commits have been in > > l

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

2016-12-09 Thread Roger Quadros
Hi, On 17/11/16 13:43, Sriram Dash wrote: > 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

[hid:for-4.10/i2c-hid 6/7] drivers/hid/i2c-hid/i2c-hid.c:1048:23: error: implicit declaration of function 'devm_regulator_get'

2016-12-09 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid.git for-4.10/i2c-hid head: de3c99488609284e454cf2b4420a789038a4cfa8 commit: ead0687fe304a66a24e3d809d1070684f3abee71 [6/7] HID: i2c-hid: support regulator power on/off config: x86_64-randconfig-x015-201649 (attached as .config) c

Re: [hid:for-4.10/i2c-hid 6/7] drivers/hid/i2c-hid/i2c-hid.c:1048:23: error: implicit declaration of function 'devm_regulator_get'

2016-12-09 Thread Jiri Kosina
On Fri, 9 Dec 2016, kbuild test robot wrote: > tree: https://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid.git > for-4.10/i2c-hid > head: de3c99488609284e454cf2b4420a789038a4cfa8 > commit: ead0687fe304a66a24e3d809d1070684f3abee71 [6/7] HID: i2c-hid: support > regulator power on/off > con

Re: [PATCH 1/1 v2] input: usbhid: fix improper return value

2016-12-09 Thread Jiri Kosina
On Mon, 5 Dec 2016, Pan Bian wrote: > Function hid_post_reset() should return negative error codes on > failures. However, in its implementation, it incorrectly returns 1. > This patch fixes the bug, returning proper error codes on failures. Applied to for-4.10/upstream. Thanks, -- Jiri Kosina

Re: ch341

2016-12-09 Thread Johan Hovold
On Thu, Dec 08, 2016 at 07:26:26PM -0800, Russell Senior wrote: > On Thu, Dec 8, 2016 at 10:02 AM, Johan Hovold wrote: > > On Thu, Dec 08, 2016 at 04:41:44AM -0800, Russell Senior wrote: > >> > "Johan" == Johan Hovold writes: > >> > >> [...] > >> > >> Johan> Ok, and you were using a terminal

Re: ch341

2016-12-09 Thread Johan Hovold
On Fri, Dec 09, 2016 at 10:21:32AM +, Aidan Thornton wrote: > On Fri, Dec 9, 2016 at 3:26 AM, Russell Senior > wrote: > > On Thu, Dec 8, 2016 at 10:02 AM, Johan Hovold wrote: > >> On Thu, Dec 08, 2016 at 04:41:44AM -0800, Russell Senior wrote: > >>> > "Johan" == Johan Hovold writes: > >

Re: [PATCH net 1/2] r8152: fix the sw rx checksum is unavailable

2016-12-09 Thread Mark Lord
On 16-12-08 10:23 PM, Hayes Wang wrote: > Mark Lord > > I find an issue about autosuspend, and it may result in the same > problem with you. I don't sure if this is helpful to you, because > it only occurs when enabling the autosuspend. Thanks. I am using ASIX adapters now. I did try the lates

Re: Emulating USB devices from userspace

2016-12-09 Thread Andrey Konovalov
On Fri, Dec 9, 2016 at 8:20 AM, Greg Kroah-Hartman wrote: > On Fri, Dec 09, 2016 at 12:38:23AM +0100, Andrey Konovalov wrote: >> Hi, >> >> I'm working on a way to extend syzkaller [1] to support fuzzing of the >> USB subsystem. The idea is to be able to emulate various USB devices >> and fuzz comm

Re: Emulating USB devices from userspace

2016-12-09 Thread Felipe Balbi
Hi, Andrey Konovalov writes: > On Fri, Dec 9, 2016 at 8:20 AM, Greg Kroah-Hartman > wrote: >> On Fri, Dec 09, 2016 at 12:38:23AM +0100, Andrey Konovalov wrote: >>> Hi, >>> >>> I'm working on a way to extend syzkaller [1] to support fuzzing of the >>> USB subsystem. The idea is to be able to emu

Re: Fwd: Antwort: Re: vUDC

2016-12-09 Thread Shuah Khan
Hi Krzysztof, On 12/09/2016 01:43 AM, Krzysztof Opasiak wrote: > FYI to the list for next generations;) > > > Forwarded Message > Subject: Antwort: Re: vUDC > Date: Fri, 9 Dec 2016 09:00:04 +0100 > From: Elen Niedermeyer > To: Krzysztof Opasiak > > > Hi, > > so your script

Re: [v1] usb:gadget:legacy:nokia :- Check for NULL in nokia_bind_config

2016-12-09 Thread Michal Nazarewicz
On Thu, Dec 08 2016, Arvind Yadav wrote: > Here, f_acm,f_ecm and f_msg needs to be checked for being NULL > in nokia_bind_config() before calling usb_add_function(), > otherwise kernel can run into a NULL-pointer dereference. > > f_phonet, f_obex1 and f_obex2 need to be checked for NULL > in nokia_

Re: ch341

2016-12-09 Thread Russell Senior
>> Okay, I built your usb-linus >> >> 46490c347df406b3368680dd911620e52dc7bfa4 >> >> with the line: >> >>r = ch341_control_out(dev, 0x9a, 0x2518, 0x0050); >> >> commented out. More precisely: > >> Loopback works, and also interoperates with pl2303 (through a null >> modem adapter). > > Interes

Re: ch341

2016-12-09 Thread Russell Senior
> Also, when the above change makes usb-linus works, does changing the > word size appear to work after probe? I'm not sure what changing the word size is supposed to do. The usb-linus + previous patch in loopback seems to work with minicom regardless of wordsize. More so even than I would guess

Re: ch341

2016-12-09 Thread Karl Palsson
Can you actually trust that pl2303 module? They're not exactly known for being trouble free, and have often been cloned in the past as well, with varyings levels of success. Do you have a cp210x or ft23x at all? This is one of the great pitfalls of loopback testing, it doesn't test that anything

Re: [PATCH] usb: dwc3: omap: Fix imprecise external abort and oops on boot

2016-12-09 Thread Roger Quadros
Hi Tony, On 08/12/16 05:21, Tony Lindgren wrote: > Somehow starting with v4.9-rc7 there have been imprecise > external aborts on omap5-uevm dwc3 controller. I have not been > able to bisect what exactly triggered this as it does not always > happen. It seems that something changed with probing tha

Re: Emulating USB devices from userspace

2016-12-09 Thread Alan Stern
On Fri, 9 Dec 2016, Felipe Balbi wrote: > Hi, > > Andrey Konovalov writes: > > On Fri, Dec 9, 2016 at 8:20 AM, Greg Kroah-Hartman > > wrote: > >> On Fri, Dec 09, 2016 at 12:38:23AM +0100, Andrey Konovalov wrote: > >>> Hi, > >>> > >>> I'm working on a way to extend syzkaller [1] to support fuzzi

Re: [PATCH] usb: dwc3: omap: Fix imprecise external abort and oops on boot

2016-12-09 Thread Tony Lindgren
* Roger Quadros [161209 08:09]: > Hi Tony, > > On 08/12/16 05:21, Tony Lindgren wrote: > > Somehow starting with v4.9-rc7 there have been imprecise > > external aborts on omap5-uevm dwc3 controller. I have not been > > able to bisect what exactly triggered this as it does not always > > happen. I

[PATCH] tools: usb: usbip: Add simple script to show how to setup vUDC

2016-12-09 Thread Krzysztof Opasiak
Add some simple script which creates a USB gadget using ConfigFS and then exports it using vUDC. This may be useful for people who just started playing with USB/IP and vUDC as it shows exact steps how to setup all stuff. Signed-off-by: Krzysztof Opasiak --- tools/usb/usbip/vudc/vudc_server_exam

Re: Fwd: Antwort: Re: vUDC

2016-12-09 Thread Krzysztof Opasiak
On 12/09/2016 03:43 PM, Shuah Khan wrote: > Hi Krzysztof, > > On 12/09/2016 01:43 AM, Krzysztof Opasiak wrote: >> FYI to the list for next generations;) >> >> >> Forwarded Message >> Subject: Antwort: Re: vUDC >> Date: Fri, 9 Dec 2016 09:00:04 +0100 >> From: Elen Niedermeyer >

Re: [PATCH] tools: usb: usbip: Add simple script to show how to setup vUDC

2016-12-09 Thread Krzysztof Opasiak
On 12/09/2016 06:07 PM, Krzysztof Opasiak wrote: > Add some simple script which creates a USB gadget using ConfigFS > and then exports it using vUDC. > > This may be useful for people who just started playing with > USB/IP and vUDC as it shows exact steps how to setup all stuff. > > Signed-off-

[PATCH v2] tools: usb: usbip: Add simple script to show how to setup vUDC

2016-12-09 Thread Krzysztof Opasiak
Add some simple script which creates a USB gadget using ConfigFS and then exports it using vUDC. This may be useful for people who just started playing with USB/IP and vUDC as it shows exact steps how to setup all stuff. Signed-off-by: Krzysztof Opasiak --- Changes since v1: - Fix terminology mi

Re: [PATCH] usb: dwc3: omap: Fix imprecise external abort and oops on boot

2016-12-09 Thread Grygorii Strashko
On 12/08/2016 05:55 PM, Tony Lindgren wrote: > * Grygorii Strashko [161208 15:38]: >> On 12/08/2016 04:57 PM, Tony Lindgren wrote: >>> Seems to work based on few boot tests. Probably both should be applied, >>> my original patch to prevent spurious interrupts before things are >>> initialized, >

[PATCH 1/2] dt-bindings: usb: add DT binding for s3c2410 USB device controller

2016-12-09 Thread Sergio Prado
Adds the device tree bindings description for Samsung S3C2410 and compatible USB device controller. Signed-off-by: Sergio Prado --- .../devicetree/bindings/usb/s3c2410-usb.txt| 28 ++ 1 file changed, 28 insertions(+) diff --git a/Documentation/devicetree/bindings/usb

[PATCH 2/2] usb: gadget: s3c2410: allow probing from device tree

2016-12-09 Thread Sergio Prado
Allows configuring Samsung's s3c2410 and compatible USB device controller using a devicetree. Signed-off-by: Sergio Prado --- drivers/usb/gadget/udc/s3c2410_udc.c | 142 +-- drivers/usb/gadget/udc/s3c2410_udc.h | 4 + 2 files changed, 123 insertions(+), 23 delet

[PATCH 0/2] usb: gadget: s3c2410: add device tree support

2016-12-09 Thread Sergio Prado
This series adds support for configuring Samsung's s3c2410 and compatible USB device controller via devicetree. Tested on FriendlyARM mini2440, based on s3c2440 SoC. Sergio Prado (2): dt-bindings: usb: add DT binding for s3c2410 USB device controller usb: gadget: s3c2410: allow probing from d

Re: usb/gadget: use-after-free in gadgetfs_setup

2016-12-09 Thread Alan Stern
On Fri, 9 Dec 2016, Andrey Konovalov wrote: > On Wed, Dec 7, 2016 at 8:15 PM, Alan Stern wrote: > > On Wed, 7 Dec 2016, Andrey Konovalov wrote: > > > >> > And in any case, is there any way you can post the series of system > >> > calls that syzkaller makes so we can tell what went wrong? > >> > >

[PATCH 1/1] Increase USB transfer limit

2016-12-09 Thread Mateusz Berezecki
This patch promotes a variable keeping track of USB transfer memory usage to a wider data type, allowing higher bandwidth transfers from a large number of USB devices connected to a single host. Signed-off-by: Mateusz Berezecki --- drivers/usb/core/devio.c | 24 1 file c

[PATCH] USB: gadgetfs: fix use-after-free bug

2016-12-09 Thread Alan Stern
Andrey Konovalov reports that fuzz testing with syzkaller causes a KASAN use-after-free bug report in gadgetfs: BUG: KASAN: use-after-free in gadgetfs_setup+0x208a/0x20e0 at addr 88003dfe5bf2 Read of size 2 by task syz-executor0/22994 CPU: 3 PID: 22994 Comm: syz-executor0 Not tainted 4.9.0-rc

[PATCH] USB: gadgetfs: fix unbounded memory allocation bug

2016-12-09 Thread Alan Stern
Andrey Konovalov reports that fuzz testing with syzkaller causes a KASAN warning in gadgetfs: BUG: KASAN: slab-out-of-bounds in dev_config+0x86f/0x1190 at addr 88003c47e160 Write of size 65537 by task syz-executor0/6356 CPU: 3 PID: 6356 Comm: syz-executor0 Not tainted 4.9.0-rc7+ #19 Hardware

[PATCH] USB: gadgetfs: fix checks of wTotalLength in config descriptors

2016-12-09 Thread Alan Stern
Andrey Konovalov's fuzz testing of gadgetfs showed that we should improve the driver's checks for valid configuration descriptors passed in by the user. In particular, the driver needs to verify that the wTotalLength value in the descriptor is not too short (smaller than USB_DT_CONFIG_SIZE). And

[PATCH] USB: gadgetfs: remove unnecessary assignment

2016-12-09 Thread Alan Stern
The dev_config() routine in gadgetfs has a check that dev->dev->bNumConfigurations is equal to 1, and then contains a redundant line of code setting the value to 1. This patch removes the unnecessary assignment. Signed-off-by: Alan Stern --- [as1819] drivers/usb/gadget/legacy/inode.c |

Re: [PATCH 1/1] Increase USB transfer limit

2016-12-09 Thread Alan Stern
On Fri, 9 Dec 2016, Mateusz Berezecki wrote: > This patch promotes a variable keeping track of USB transfer memory > usage to a wider data type, allowing higher bandwidth transfers from a > large number of USB devices connected to a single host. > > Signed-off-by: Mateusz Berezecki > --- > driv

Re: [PATCH 1/1] Increase USB transfer limit

2016-12-09 Thread Mateusz Berezecki
On 9 Dec 2016, at 12:37, Alan Stern wrote: On Fri, 9 Dec 2016, Mateusz Berezecki wrote: This patch promotes a variable keeping track of USB transfer memory usage to a wider data type, allowing higher bandwidth transfers from a large number of USB devices connected to a single host. Signed

[PATCH] usb: dwc3: omap: remove devm_request_threaded_irq

2016-12-09 Thread Grygorii Strashko
Switch back from devm_request_threaded_irq() to request_threaded_irq() to avoid races between interrupt handler execution and PM runtime in error handling code path in probe and in dwc3_omap_remove(): in probe: ... err1: pm_runtime_put_sync(dev); ^^ PM runtime can race with IRQ handler wh

[PATCH 1/1] Increase USB transfer limit

2016-12-09 Thread Mateusz Berezecki
Promote a variable keeping track of USB transfer memory usage to a wider data type and allow for higher bandwidth transfers from a large number of USB devices connected to a single host. Signed-off-by: Mateusz Berezecki --- drivers/usb/core/devio.c | 22 +++--- 1 file changed, 11

Re: [RFT PATCH 1/1] xhci: free xhci virtual devices with leaf nodes first

2016-12-09 Thread Guenter Roeck
On Wed, Nov 30, 2016 at 01:41:24PM +0200, Mathias Nyman wrote: > On 28.11.2016 22:24, Guenter Roeck wrote: > >On Wed, Nov 23, 2016 at 02:24:27PM +0200, Mathias Nyman wrote: > >>the tt_info provided by a HS hub might be in use to by a child device > >>Make sure we free the devices in the correct ord

Re: usb:xhci: support disable usb2 LPM Remote Wakeup

2016-12-09 Thread Rob Herring
On Sun, Dec 04, 2016 at 07:42:01PM +0700, Thang Q. Nguyen wrote: > From: Thang Nguyen > > As per USB 2.0 link power management addendum ECN, table 1-2, page 4, > device or host initiated via resume signaling; device-initiated resumes > can be optionally enabled/disabled by software. This patch ad

Re: [PATCH v2] tools: usb: usbip: Add simple script to show how to setup vUDC

2016-12-09 Thread Shuah Khan
Hi Krzysztof, Thanks for getting to this so quickly. Couple of comments below: On 12/09/2016 10:15 AM, Krzysztof Opasiak wrote: > Add some simple script which creates a USB gadget using ConfigFS > and then exports it using vUDC. > > This may be useful for people who just started playing with > U

Re: [PATCH 1/1] Increase USB transfer limit

2016-12-09 Thread Alan Stern
On Fri, 9 Dec 2016, Mateusz Berezecki wrote: > Promote a variable keeping track of USB transfer memory usage to a > wider data type and allow for higher bandwidth transfers from a large > number of USB devices connected to a single host. > > Signed-off-by: Mateusz Berezecki > --- > drivers/usb/

Re: [PATCH] usb: dwc3: omap: remove devm_request_threaded_irq

2016-12-09 Thread Tony Lindgren
* Grygorii Strashko [161209 12:55]: > Switch back from devm_request_threaded_irq() to request_threaded_irq() to > avoid races between interrupt handler execution and PM runtime in error > handling code path in probe and in dwc3_omap_remove(): Can't you just call disable_irq() on the exit path ins

Re: ch341

2016-12-09 Thread Russell Senior
Hi Karl, The pl2303 has always worked in 8N1 mode for me, talking to serial devices. That's all I can say with certainty. On Fri, Dec 9, 2016 at 8:00 AM, Karl Palsson wrote: > > Can you actually trust that pl2303 module? They're not exactly > known for being trouble free, and have often been cl

Re: [PATCH] usb: dwc3: omap: remove devm_request_threaded_irq

2016-12-09 Thread Grygorii Strashko
On 12/09/2016 03:59 PM, Tony Lindgren wrote: * Grygorii Strashko [161209 12:55]: Switch back from devm_request_threaded_irq() to request_threaded_irq() to avoid races between interrupt handler execution and PM runtime in error handling code path in probe and in dwc3_omap_remove(): Can't you

Re: [PATCH] usb: dwc3: omap: remove devm_request_threaded_irq

2016-12-09 Thread Tony Lindgren
* Grygorii Strashko [161209 14:46]: > > > On 12/09/2016 03:59 PM, Tony Lindgren wrote: > > * Grygorii Strashko [161209 12:55]: > > > Switch back from devm_request_threaded_irq() to request_threaded_irq() to > > > avoid races between interrupt handler execution and PM runtime in error > > > hand

Re: [PATCH 1/1] Increase USB transfer limit

2016-12-09 Thread Mateusz Berezecki
On 9 Dec 2016, at 13:50, Alan Stern wrote: On Fri, 9 Dec 2016, Mateusz Berezecki wrote: /* Limit on the total amount of memory we can allocate for transfers */ -static unsigned usbfs_memory_mb = 16; +static u32 usbfs_memory_mb = 16; module_param(usbfs_memory_mb, uint, 0644); MODULE_PARM_DE

Re: [PATCH] usb: dwc3: omap: remove devm_request_threaded_irq

2016-12-09 Thread Grygorii Strashko
On 12/09/2016 05:04 PM, Tony Lindgren wrote: > * Grygorii Strashko [161209 14:46]: >> >> >> On 12/09/2016 03:59 PM, Tony Lindgren wrote: >>> * Grygorii Strashko [161209 12:55]: Switch back from devm_request_threaded_irq() to request_threaded_irq() to avoid races between interrupt hand

Re: [PATCH] usb: dwc3: omap: remove devm_request_threaded_irq

2016-12-09 Thread Tony Lindgren
* Grygorii Strashko [161209 15:32]: > > > On 12/09/2016 05:04 PM, Tony Lindgren wrote: > > * Grygorii Strashko [161209 14:46]: > >> > >> > >> On 12/09/2016 03:59 PM, Tony Lindgren wrote: > >>> * Grygorii Strashko [161209 12:55]: > Switch back from devm_request_threaded_irq() to request_th

Re: [PATCH] usb: dwc3: omap: remove devm_request_threaded_irq

2016-12-09 Thread Grygorii Strashko
On 12/09/2016 05:37 PM, Tony Lindgren wrote: * Grygorii Strashko [161209 15:32]: On 12/09/2016 05:04 PM, Tony Lindgren wrote: * Grygorii Strashko [161209 14:46]: On 12/09/2016 03:59 PM, Tony Lindgren wrote: * Grygorii Strashko [161209 12:55]: Switch back from devm_request_threaded_i

Should xhci_irq() call usb_hc_died()?

2016-12-09 Thread Bjorn Helgaas
Hi Mathias, ehci_irq(), ohci_irq(), fotg210_irq(), and oxu210_hcd_irq() contain code equivalent to this: status = ehci_readl(...); if (status == ~(u32) 0) { ... usb_hc_died(hcd); ... return IRQ_HANDLED; } xhci_irq() has a similar check, but does not call usb_hc_died(): s