[PATCH v3 2/3] USB: PD: define specific requests

2016-03-10 Thread Oliver Neukum
This takes the definitions of requests from chapter 9.3.1 of the USB Power Delivery spec. Signed-off-by: Oliver Neukum --- include/uapi/linux/usb/ch9.h | 7 +++ 1 file changed, 7 insertions(+) diff --git a/include/uapi/linux/usb/ch9.h b/include/uapi/linux/usb/ch9.h index 1046c55..78e95ca

[PATCH v4 1/3] USB: add descriptors from USB Power Delivery spec

2016-03-10 Thread Oliver Neukum
Adding the descriptors of chapter 9.2 of the Power Delivery spec. Signed-off-by: Oliver Neukum --- include/uapi/linux/usb/ch9.h | 98 1 file changed, 98 insertions(+) diff --git a/include/uapi/linux/usb/ch9.h b/include/uapi/linux/usb/ch9.h index

[PATCH v4 2/3] USB: PD: define specific requests

2016-03-10 Thread Oliver Neukum
This takes the definitions of requests from chapter 9.3.1 of the USB Power Delivery spec. Signed-off-by: Oliver Neukum --- include/uapi/linux/usb/ch9.h | 7 +++ 1 file changed, 7 insertions(+) diff --git a/include/uapi/linux/usb/ch9.h b/include/uapi/linux/usb/ch9.h index b98fc05..4abd964

[PATCH v4]adding definitions for USB PD to headers

2016-03-10 Thread Oliver Neukum
This patch set adds to definitions from chapter 9 of the Power Delivery spec to the header files so that they can be better used. It is a conservative selection and adds only a minimum. -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vge

[PATCH v4 3/3] USB: PD: additional feature selectors

2016-03-10 Thread Oliver Neukum
This adds the feature selectors from Table 9-8 Signed-off-by: Oliver Neukum --- include/uapi/linux/usb/ch9.h | 16 1 file changed, 16 insertions(+) diff --git a/include/uapi/linux/usb/ch9.h b/include/uapi/linux/usb/ch9.h index 4abd964..08104bc 100644 --- a/include/uapi/linux

Re: system awareness of endpoints

2016-03-14 Thread Oliver Neukum
On Sat, 2016-03-12 at 20:30 -0800, Greg KH wrote: > On Sat, Mar 12, 2016 at 07:56:03PM -0800, bruce m beach wrote: > > I believe I can change the Device descriptors in firmware, > > upload the new firmware and reboot the stick but wouldn't > > the usb subsystem have the old device descriptor from t

Re: "reset full-speed USB device number 6 using ehci-pci" with Dell Inspiron 15R 5537

2016-03-14 Thread Oliver Neukum
On Fri, 2016-03-11 at 11:54 -0500, Alan Stern wrote: > Perhaps I didn't do a good job of addressing the real underlying > problem. That's why I asked if this was the right approach. > > In Daniel's case, usbhid_start() never got called. Perhaps that's the > real problem? Anyway, this meant tha

[RFT] digi_acceleport: do sanity checking for the number of ports

2016-03-14 Thread Oliver Neukum
The driver can be crashed with devices that expose crafted descriptors with too few endpoints. See: http://seclists.org/bugtraq/2016/Mar/61 Signed-off-by: Oliver Neukum --- drivers/usb/serial/digi_acceleport.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/usb/serial

[RFT] sanity checking in digiport driver

2016-03-14 Thread Oliver Neukum
This addresses the DoS issue with respect to checking the number of ports Ralf reported here: http://seclists.org/bugtraq/2016/Mar/61 Could someone with the requisite hardware please test? Regards Oliver -- To unsubscribe from this list: send the line "unsubscribe linux-us

Re: "reset full-speed USB device number 6 using ehci-pci" with Dell Inspiron 15R 5537

2016-03-14 Thread Oliver Neukum
On Mon, 2016-03-14 at 11:03 -0400, Alan Stern wrote: > On Mon, 14 Mar 2016, Oliver Neukum wrote: > > It seems to me that hid_resume_common() needs to be split into three > > parts > > > > a) doing the stuff for pending resets > > b) conditionally re

Re: [PATCH] USB: cdc-acm: add support for Sagem Monetel ELC930

2016-03-15 Thread Oliver Neukum
On Tue, 2016-03-15 at 00:04 +, Nicolas Saenz Julienne wrote: > Hi, > the device is missing all the ACM specific "extra" info on it's interface > descriptor. Which seems be triggering the "Zero length descriptor references" > error during the probe function. Adding the NO_UNION_NORMAL quirk see

[PATCH] cdc-acm: more sanity checking

2016-03-15 Thread Oliver Neukum
An attack has become available which pretends to be a quirky device circumventing normal sanity checks and crashes the kernel by an insufficient number of interfaces. This patch adds a check to the code path for quirky devices. Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org --- drivers

Re: [PATCH] watchdog: add driver for StreamLabs USB watchdog device

2016-03-16 Thread Oliver Neukum
On Wed, 2016-03-16 at 00:57 +, Alexey Klimov wrote: > Hi Oliver, > > On Thu, Mar 10, 2016 at 9:23 AM, Oliver Neukum wrote: > > On Thu, 2016-03-10 at 02:29 +, Alexey Klimov wrote: > >> + streamlabs_wdt->buffer[3] = 0x80; > >> + > >> +

Re: [PATCH] usb_driver_claim_interface: add sanity checking

2016-03-18 Thread Oliver Neukum
On Wed, 2016-03-16 at 10:41 -0400, Alan Stern wrote: > While adding your check to usb_driver_claim_interface() is a reasonable > thing to do, it might not solve all the problems. A driver might still > try to use the invalid interface pointer (perhaps when writing out an > error message). It wou

[PATCH] mct_u232: sanity checking in probe

2016-03-18 Thread Oliver Neukum
An attack using the lack of sanity checking in probe is known. This patch checks for the existance of a second port. CVE-2016-3136 Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org --- drivers/usb/serial/mct_u232.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/usb/serial

[PATCH] usb_driver_claim_interface: add sanity checking

2016-03-18 Thread Oliver Neukum
Attacks that trick drivers into passing a NULL pointer to usb_driver_claim_interface() using forged descriptors are known. This thwarts them by sanity checking. Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org --- drivers/usb/core/driver.c | 6 +- 1 file changed, 5 insertions(+), 1

Re: [PATCH] usb_driver_claim_interface: add sanity checking

2016-03-19 Thread Oliver Neukum
On Thu, 2016-03-17 at 12:44 +0100, Oliver Neukum wrote: > On Wed, 2016-03-16 at 10:41 -0400, Alan Stern wrote: > > > While adding your check to usb_driver_claim_interface() is a reasonable > > thing to do, it might not solve all the problems. A driver might still > >

[PATCH] digi_acceleport: do sanity checking for the number of ports

2016-03-19 Thread Oliver Neukum
The driver can be crashed with devices that expose crafted descriptors with too few endpoints. See: http://seclists.org/bugtraq/2016/Mar/61 Signed-off-by: Oliver Neukum --- drivers/usb/serial/digi_acceleport.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/usb/serial

Re: [PATCH] usb_driver_claim_interface: add sanity checking

2016-03-19 Thread Oliver Neukum
On Wed, 2016-03-16 at 10:08 -0400, Alan Stern wrote: > On Wed, 16 Mar 2016, Oliver Neukum wrote: > > > Attacks that trick drivers into passing a NULL pointer > > to usb_driver_claim_interface() using forged descriptors are > > known. This thwarts them by sanity checking.

[PATCH] cypress_m8: add sanity checking

2016-03-19 Thread Oliver Neukum
An attack using missing endpoints exists. CVE-2016-3137 Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org --- drivers/usb/serial/cypress_m8.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/usb/serial/cypress_m8.c b/drivers/usb/serial/cypress_m8.c

[RFT] digi_acceleport: do sanity checking for the number of ports

2016-03-19 Thread Oliver Neukum
The driver can be crashed with devices that expose crafted descriptors with too few endpoints. See: http://seclists.org/bugtraq/2016/Mar/61 Signed-off-by: Oliver Neukum --- drivers/usb/serial/digi_acceleport.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/usb/serial

Re: [PATCH v7 1/4] gadget: Introduce the usb charger framework

2016-03-19 Thread Oliver Neukum
On Wed, 2016-03-16 at 19:46 +0800, Baolin Wang wrote: > This patch introduces the usb charger driver based on usb gadget that > makes an enhancement to a power driver. It works well in practice but > that requires a system with suitable hardware. > > The basic conception of the usb charger is that

Re: [PATCH] digi_acceleport: do sanity checking for the number of ports

2016-03-19 Thread Oliver Neukum
expected bulk-out endpoints are available) How about this version? We really should have a way to specify that to the generic serial driver. Regards Oliver From 75c015b7281411abbfc4c148e648786258cffedb Mon Sep 17 00:00:00 2001 From: Oliver Neukum Date: Mon, 14 Mar 2

[PATCH v3] cypress_m8: add sanity checking

2016-03-19 Thread Oliver Neukum
An attack using missing endpoints exists. CVE-2016-3137 Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org v1 - add sanity check v2 - add error logging v3 - correct error message --- drivers/usb/serial/cypress_m8.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff

[PATCH] ims-pcu: sanity check against missing interfaces

2016-03-19 Thread Oliver Neukum
A malicious device missing interface can make the driver oops. Add sanity checking. Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org --- drivers/input/misc/ims-pcu.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/input/misc/ims-pcu.c b/drivers/input/misc/ims-pcu.c index

[PATCH] mct_u232: sanity checking in probe

2016-03-19 Thread Oliver Neukum
An attack using the lack of sanity checking in probe is known. This patch checks for the existance of a second port. CVE-2016-3136 Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org --- drivers/usb/serial/mct_u232.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/usb/serial

[PATCH] cypress_m8: add sanity checking

2016-03-20 Thread Oliver Neukum
An attack using missing endpoints exists. CVE-2016-3137 Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org --- drivers/usb/serial/cypress_m8.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/usb/serial/cypress_m8.c b/drivers/usb/serial/cypress_m8.c index 01bf533..1c6cbf5

Re: [PATCH] lan78xx: Protect runtime_auto check by #ifdef CONFIG_PM

2016-03-21 Thread Oliver Neukum
On Sun, 2016-03-20 at 11:43 +0100, Geert Uytterhoeven wrote: > If CONFIG_PM=n: > > drivers/net/usb/lan78xx.c: In function ‘lan78xx_get_stats64’: > drivers/net/usb/lan78xx.c:3274: error: ‘struct dev_pm_info’ has no > member named ‘runtime_auto’ > > If PM is disabled, the runtime_auto flag

Re: [PATCH] usb: Wait before re-enabling a port that has been disabled due to EMI

2016-03-21 Thread Oliver Neukum
On Sun, 2016-03-20 at 18:09 +0100, Guido Trentalancia wrote: > Hello. > > Considering that EM interference can last for a while (generally up to > seconds), I am currently testing the following patch for module usbcore > so that it is possible to specify an amount of time to wait before > trying t

Re: "reset full-speed USB device number 6 using ehci-pci" with Dell Inspiron 15R 5537

2016-03-21 Thread Oliver Neukum
On Fri, 2016-03-18 at 12:36 -0400, Alan Stern wrote: > @@ -1584,10 +1581,8 @@ static int hid_resume(struct usb_interfa > static int hid_reset_resume(struct usb_interface *intf) > { > struct hid_device *hid = usb_get_intfdata(intf); > - struct usbhid_device *usbhid = hid->driver_data; >

[PATCH] mct_u232: sanity checking in probe

2016-03-21 Thread Oliver Neukum
An attack using the lack of sanity checking in probe is known. This patch checks for the existance of a second port. CVE-2016-3136 Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org v1 - add sanity check for presence of a second port v2 - add sanity check for an interrupt endpoint

Re: [PATCH] mct_u232: sanity checking in probe

2016-03-21 Thread Oliver Neukum
On Thu, 2016-03-17 at 10:47 -0400, Johan Hovold wrote: > This looks like you just resent v1 (again, please include the revision > in the mail Subject). Indeed. Wrong directory. Sorry Oliver -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the bo

[PATCH v2] mct_u232: sanity checking in probe

2016-03-21 Thread Oliver Neukum
An attack using the lack of sanity checking in probe is known. This patch checks for the existance of a second port. CVE-2016-3136 Signed-off-by: Oliver Neukum CC: sta...@vger.kernel.org v1 - add sanity check for presence of a second port v2 - add sanity check for an interrupt endpoint

[PATCH v2] digi_acceleport: do sanity checking for the number of ports

2016-03-21 Thread Oliver Neukum
The driver can be crashed with devices that expose crafted descriptors with too few endpoints. See: http://seclists.org/bugtraq/2016/Mar/61 Signed-off-by: Oliver Neukum v1 - added sanity checks v2 - moved them to probe() to fix problems Johan pointed out --- drivers/usb/serial

Re: [PATCH] lan78xx: Protect runtime_auto check by #ifdef CONFIG_PM

2016-03-21 Thread Oliver Neukum
On Mon, 2016-03-21 at 10:57 -0400, Alan Stern wrote: > One possible solution is to export a sysfs parameter to prevent > statistics collection (or more generally, to change the interval at > which it occurs). Surely, not performing a task can hardly be beaten in terms of power consumption. That

Re: [PATCH] lan78xx: Protect runtime_auto check by #ifdef CONFIG_PM

2016-03-21 Thread Oliver Neukum
On Mon, 2016-03-21 at 14:24 -0400, Alan Stern wrote: > On Mon, 21 Mar 2016, Oliver Neukum wrote: > > > On Mon, 2016-03-21 at 10:57 -0400, Alan Stern wrote: > > > > > One possible solution is to export a sysfs parameter to prevent > > > statistics collecti

Re: "reset full-speed USB device number 6 using ehci-pci" with Dell Inspiron 15R 5537

2016-03-21 Thread Oliver Neukum
On Mon, 2016-03-21 at 11:46 -0400, Alan Stern wrote: > On Mon, 21 Mar 2016, Oliver Neukum wrote: > > > On Fri, 2016-03-18 at 12:36 -0400, Alan Stern wrote: > > > > Almost. In case of reset_resume() it makes no sense to still > > clear a halt or execute a re

Re: 答复: 【xhci】suspend and resume core dump problem

2016-03-22 Thread Oliver Neukum
On Mon, 2016-03-21 at 23:41 -0400, gre...@linuxfoundation.org wrote: > On Tue, Mar 22, 2016 at 03:17:08AM +, Lipengcheng wrote: > > Hi, > > Thanks for your reply. > > When the suspend and resume process , the operation of press ctrl + c > > will produce an interruput and cause to allocate

Re: [PATCH] lan78xx: Protect runtime_auto check by #ifdef CONFIG_PM

2016-03-22 Thread Oliver Neukum
On Mon, 2016-03-21 at 15:30 -0400, Alan Stern wrote: > On Mon, 21 Mar 2016, Oliver Neukum wrote: > > > We have an autosuspend timeout because we think that IO, if it will > > come at all, is likeliest to come soon. If, however, the IO is > > periodic that heuristics is

[PATCH] sur40:fix DMA on stack

2016-03-22 Thread Oliver Neukum
During the initialisation that driver uses a buffer on the stack for DMA. That violates the cache coherency rules. The fix is to allocate the buffer with kmalloc(). Signed-off-by: Oliver Neukum --- drivers/input/touchscreen/sur40.c | 20 1 file changed, 12 insertions(+), 8

Re: [PATCH] lan78xx: Protect runtime_auto check by #ifdef CONFIG_PM

2016-03-22 Thread Oliver Neukum
On Tue, 2016-03-22 at 10:21 -0400, Alan Stern wrote: > I don't see any point in resuming the device just in order to collect > operating statistics. If it was already suspended then it wasn't > operating, so there will be no statistics to collect. Indeed. In that case the point is moot. But it

[PATCH 2/4] aiptek: stop saving struct usb_device

2016-03-22 Thread Oliver Neukum
The device can now easily be derived from the interface. Stop leaving a private copy. Signed-off-by: Oliver Neukum --- drivers/input/tablet/aiptek.c | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/input/tablet/aiptek.c b/drivers/input/tablet

[PATCH 3/4] gtco: stop saving struct usb_device

2016-03-22 Thread Oliver Neukum
The device can now easily be derived from the interface. Stop leaving a private copy. Signed-off-by: Oliver Neukum --- drivers/input/tablet/gtco.c | 24 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/drivers/input/tablet/gtco.c b/drivers/input/tablet

[PATCH 0/4] tablet: remove private copy to USB device

2016-03-22 Thread Oliver Neukum
We now have a macro to easily get to the USB device from the interface. So we are cleaning up all drivers to not store a private pointer. Oliver Neukum (4): acecad: stop saving struct usb_device aiptek: stop saving struct usb_device gtco: stop saving struct usb_device kbtab: stop saving

[PATCH 1/4] acecad: stop saving struct usb_device

2016-03-22 Thread Oliver Neukum
The device can now easily be derived from the interface. Stop leaving a private copy. Signed-off-by: Oliver Neukum --- drivers/input/tablet/acecad.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/input/tablet/acecad.c b/drivers/input/tablet/acecad.c

[PATCH 4/4] kbtab: stop saving struct usb_device

2016-03-22 Thread Oliver Neukum
The device can now easily be derived from the interface. Stop leaving a private copy. Signed-off-by: Oliver Neukum --- drivers/input/tablet/kbtab.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/input/tablet/kbtab.c b/drivers/input/tablet/kbtab.c index

Re: [PATCH] lan78xx: Protect runtime_auto check by #ifdef CONFIG_PM

2016-03-22 Thread Oliver Neukum
On Tue, 2016-03-22 at 11:13 -0400, Alan Stern wrote: > > Indeed. In that case the point is moot. But it is correct to ask > > the core whether the device is autosuspended at that point rather > > than keep a private flag if you can. > > That's why we have pm_runtime_status_suspended(). I guess we

[RFC] xhci: one more quirk for PANTHERPOINT

2016-03-22 Thread Oliver Neukum
A T430 is reported to also need XHCI_SLOW_SUSPEND, lest a power off turn into a reboot. Signed-off-by: Oliver Neukum --- drivers/usb/host/xhci-pci.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/usb/host/xhci-pci.c b/drivers/usb/host/xhci-pci.c index f0640b7

[RFC] PANTHERPOINT needing yet another quirk

2016-03-22 Thread Oliver Neukum
I have a report of a T430 laptop needing this unless you want shut downs turn into reboot. Is there any hope of investigating this further at Intel, or do we go for the cautious approach? Oliver Neukum (1): xhci: one more quirk for PANTHERPOINT drivers/usb/host/xhci-pci.c | 4 +++- 1 file

Re: Usb point of sale keyboard shows err 19 of hub has too many ports

2016-03-30 Thread Oliver Neukum
On Tue, 2016-03-29 at 17:58 -0700, Greg KH wrote: > On Tue, Mar 29, 2016 at 05:42:50PM +0100, reggie macdonald wrote: > > Hi I made a bug report on bugzilla and was told to forward it to this email. > > > > Please see this thread: https://bbs.archlinux.org/viewtopic.php?id=210446 > > > > for curr

need to resubmit serial fixes?

2016-03-31 Thread Oliver Neukum
Hi, do I need to resubmit the serial fixes I submitted for the issues with the forged device descriptors leading to crashes? Regards Oliver -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More

Re: [RFC] Create an audit record of USB specific details

2016-04-03 Thread Oliver Neukum
On Mon, 2016-04-04 at 00:02 -0400, wmealing wrote: > From: Wade Mealing > > Gday, > > I'm looking to create an audit trail for when devices are added or removed > from the system. > > The audit subsystem is a logging subsystem in kernel space that can be > used to create advanced filters on gen

Re: [PATCH v2 05/14] USB: ch341: fix USB buffer allocations

2016-04-04 Thread Oliver Neukum
On Sat, 2016-04-02 at 19:07 +0200, Grigori Goronzy wrote: > Use the correct types and sizes. > > Signed-off-by: Grigori Goronzy > --- > drivers/usb/serial/ch341.c | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/drivers/usb/serial/ch341.c b/drivers/usb/serial/

Re: cdc-acm: v4.6-rc1: Kernel panic in acm_start_wb

2016-04-04 Thread Oliver Neukum
On Mon, 2016-04-04 at 12:31 +0200, Torsten Hilbrich wrote: > commit a81cf9799ad7299b03a4dff020d9685f9ac5f3e0 > Author: Oliver Neukum > Date: Wed Feb 10 10:39:49 2016 +0100 > > cdc-acm: implement put_char() and flush_chars() Hi, does this fix the issue?

[PATCH] cdc-acm: fix crash if flushed with nothing buffered

2016-04-04 Thread Oliver Neukum
Under some circumstances acm_tty_flush_chars() is called with no buffer to flush. We simply need to do nothing. Signed-off-by: Oliver Neukum Reported-by: Torsten Hilbrich --- drivers/usb/class/cdc-acm.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/usb/class/cdc-acm.c b

[PATCH] cdc-acm: fix crash if flushed with nothing buffered

2016-04-04 Thread Oliver Neukum
Under some circumstances acm_tty_flush_chars() is called with no buffer to flush. We simply need to do nothing. Signed-off-by: Oliver Neukum Reported-by: Torsten Hilbrich --- drivers/usb/class/cdc-acm.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/usb/class/cdc-acm.c b

Re: [RFC] Create an audit record of USB specific details

2016-04-05 Thread Oliver Neukum
On Tue, 2016-04-05 at 18:40 +1000, Wade Mealing wrote: > Consider the following scenario. Currently we have device drivers > that emit text via a printk request which is eventually picked up by > syslog like implementation (not the audit subsystem). We also have UEVENTs. The crucial question is w

Re: Oops in 4.6-rc2: NULL pointer dereference in cdc-acm

2016-04-07 Thread Oliver Neukum
On Wed, 2016-04-06 at 22:48 +0200, Gabriele Mazzotta wrote: > Hi, > > I'm getting a kernel oops when I plug some smartphone via USB to my > laptop, which is currently running the v4.6-rc2. > > The problem seems to be caused by a81cf9799ad7 ("cdc-acm: implement > put_char() and flush_chars()"). >

Re: [PATCH] usb: Add driver for UCSI

2016-04-12 Thread Oliver Neukum
On Tue, 2016-04-12 at 14:43 +0300, Heikki Krogerus wrote: > +static int ucsi_init(struct ucsi *ucsi) > +{ > + struct ucsi_connector *con; > + struct ucsi_control ctrl; > + int ret; > + int i; > + > + atomic_set(&ucsi->event_pending, 0); > + init_completion(&ucsi->complete);

Re: [PATCHv4 2/3] usb: storage: scsiglue: limit USB3 devices to 2048 sectors

2016-04-13 Thread Oliver Neukum
On Wed, 2016-04-13 at 08:42 +0300, Felipe Balbi wrote: > USB3 devices, because they are much newer, have much > less chance of having issues with larger transfers. > > We still keep a limit because anything above 2048 > sectors really rendered negligible speed > improvements, so we will simply ign

Re: [PATCH 1/1] usb: lpm: add boot flag to disable lpm

2016-04-14 Thread Oliver Neukum
On Wed, 2016-04-13 at 14:33 -0700, Greg KH wrote: > But larger issue, no new module parameters for things like this. No one > will use them and they aren't device or bus specific. It's a huge > hammer that isn't nice to use. But this is a valuable debug tool. Regards Ol

Re: [PATCH 1/1] usb: lpm: add boot flag to disable lpm

2016-04-14 Thread Oliver Neukum
On Wed, 2016-04-13 at 15:11 -0700, Greg KH wrote: > On Wed, Apr 13, 2016 at 02:37:35PM -0700, Matthew Giassa wrote: > > Thank you for the feedback Greg. This is my first attempt to submit a > > kernel patch. > > > > Is there a better approach to this? The only other option at my disposal > > is to

Re: [PATCH 1/1] usb: lpm: add boot flag to disable lpm

2016-04-14 Thread Oliver Neukum
On Thu, 2016-04-14 at 10:53 +0200, Bjørn Mork wrote: > Even more valuable when you make it device or bus specific. I don't see > Greg arguing against a knob to turn off LPM. Only the slegde hammer > operated master switch implementation :) We do have nousb and autosuspend=-1 And it is easy to e

Re: [PATCH 1/1] usb: lpm: add boot flag to disable lpm

2016-04-14 Thread Oliver Neukum
On Thu, 2016-04-14 at 10:38 -0400, Alan Stern wrote: > > So we have quirk for it. The ability to trigger this quirk the hard > way > > would be useful for debugging. Thus I believe that this patch is a > good > > idea. > > If this is for debugging then maybe it belongs in debugfs. Doing it > tha

Re: [PATCH v2] watchdog: add driver for StreamLabs USB watchdog device

2016-04-18 Thread Oliver Neukum
On Mon, 2016-04-18 at 03:53 +0100, Alexey Klimov wrote: > This patch creates new driver that supports StreamLabs usb watchdog > device. This device plugs into 9-pin usb header and connects to > reset pin and reset button on common PC. > > USB commands used to communicate with device were reverse >

Re: [PATCH v2] watchdog: add driver for StreamLabs USB watchdog device

2016-04-18 Thread Oliver Neukum
On Mon, 2016-04-18 at 06:57 -0700, Guenter Roeck wrote: > On 04/18/2016 01:32 AM, Oliver Neukum wrote: > > On Mon, 2016-04-18 at 03:53 +0100, Alexey Klimov wrote: > >> This patch creates new driver that supports StreamLabs usb watchdog > >> device. This device plug

Re: [PATCH v2] watchdog: add driver for StreamLabs USB watchdog device

2016-04-19 Thread Oliver Neukum
On Mon, 2016-04-18 at 09:39 -0700, Guenter Roeck wrote: > > Possibly. We have never gone that route. The obvious problems is > that > > I am not sure our alignment is known before boot. > > > Seems scary. I always thought that the alignment associated with > cacheline_aligned would be the maxi

Re: What are Shared HCD and Companion Controller(HCD?)

2016-04-19 Thread Oliver Neukum
On Tue, 2016-04-19 at 17:44 +0800, Peter Chen wrote: > Hi all, > > When I review the patch [1] for adding companion controller support for > OTG framework, I am puzzled several concepts, like shared hcd and > companion controller, companion hcd, companion port, would someone > please explain them?

[RFC 2/4] cdc-acm: use the common parser

2016-04-19 Thread Oliver Neukum
This introduces the common parser for extra CDC headers now that it no longer depends on usbnet. Signed-off-by: Oliver Neukum --- drivers/usb/class/cdc-acm.c | 60 +++-- 1 file changed, 3 insertions(+), 57 deletions(-) diff --git a/drivers/usb/class/cdc

[RFC 3/4] cdc-acm: cleanup error handling

2016-04-19 Thread Oliver Neukum
A small update to unify error handling during probe(). Signed-off-by: Oliver Neukum --- drivers/usb/class/cdc-acm.c | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c index 6d82257..8268860 100644 --- a/drivers

[RFC 1/4] usbnet: move the CDC parser into USB core

2016-04-19 Thread Oliver Neukum
The dependencies were impossible to handle preventing drivers for CDC devices not which are not network drivers from using the common parser. Signed-off-by: Oliver Neukum --- drivers/net/usb/usbnet.c | 138 drivers/usb/core/message.c | 153

[RFC 4/4] cdc-wdm: use the common CDC parser

2016-04-19 Thread Oliver Neukum
Now that the common parser resides in USB core, it can be used for CDC-WDM. Signed-off-by: Oliver Neukum --- drivers/usb/class/cdc-wdm.c | 29 + 1 file changed, 5 insertions(+), 24 deletions(-) diff --git a/drivers/usb/class/cdc-wdm.c b/drivers/usb/class/cdc-wdm.c

[RFC] moving CDC parser into USB core

2016-04-19 Thread Oliver Neukum
Hi, after trying to use the common parser drivers which don't depend on usbnet I ended up in dependency hell. Having this code live in usbnet just doesn't make sense. I toyed with the idea of turning it into a module of its own, but that collides with the purpose of saving space. -- To unsubscrib

resending patches for chaoskey

2016-04-19 Thread Oliver Neukum
Hi, I got more patches to improve throughput but I cannot test them. Regards From b32c2f840c1ff0d0e93b627eb07b2fdc11f37bb5 Mon Sep 17 00:00:00 2001 From: Oliver Neukum Date: Thu, 25 Feb 2016 12:20:12 +0100 Subject: [PATCH 1/4] chaoskey: O_NONBLOCK in concurrent reads This changes the

[PATCH 1/2] USB: LTM also for USB 3.1

2016-04-20 Thread Oliver Neukum
LTM is also defined for SS+. The correct test is to check for anything slower than SS not exactly SS. Signed-off-by: Oliver Neukum --- include/linux/usb.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/usb.h b/include/linux/usb.h index 6a9a0c2..29aba760 100644

[PATCH 2/2] USB: correct intervals for SS+

2016-04-20 Thread Oliver Neukum
SS+ also expresses intervals in units of 125ms. Testing must be for SS or faster, not SS exactly. Signed-off-by: Oliver neukum --- include/linux/usb.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/linux/usb.h b/include/linux/usb.h index 29aba760..7824f45 100644

[PATCH 0/2] Correcting a few remaining test for USB_SPEED_SUPER

2016-04-20 Thread Oliver Neukum
It looks to me like the tests for LTM and the units of intervals for periodic transfers used ==USB_SPEED_SUPER where >=USB_SPEED_SUPER should have been used. Oliver Neukum (2): USB: LTM also for USB 3.1 USB: correct intervals for SS+ include/linux/usb.h | 6 +++--- 1 file changed

[PATCH] hub: admit devices are SS+

2016-04-20 Thread Oliver Neukum
If a port can do 10 Gb/s the kernel should say so. The corresponding check needs to be added. Signed-off.by: Oliver Neukum > --- drivers/usb/core/hub.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c index 38cc4ba..c2270d8 100644 --

[PATCH] sisusbvga: correct speed testing

2016-05-02 Thread Oliver Neukum
Allow for SS+ Signed-off-by: Oliver Neukum --- drivers/usb/misc/sisusbvga/sisusb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/misc/sisusbvga/sisusb.c b/drivers/usb/misc/sisusbvga/sisusb.c index a22de52..15666ad 100644 --- a/drivers/usb/misc/sisusbvga

[PATCH] sisusbvga: correct speed testing

2016-05-02 Thread Oliver Neukum
Allow for SS+ Signed-off-by: Oliver Neukum --- drivers/usb/misc/sisusbvga/sisusb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/misc/sisusbvga/sisusb.c b/drivers/usb/misc/sisusbvga/sisusb.c index a22de52..15666ad 100644 --- a/drivers/usb/misc/sisusbvga

[PATCH 2/3] usbnet: correct speed testing

2016-05-02 Thread Oliver Neukum
Allow for SS+ USB Signed-off-by: Oliver Neukum --- drivers/net/usb/usbnet.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/usb/usbnet.c b/drivers/net/usb/usbnet.c index 4f08426..bc46ef9 100644 --- a/drivers/net/usb/usbnet.c +++ b/drivers/net/usb/usbnet.c @@ -355,6 +355,7

[PATCH 3/3] rtl8152: correct speed testing

2016-05-02 Thread Oliver Neukum
Allow for SS+ USB Signed-off-by: Oliver Neukum --- drivers/net/usb/r8152.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c index d1f78c2..3f9f6ed 100644 --- a/drivers/net/usb/r8152.c +++ b/drivers/net/usb/r8152.c @@ -3366,7

[PATCH 1/3] brcm80211: correct speed testing

2016-05-02 Thread Oliver Neukum
Allow for SS+ USB Signed-off-by: Oliver Neukum --- drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c index

[PATCH] sisusbvga: correct speed testing

2016-05-02 Thread Oliver Neukum
Allow for SS+ Signed-off-by: Oliver Neukum --- drivers/usb/misc/sisusbvga/sisusb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/misc/sisusbvga/sisusb.c b/drivers/usb/misc/sisusbvga/sisusb.c index a22de52..15666ad 100644 --- a/drivers/usb/misc/sisusbvga

[PATCH] sisusbvga: correct speed testing

2016-05-02 Thread Oliver Neukum
Allow for SS+ Signed-off-by: Oliver Neukum --- drivers/usb/misc/sisusbvga/sisusb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/misc/sisusbvga/sisusb.c b/drivers/usb/misc/sisusbvga/sisusb.c index a22de52..15666ad 100644 --- a/drivers/usb/misc/sisusbvga

Re: USB SUBSYSTEM - drivers/usb/core/config.c

2017-02-07 Thread Oliver Neukum
Am Dienstag, den 07.02.2017, 19:01 +0100 schrieb John Skelton: > I'm open to any suggestions.  As I see it the above code is probably > wrong > in trying to use a low speed Bulk endpoint.  The low performance of > cheap > Arduinos and digistump etc (with no hardware USB) is not going to > allow > a

Re: [usb-storage] usb: storage: suspicious code

2017-02-14 Thread Oliver Neukum
Am Dienstag, den 14.02.2017, 23:06 -0600 schrieb Gustavo A. R. Silva: Hi, > waitcount = 0; > do { > result = jumpshot_get_status(us); > if (result != USB_STOR_TRANSPORT_GOOD) { > // I have not experimented to find the smallest > value. > // >   

Re: [PATCH] usb: class: remove logically dead code

2017-02-15 Thread Oliver Neukum
ustavo A. R. Silva > Acked-by: Oliver Neukum -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: Periodic reconnects of USB mouse on Dell PowerEdge R730

2017-02-15 Thread Oliver Neukum
Am Mittwoch, den 08.02.2017, 17:54 +0100 schrieb Johan Hovold: > > Also, I am unable to reproduce this problem with the *same* mice on > a  > > laptop with a USB3 – it’s blue – port. > > Ok, then the quirk is probably not the right solution (even if it > could > possibly help with the disconnects)

Re: [PATCH] drivers: usb-misc: sisusbvga: remove dead code

2017-02-16 Thread Oliver Neukum
Am Dienstag, den 07.02.2017, 22:01 -0600 schrieb Gustavo A. R. Silva: > The condition modex % 16 cannot be true when modex value is equal to > 640 > The condition du & 0xff cannot be true when du value is equal to > 0x1400 >  Sorry for speaking up so late, but this is not a good idea. We lose the

Re: usb 2-1.5:1.0: rebind failed: -517

2017-02-16 Thread Oliver Neukum
Am Sonntag, den 12.02.2017, 22:57 -0300 schrieb Cristian Aravena: > Hello, > > My report: > https://bugzilla.kernel.org/show_bug.cgi?id=194571 > > "dmesg: > [ 5519.078456] usb 2-1.5:1.0: rebind failed: -517 > [ 5519.078461] usb 2-1.5:1.1: rebind failed: -517 Which kernel version? Which device? W

Re: VL805 USB 3.0 does not see connected devices (only on x86_64) (x86 is ok)

2017-02-20 Thread Oliver Neukum
Am Sonntag, den 19.02.2017, 06:48 +0300 schrieb c400: > [  805.771818] sd 7:0:0:0: [sdd] Attached SCSI removable disk > [  805.811101] DMAR: DRHD: handling fault status reg 2 > [  805.811108] DMAR: [DMA Read] Request device [07:00.0] fault addr > fff98000 [fault reason 06] PTE Read access is not se

[PATCH] lvs: fix race condition in disconnect handling

2017-02-20 Thread Oliver Neukum
There is a small window during which the an URB may remain active after disconnect has returned. If in that case already freed memory may be accessed and executed. The fix is to poison the URB befotre the work is flushed. Signed-off-by: Oliver Neukum --- drivers/usb/misc/lvstest.c | 2 ++ 1

Re: [Kernel] usbhid 3-2:1.1: couldn't find an input interrupt endpoint

2017-02-20 Thread Oliver Neukum
Am Montag, den 20.02.2017, 15:28 -0300 schrieb Cristian: > Hello, > > dmesg: > [2.465370] usbhid 3-2:1.1: couldn't find an input interrupt > endpoint Most likely it does not have an interrupt endpoint. You will need to provide "lsusb -v" not lspci, as this bug is about a USB device. Is this a

Re: [PATCH] lvs: fix race condition in disconnect handling

2017-02-21 Thread Oliver Neukum
Am Montag, den 20.02.2017, 19:51 +0300 schrieb Sergei Shtylyov: > On 02/20/2017 05:38 PM, Oliver Neukum wrote: > > > > > There is a small window during which the an URB may > > So the or an? That is a question of view point which I cannot give an objective answer

Re: Choppy USB audio on i.MX53 chipidea with 4.4 kernel. Ok in 4.10

2017-02-22 Thread Oliver Neukum
Am Dienstag, den 21.02.2017, 17:06 +0100 schrieb Martin Fuzzey: >  > However the revert commit message doesn't really indicate that it is > a  > bug fix. > The links in the revert commit are describing scenarios involving  > multiple codecs, whereas I am only using one. Hi, if it fixes a bug, it

Re: [PATCH 00/21] USB: serial: refactor endpoint sanity checks

2017-03-03 Thread Oliver Neukum
Am Donnerstag, den 02.03.2017, 12:51 +0100 schrieb Johan Hovold: > This series refactors the endpoint sanity checks by allowing > subdrivers > to specify a minimum number of endpoints required per type and > letting > core verify this during probe. Hi, this is very good, but is it at the right pl

Re: Question: Does usbip support USB 3.0?

2017-03-06 Thread Oliver Neukum
Am Montag, den 06.03.2017, 09:02 +0800 schrieb Yuyang Du: > Hi Greg, > > On Thu, Feb 23, 2017 at 08:51:03AM +0100, Greg KH wrote: > > > > And again, what specifically are you referring to, and again, have > > you > > tried the code out yourself?  What is preventing you from testing > > this > > i

Re: [PATCH v17 2/3] usb: USB Type-C connector class

2017-03-06 Thread Oliver Neukum
Am Freitag, den 03.03.2017, 20:27 +0100 schrieb Mats Karrman: > On 2017-03-03 13:59, Heikki Krogerus wrote: > > > > > On Fri, Mar 03, 2017 at 08:29:18AM +0100, Mats Karrman wrote: > > > > > > > How would something like that sound to you guys? > > Complicated... Need to marinate on that fo

Re: [PATCH 00/21] USB: serial: refactor endpoint sanity checks

2017-03-06 Thread Oliver Neukum
Am Montag, den 06.03.2017, 10:23 +0100 schrieb Johan Hovold: > [ +CC: Greg ] > > On Fri, Mar 03, 2017 at 07:29:02PM +0100, Oliver Neukum wrote: > > > > Am Donnerstag, den 02.03.2017, 12:51 +0100 schrieb Johan Hovold: > > > > > > This series refactors

<    1   2   3   4   5   6   7   8   9   10   >