Re: [PATCH V2] usb: dwc3: gadget: trb_dequeue is not updated properly

2019-07-18 Thread Felipe Balbi
Hi, Let's look at the relevant code: fei.y...@intel.com writes: > From: Fei Yang > > If scatter-gather operation is allowed, a large USB request would be split > into multiple TRBs. These TRBs are chained up by setting DWC3_TRB_CTRL_CHN > bit except the last one which has DWC3_TRB_CTRL_IOC bi

Re: WARNING in shark_write_reg/usb_submit_urb

2019-07-18 Thread Andrey Konovalov
On Tue, Jul 16, 2019 at 4:17 PM Hillf Danton wrote: > > > Hello, > > On Tue, 16 Jul 2019 03:38:05 -0700 (PDT) > > syzbot found the following crash on: > > > > HEAD commit:6a3599ce usb-fuzzer: main usb gadget fuzzer driver > > git tree: https://github.com/google/kasan.git usb-fuzzer > > c

WARNING in snd_usb_apply_boot_quirk/usb_submit_urb

2019-07-18 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:6a3599ce usb-fuzzer: main usb gadget fuzzer driver git tree: https://github.com/google/kasan.git usb-fuzzer console output: https://syzkaller.appspot.com/x/log.txt?x=11a9bbe060 kernel config: https://syzkaller.appspot.com/x/.

Re: WARNING in shark_write_reg/usb_submit_urb

2019-07-18 Thread Alan Stern
On Thu, 18 Jul 2019, Andrey Konovalov wrote: > On Tue, Jul 16, 2019 at 4:17 PM Hillf Danton wrote: > > > > > > Hello, > > > > On Tue, 16 Jul 2019 03:38:05 -0700 (PDT) > > > syzbot found the following crash on: > > > > > > HEAD commit:6a3599ce usb-fuzzer: main usb gadget fuzzer driver > > > gi

RE: [PATCH v2] USB: serial: option: Add support for ZTE MF871A

2019-07-18 Thread OKAMOTO Yoshiaki
Hi Lars, > Please do a full test of the interface attributes (Class/SubClass/Proto) > whenever possible, this could be helpful in case the mfgr makes a device > with different interface layout but re-uses an already used vid:pid. > What should we do specifically for "a full test of the interface

RE: [PATCH V2] usb: dwc3: gadget: trb_dequeue is not updated properly

2019-07-18 Thread Yang, Fei
> Can only be true for last TRB > | if (event->status & DEPEVT_STATUS_IOC) | return 1; This is the problem. The whole USB request gets only one interrupt when the last TRB completes, so dwc3_gadget_ep_reclaim_trb_sg() gets called with event->status = 0x6 which has DEPEVT_STATU

USB Modem support for Droid 4

2019-07-18 Thread Pavel Machek
From: Tony Lindgren Droid starts to have useful support in linux-next. Modem is tricky to play with, but this is enough to get basic support. Signed-off-by: Pavel Machek diff --git a/drivers/usb/serial/qcserial.c b/drivers/usb/serial/qcserial.c index 613f91a..3ca9439 100644 --- a/drivers/usb/s

Re: [PATCH] usb: qmi_wwan: add D-Link DWM-222 A2 device ID

2019-07-18 Thread David Miller
From: Rogan Dawes Date: Wed, 17 Jul 2019 11:14:33 +0200 > Signed-off-by: Rogan Dawes Applied.

[PATCH v3] usb: dwc3: gadget: trb_dequeue is not updated properly

2019-07-18 Thread fei . yang
From: Fei Yang If scatter-gather operation is allowed, a large USB request is split into multiple TRBs. These TRBs are chained up by setting DWC3_TRB_CTRL_CHN bit except the last one which has DWC3_TRB_CTRL_IOC bit set instead. Since only the last TRB has IOC set for the whole USB request, the dw

RE: [PATCH V2] usb: dwc3: gadget: trb_dequeue is not updated properly

2019-07-18 Thread Yang, Fei
> > Can only be true for last TRB > > | if (event->status & DEPEVT_STATUS_IOC) | return 1; > > This is the problem. The whole USB request gets only one interrupt when the > last TRB completes, so dwc3_gadget_ep_reclaim_trb_sg() > gets called with event->status = 0x6 which has D

Re: [PATCH v3] usb: dwc3: gadget: trb_dequeue is not updated properly

2019-07-18 Thread Thinh Nguyen
Hi, fei.y...@intel.com wrote: > From: Fei Yang > > If scatter-gather operation is allowed, a large USB request is split into > multiple TRBs. These TRBs are chained up by setting DWC3_TRB_CTRL_CHN bit > except the last one which has DWC3_TRB_CTRL_IOC bit set instead. > Since only the last TRB has

[PATCH AUTOSEL 5.2 010/171] usb: core: hub: Disable hub-initiated U1/U2

2019-07-18 Thread Sasha Levin
From: Thinh Nguyen [ Upstream commit 561759292774707b71ee61aecc07724905bb7ef1 ] If the device rejects the control transfer to enable device-initiated U1/U2 entry, then the device will not initiate U1/U2 transition. To improve the performance, the downstream port should not initate transition to

[PATCH AUTOSEL 5.2 072/171] usb: gadget: storage: Remove warning message

2019-07-18 Thread Sasha Levin
From: EJ Hsu [ Upstream commit e70b3f5da00119e057b7faa557753fee7f786f17 ] This change is to fix below warning message in following scenario: usb_composite_setup_continue: Unexpected call When system tried to enter suspend, the fsg_disable() will be called to disable fsg driver and send a signal

[PATCH AUTOSEL 5.1 008/141] usb: core: hub: Disable hub-initiated U1/U2

2019-07-18 Thread Sasha Levin
From: Thinh Nguyen [ Upstream commit 561759292774707b71ee61aecc07724905bb7ef1 ] If the device rejects the control transfer to enable device-initiated U1/U2 entry, then the device will not initiate U1/U2 transition. To improve the performance, the downstream port should not initate transition to

[PATCH AUTOSEL 4.14 02/60] usb: core: hub: Disable hub-initiated U1/U2

2019-07-18 Thread Sasha Levin
From: Thinh Nguyen [ Upstream commit 561759292774707b71ee61aecc07724905bb7ef1 ] If the device rejects the control transfer to enable device-initiated U1/U2 entry, then the device will not initiate U1/U2 transition. To improve the performance, the downstream port should not initate transition to

[PATCH AUTOSEL 4.14 22/60] usb: gadget: storage: Remove warning message

2019-07-18 Thread Sasha Levin
From: EJ Hsu [ Upstream commit e70b3f5da00119e057b7faa557753fee7f786f17 ] This change is to fix below warning message in following scenario: usb_composite_setup_continue: Unexpected call When system tried to enter suspend, the fsg_disable() will be called to disable fsg driver and send a signal

[PATCH AUTOSEL 4.9 02/45] usb: core: hub: Disable hub-initiated U1/U2

2019-07-18 Thread Sasha Levin
From: Thinh Nguyen [ Upstream commit 561759292774707b71ee61aecc07724905bb7ef1 ] If the device rejects the control transfer to enable device-initiated U1/U2 entry, then the device will not initiate U1/U2 transition. To improve the performance, the downstream port should not initate transition to

[PATCH AUTOSEL 4.4 14/35] usb: gadget: Zero ffs_io_data

2019-07-18 Thread Sasha Levin
From: Andrzej Pietrasiewicz [ Upstream commit 508595515f4bcfe36246e4a565cf280937aeaade ] In some cases the "Allocate & copy" block in ffs_epfile_io() is not executed. Consequently, in such a case ffs_alloc_buffer() is never called and struct ffs_io_data is not initialized properly. This in turn

[PATCH AUTOSEL 4.4 02/35] usb: core: hub: Disable hub-initiated U1/U2

2019-07-18 Thread Sasha Levin
From: Thinh Nguyen [ Upstream commit 561759292774707b71ee61aecc07724905bb7ef1 ] If the device rejects the control transfer to enable device-initiated U1/U2 entry, then the device will not initiate U1/U2 transition. To improve the performance, the downstream port should not initate transition to

[PATCH AUTOSEL 4.9 17/45] usb: gadget: Zero ffs_io_data

2019-07-18 Thread Sasha Levin
From: Andrzej Pietrasiewicz [ Upstream commit 508595515f4bcfe36246e4a565cf280937aeaade ] In some cases the "Allocate & copy" block in ffs_epfile_io() is not executed. Consequently, in such a case ffs_alloc_buffer() is never called and struct ffs_io_data is not initialized properly. This in turn

[PATCH AUTOSEL 4.14 21/60] usb: gadget: Zero ffs_io_data

2019-07-18 Thread Sasha Levin
From: Andrzej Pietrasiewicz [ Upstream commit 508595515f4bcfe36246e4a565cf280937aeaade ] In some cases the "Allocate & copy" block in ffs_epfile_io() is not executed. Consequently, in such a case ffs_alloc_buffer() is never called and struct ffs_io_data is not initialized properly. This in turn

Re: [PATCH v2] USB: serial: option: Add support for ZTE MF871A

2019-07-18 Thread Lars Melin
On 7/18/2019 21:46, OKAMOTO Yoshiaki wrote: Hi Lars, Please do a full test of the interface attributes (Class/SubClass/Proto) whenever possible, this could be helpful in case the mfgr makes a device with different interface layout but re-uses an already used vid:pid. What should we do specif

[PATCH AUTOSEL 4.19 035/101] usb: gadget: Zero ffs_io_data

2019-07-18 Thread Sasha Levin
From: Andrzej Pietrasiewicz [ Upstream commit 508595515f4bcfe36246e4a565cf280937aeaade ] In some cases the "Allocate & copy" block in ffs_epfile_io() is not executed. Consequently, in such a case ffs_alloc_buffer() is never called and struct ffs_io_data is not initialized properly. This in turn

[PATCH AUTOSEL 4.19 036/101] usb: gadget: storage: Remove warning message

2019-07-18 Thread Sasha Levin
From: EJ Hsu [ Upstream commit e70b3f5da00119e057b7faa557753fee7f786f17 ] This change is to fix below warning message in following scenario: usb_composite_setup_continue: Unexpected call When system tried to enter suspend, the fsg_disable() will be called to disable fsg driver and send a signal

[PATCH AUTOSEL 4.19 005/101] usb: core: hub: Disable hub-initiated U1/U2

2019-07-18 Thread Sasha Levin
From: Thinh Nguyen [ Upstream commit 561759292774707b71ee61aecc07724905bb7ef1 ] If the device rejects the control transfer to enable device-initiated U1/U2 entry, then the device will not initiate U1/U2 transition. To improve the performance, the downstream port should not initate transition to

[PATCH AUTOSEL 5.1 054/141] usb: gadget: storage: Remove warning message

2019-07-18 Thread Sasha Levin
From: EJ Hsu [ Upstream commit e70b3f5da00119e057b7faa557753fee7f786f17 ] This change is to fix below warning message in following scenario: usb_composite_setup_continue: Unexpected call When system tried to enter suspend, the fsg_disable() will be called to disable fsg driver and send a signal

[PATCH AUTOSEL 5.1 052/141] usb: gadget: Zero ffs_io_data

2019-07-18 Thread Sasha Levin
From: Andrzej Pietrasiewicz [ Upstream commit 508595515f4bcfe36246e4a565cf280937aeaade ] In some cases the "Allocate & copy" block in ffs_epfile_io() is not executed. Consequently, in such a case ffs_alloc_buffer() is never called and struct ffs_io_data is not initialized properly. This in turn

[PATCH AUTOSEL 5.2 070/171] usb: dwc3: Fix core validation in probe, move after clocks are enabled

2019-07-18 Thread Sasha Levin
From: Enric Balletbo i Serra [ Upstream commit dc1b5d9aed1794b5a1c6b0da46e372cc09974cbc ] The required clocks needs to be enabled before the first register access. After commit fe8abf332b8f ("usb: dwc3: support clocks and resets for DWC3 core"), this happens when the dwc3_core_is_valid function

[PATCH AUTOSEL 5.2 069/171] usb: gadget: Zero ffs_io_data

2019-07-18 Thread Sasha Levin
From: Andrzej Pietrasiewicz [ Upstream commit 508595515f4bcfe36246e4a565cf280937aeaade ] In some cases the "Allocate & copy" block in ffs_epfile_io() is not executed. Consequently, in such a case ffs_alloc_buffer() is never called and struct ffs_io_data is not initialized properly. This in turn

Re: USB Modem support for Droid 4

2019-07-18 Thread Tony Lindgren
Hi, * Pavel Machek [190718 20:17]: > From: Tony Lindgren > > Droid starts to have useful support in linux-next. Modem is tricky to > play with, but this is enough to get basic support. Below is a better patch using option driver adding support for all the ports. I'll send it out with a proper

Re: [PATCH AUTOSEL 5.1 054/141] usb: gadget: storage: Remove warning message

2019-07-18 Thread Thinh Nguyen
Hi Sasha, Sasha Levin wrote: > From: EJ Hsu > > [ Upstream commit e70b3f5da00119e057b7faa557753fee7f786f17 ] > > This change is to fix below warning message in following scenario: > usb_composite_setup_continue: Unexpected call > > When system tried to enter suspend, the fsg_disable() will be cal