[PATCH v3 05/12] usb: xhci: dbc: add debug buffer

2015-11-08 Thread Lu Baolu
DBC_DEBUG is defined. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 62 ++-- 1 file changed, 60 insertions(+), 2 deletions(-) diff --git a/drivers/usb/early/xhci-dbc.c b/drivers/usb/early/xhci-dbc.c index 6b23f09..b36a527 100644 --- a/drivers

[PATCH v3 01/12] usb: xhci: add sysfs file for xHCI debug port

2015-11-08 Thread Lu Baolu
file will show users the state (disabled, enabled or configured) of the debug port. With a host that does NOT support debug port, "debug_port_state" file won't be created. Signed-off-by: Lu Baolu --- .../ABI/testing/sysfs-bus-pci-drivers-xhci_hcd | 23 +

Re: Overly conservative xHCI bandwidth estimation

2015-11-09 Thread Lu, Baolu
On 11/09/2015 05:27 PM, Steinar H. Gunderson wrote: On Mon, Nov 09, 2015 at 01:02:50PM +0800, Lu, Baolu wrote: We've got below facts: 1. One card works well w/ or w/o LPM enabled. No, this isn't right. One card works well without LPM; it does work with LPM but not well. Ther

Re: [PATCH v3 00/12] usb: early: add support for early printk through USB3 debug port

2015-11-10 Thread Lu, Baolu
On 11/10/2015 05:39 PM, Dave Young wrote: Hi, On 11/09/15 at 03:38pm, Lu Baolu wrote: This patch series adds support for early printk through USB3 debug port. USB3 debug port is described in xHCI specification as an optional extended capability. I did a test with your previous patchset

Re: [PATCH v3 01/12] usb: xhci: add sysfs file for xHCI debug port

2015-11-10 Thread Lu, Baolu
+ * + * Copyright (C) 2015 Intel Corp. + * + * Author: Lu Baolu + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ +#include + +#include "x

Re: [PATCH v3 00/12] usb: early: add support for early printk through USB3 debug port

2015-11-10 Thread Lu, Baolu
On 11/11/2015 10:25 AM, Dave Young wrote: Hi, On 11/11/15 at 09:32am, Lu, Baolu wrote: On 11/10/2015 05:39 PM, Dave Young wrote: Hi, On 11/09/15 at 03:38pm, Lu Baolu wrote: This patch series adds support for early printk through USB3 debug port. USB3 debug port is described in xHCI

Re: [PATCH v3 00/12] usb: early: add support for early printk through USB3 debug port

2015-11-10 Thread Lu, Baolu
On 11/11/2015 10:25 AM, Dave Young wrote: [ 1616.823351] usb 2-2: new SuperSpeed USB device number 8 using xhci_hcd [ 1616.834520] usb 2-2: LPM exit latency is zeroed, disabling LPM. [ 1616.834856] usb 2-2: New USB device found, idVendor=1d6b, idProduct=0004 [ 1616.834858] usb 2-2: New USB devi

[PATCH 3/3] usb: core: lpm: remove usb3_lpm_enabled in usb_device

2015-11-11 Thread Lu Baolu
Commit 8306095fd2c1 ("USB: Disable USB 3.0 LPM in critical sections.") adds usb3_lpm_enabled member to struct usb_device. There is no reference to this member now. Hence, it could be removed. Signed-off-by: Lu Baolu --- include/linux/usb.h | 1 - 1 file changed, 1 deletion(-) di

[PATCH 0/3] usb: core: lpm: add sysfs node for usb3 lpm permit

2015-11-11 Thread Lu Baolu
-unfriendly USB devices on any released Linux kernels. This patch series contains a fix and a cleanup as well. Thanks, Baolu Lu Baolu (3): usb: core: lpm: fix usb3_hardware_lpm sysfs node usb: core: lpm: add sysfs node for usb3 lpm permit usb: core: lpm: remove usb3_lpm_enabled in

[PATCH 1/3] usb: core: lpm: fix usb3_hardware_lpm sysfs node

2015-11-11 Thread Lu Baolu
u1 (for U1) and usb3_hardware_lpm_u2 (for U2), and recording the U1/U2 LPM status in right places. This patch should be back-ported to kernels as old as 4.3, that contains Commit 655fe4effe0f ("usbcore: add sysfs support to xHCI usb3 hardware LPM"). Cc: sta...@vger.kernel.org Signed-off-by: Lu

[PATCH 2/3] usb: core: lpm: add sysfs node for usb3 lpm permit

2015-11-11 Thread Lu Baolu
or u2 permitted, "u1" - only u1 is permitted, "u2" - only u2 is permitted, "u1_u2" - both u1 and u2 are permitted. With this interface, users can use an LPM-unfriendly USB device on a released Linux kernel. Signed-off-by: Lu Baolu Signed-off-by: Zhuang Jin Can ---

Re: [PATCH 3/3] usb: core: lpm: remove usb3_lpm_enabled in usb_device

2015-11-11 Thread Lu, Baolu
On 11/11/2015 11:10 PM, Alan Stern wrote: On Wed, 11 Nov 2015, Lu Baolu wrote: Commit 8306095fd2c1 ("USB: Disable USB 3.0 LPM in critical sections.") adds usb3_lpm_enabled member to struct usb_device. There is no reference to this member now. Hence, it could be removed. Signed-

[PATCH v2 3/3] usb: core: lpm: remove usb3_lpm_enabled in usb_device

2015-11-11 Thread Lu Baolu
Commit 8306095fd2c1 ("USB: Disable USB 3.0 LPM in critical sections.") adds usb3_lpm_enabled member to struct usb_device. There is no reference to this member now. Hence, it could be removed. Signed-off-by: Lu Baolu --- include/linux/usb.h | 2 -- 1 file changed, 2 deletions(-) di

[PATCH v2 1/3] usb: core: lpm: fix usb3_hardware_lpm sysfs node

2015-11-11 Thread Lu Baolu
u1 (for U1) and usb3_hardware_lpm_u2 (for U2), and recording the U1/U2 LPM status in right places. This patch should be back-ported to kernels as old as 4.3, that contains Commit 655fe4effe0f ("usbcore: add sysfs support to xHCI usb3 hardware LPM"). Cc: sta...@vger.kernel.org Signed-off-by: Lu

[PATCH v2 0/3] usb: core: lpm: add sysfs node for usb3 lpm permit

2015-11-11 Thread Lu Baolu
-unfriendly USB devices on any released Linux kernels. This patch series contains a fix and a cleanup as well. Change log: v1->v2: Fix the "make htmldoc" warning reported by 0-day robot. Thanks, Baolu Lu Baolu (3): usb: core: lpm: fix usb3_hardware_lpm sysfs node usb: core: l

[PATCH v2 2/3] usb: core: lpm: add sysfs node for usb3 lpm permit

2015-11-11 Thread Lu Baolu
or u2 permitted, "u1" - only u1 is permitted, "u2" - only u2 is permitted, "u1_u2" - both u1 and u2 are permitted. With this interface, users can use an LPM-unfriendly USB device on a released Linux kernel. Signed-off-by: Lu Baolu Signed-off-by: Zhuang Jin Can ---

Re: [PATCH v3 00/12] usb: early: add support for early printk through USB3 debug port

2015-11-11 Thread Lu, Baolu
On 11/11/2015 10:25 AM, Dave Young wrote: Hi, On 11/11/15 at 09:32am, Lu, Baolu wrote: On 11/10/2015 05:39 PM, Dave Young wrote: Hi, On 11/09/15 at 03:38pm, Lu Baolu wrote: This patch series adds support for early printk through USB3 debug port. USB3 debug port is described in xHCI specifica

Re: [PATCH v2 3/3] usb: core: lpm: remove usb3_lpm_enabled in usb_device

2015-11-12 Thread Lu, Baolu
On 11/13/2015 12:20 AM, Alan Stern wrote: On Thu, 12 Nov 2015, Lu Baolu wrote: Commit 8306095fd2c1 ("USB: Disable USB 3.0 LPM in critical sections.") adds usb3_lpm_enabled member to struct usb_device. There is no reference to this member now. Hence, it could be removed. Signed-

Re: [PATCH v3 00/12] usb: early: add support for early printk through USB3 debug port

2015-11-12 Thread Lu, Baolu
Hi Dave, On 11/12/2015 02:01 PM, Dave Young wrote: Hi, Baolu On 11/12/15 at 10:45am, Lu, Baolu wrote: >Hi Dave, > >Which device are you testing with? This implementation was developed >and tested on Intel Skylake devices. > >It doesn't surprise me if it doesn't w

Re: [PATCH v2 1/3] usb: core: lpm: fix usb3_hardware_lpm sysfs node

2015-11-12 Thread Lu, Baolu
On 11/13/2015 12:20 AM, Alan Stern wrote: On Thu, 12 Nov 2015, Lu Baolu wrote: Commit 655fe4effe0f ("usbcore: add sysfs support to xHCI usb3 hardware LPM") introduced usb3_hardware_lpm sysfs node. This doesn't show the correct status of USB3 U1 and U2 LPM status. This patc

Re: [PATCH v3 00/12] usb: early: add support for early printk through USB3 debug port

2015-11-12 Thread Lu Baolu
On 11/13/2015 10:26 AM, Dave Young wrote: On 11/13/15 at 10:04am, Lu, Baolu wrote: Hi Dave, On 11/12/2015 02:01 PM, Dave Young wrote: Hi, Baolu On 11/12/15 at 10:45am, Lu, Baolu wrote: Hi Dave, Which device are you testing with? This implementation was developed and tested on Intel

Re: [PATCH v2 1/3] usb: core: lpm: fix usb3_hardware_lpm sysfs node

2015-11-13 Thread Lu Baolu
On 11/13/2015 11:28 PM, Alan Stern wrote: On Fri, 13 Nov 2015, Lu, Baolu wrote: On 11/13/2015 12:20 AM, Alan Stern wrote: On Thu, 12 Nov 2015, Lu Baolu wrote: Commit 655fe4effe0f ("usbcore: add sysfs support to xHCI usb3 hardware LPM") introduced usb3_hardware_lpm sysfs node. Th

[PATCH v3 0/3] usb: core: lpm: add sysfs node for usb3 lpm permit

2015-11-14 Thread Lu Baolu
-day robot. Thanks, Baolu Lu Baolu (3): usb: core: lpm: fix usb3_hardware_lpm sysfs node usb: core: lpm: add sysfs node for usb3 lpm permit usb: core: lpm: remove usb3_lpm_enabled in usb_device Documentation/ABI/testing/sysfs-bus-usb | 27 +++--- Documentation/usb/power-management.t

[PATCH v3 2/3] usb: core: lpm: add sysfs node for usb3 lpm permit

2015-11-14 Thread Lu Baolu
or u2 permitted, "u1" - only u1 is permitted, "u2" - only u2 is permitted, "u1_u2" - both u1 and u2 are permitted. With this interface, users can use an LPM-unfriendly USB device on a released Linux kernel. Signed-off-by: Lu Baolu Signed-off-by: Zhuang Jin Can ---

[PATCH v3 3/3] usb: core: lpm: remove usb3_lpm_enabled in usb_device

2015-11-14 Thread Lu Baolu
Commit 8306095fd2c1 ("USB: Disable USB 3.0 LPM in critical sections.") adds usb3_lpm_enabled member to struct usb_device. There is no reference to this member now. Hence, it could be removed. Signed-off-by: Lu Baolu --- include/linux/usb.h | 2 -- 1 file changed, 2 deletions(-) di

[PATCH v3 1/3] usb: core: lpm: fix usb3_hardware_lpm sysfs node

2015-11-14 Thread Lu Baolu
u1 (for U1) and usb3_hardware_lpm_u2 (for U2), and recording the U1/U2 LPM status in right places. This patch should be back-ported to kernels as old as 4.3, that contains Commit 655fe4effe0f ("usbcore: add sysfs support to xHCI usb3 hardware LPM"). Cc: sta...@vger.kernel.org Signed-off-by: Lu

Re: [PATCH v3 04/12] usb: xhci: dbc: add support for Intel xHCI dbc quirk

2015-11-15 Thread Lu Baolu
Hi, On 11/13/2015 11:34 PM, Dmitry Malkin wrote: On Mon, 9 Nov 2015 15:38:33 +0800, Lu Baolu wrote: On Intel platform, if the debug target is connected with debug host, enabling DCE bit in command register leads to a hung bus state. In the hung state, the host system will not see a port

[PATCH v4 11/12] usb: serial: usb_debug: add support for dbc debug device

2015-11-16 Thread Lu Baolu
This patch add dbc debug device support in usb_debug driver. Signed-off-by: Lu Baolu Acked-by: Johan Hovold --- drivers/usb/serial/usb_debug.c | 28 +--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/drivers/usb/serial/usb_debug.c b/drivers/usb/serial

[PATCH v4 12/12] usb: doc: add document for xHCI DbC driver

2015-11-16 Thread Lu Baolu
Add Documentation/usb/xhci-dbc.txt. This document includes development status and user guide for USB3 debug port. Signed-off-by: Lu Baolu --- Documentation/usb/xhci-dbc.txt | 325 + MAINTAINERS| 1 + drivers/usb/early/xhci-dbc.c

[PATCH v4 10/12] usb: xhci: dbc: add handshake between debug target and host

2015-11-16 Thread Lu Baolu
'y' in the tty application. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 27 +++ 1 file changed, 27 insertions(+) diff --git a/drivers/usb/early/xhci-dbc.c b/drivers/usb/early/xhci-dbc.c index 68a7139..b75c523 100644 --- a/drivers/usb/early/xhci-dbc

[PATCH v4 09/12] x86: early_printk: add USB3 debug port earlyprintk support

2015-11-16 Thread Lu Baolu
Add support for early printk by writing debug messages to the USB3 debug port. Users can use this type of early printk by specifying kernel parameter of "earlyprintk=xdbc". This gives users a chance of providing debug output. Signed-off-by: Lu Baolu --- Documentation/kernel-parameter

[PATCH v4 07/12] usb: xhci: dbc: handle dbc-configured exit

2015-11-16 Thread Lu Baolu
DbC might exit configured state in some cases (refer to 7.6.4.4 in xHCI spec 1.1). Software needs detect and clear this situation by clearing DCCTRL.DCR and wait until the DbC configured before read or write oprations. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 28

[PATCH v4 08/12] usb: xhci: dbc: handle endpoint stall

2015-11-16 Thread Lu Baolu
. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 36 1 file changed, 36 insertions(+) diff --git a/drivers/usb/early/xhci-dbc.c b/drivers/usb/early/xhci-dbc.c index 8a5a51f..aaf655f 100644 --- a/drivers/usb/early/xhci-dbc.c +++ b/drivers/usb/early

[PATCH v4 05/12] usb: xhci: dbc: add debug buffer

2015-11-16 Thread Lu Baolu
DBC_DEBUG is defined. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 62 ++-- 1 file changed, 60 insertions(+), 2 deletions(-) diff --git a/drivers/usb/early/xhci-dbc.c b/drivers/usb/early/xhci-dbc.c index 6b23f09..b36a527 100644 --- a/drivers

[PATCH v4 06/12] usb: xhci: dbc: add bulk out and bulk in interfaces

2015-11-16 Thread Lu Baolu
This patch adds interfaces for bulk out and bulk in ops. These interfaces could be used to implement early printk bootconsole or hook to various system debuggers. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 373 +++ include/linux/usb/xhci

[PATCH v4 01/12] usb: xhci: add sysfs file for xHCI debug port

2015-11-16 Thread Lu Baolu
file will show users the state (disabled, enabled or configured) of the debug port. With a host that does NOT support debug port, "debug_port_state" file won't be created. Signed-off-by: Lu Baolu --- .../ABI/testing/sysfs-bus-pci-drivers-xhci_hcd | 23 +++

[PATCH v4 03/12] usb: xhci: dbc: probe and setup xhci debug capability

2015-11-16 Thread Lu Baolu
between the debug host and target. Signed-off-by: Lu Baolu --- MAINTAINERS | 7 + arch/x86/Kconfig.debug | 12 + drivers/usb/early/Makefile | 1 + drivers/usb/early/xhci-dbc.c | 787 +++ include/linux/usb/xhci-dbc.h | 187

[PATCH v4 02/12] x86: fixmap: add permanent fixmap for xhci debug port

2015-11-16 Thread Lu Baolu
fixed_addresses table for xHCI mmio access. Signed-off-by: Lu Baolu --- arch/x86/include/asm/fixmap.h | 4 1 file changed, 4 insertions(+) diff --git a/arch/x86/include/asm/fixmap.h b/arch/x86/include/asm/fixmap.h index f80d700..fbf452f 100644 --- a/arch/x86/include/asm/fixmap.h +++ b/arch/x86/include

[PATCH v4 04/12] usb: xhci: dbc: add support for Intel xHCI dbc quirk

2015-11-16 Thread Lu Baolu
a port reset to the debug port from the host xHCI. This patch introduces this work around. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 52 include/linux/usb/xhci-dbc.h | 2 ++ 2 files changed, 54 insertions(+) diff --git a/drivers/usb

[PATCH v4 00/12] usb: early: add support for early printk through USB3 debug port

2015-11-16 Thread Lu Baolu
_cap_by_id() helper. (2) Patch 3 "bus hung state" changed to "port hung state" in commit message. (3) Patch 12 added verified platform information. Lu Baolu (12): usb: xhci: add sysfs file for xHCI debug port x86: fixmap: add permanent fixmap for xhci debug port usb

Re: [PATCH v3 04/12] usb: xhci: dbc: add support for Intel xHCI dbc quirk

2015-11-18 Thread Lu Baolu
Hi, On 11/17/2015 06:28 PM, Dmitry Malkin wrote: On Mon, 16 Nov 2015 10:18:42 +0800, Lu Baolu wrote: This quirk works as well if debug host doesn't have DBC. I didn't try a DBC-capable debug host yet. Hi, I went through it again, with your v3 patch series on top of vanilla v4

Re: [PATCH v4 01/12] usb: xhci: add sysfs file for xHCI debug port

2015-11-21 Thread Lu Baolu
On 11/20/2015 10:33 PM, Mathias Nyman wrote: On 17.11.2015 08:38, Lu Baolu wrote: This patch adds a sysfs file for users to check 1) whether the debug capability is implemented by hardware; 2) if supported, which state does it stay at. With a host that supports debug port, a file named

[PATCH v5 12/12] usb: doc: add document for xHCI DbC driver

2015-12-01 Thread Lu Baolu
Add Documentation/usb/xhci-dbc.txt. This document includes development status and user guide for USB3 debug port. Signed-off-by: Lu Baolu --- Documentation/usb/xhci-dbc.txt | 350 + MAINTAINERS| 1 + drivers/usb/early/xhci-dbc.c

[PATCH v5 11/12] usb: serial: usb_debug: add support for dbc debug device

2015-12-01 Thread Lu Baolu
This patch add dbc debug device support in usb_debug driver. Signed-off-by: Lu Baolu Acked-by: Johan Hovold --- drivers/usb/serial/usb_debug.c | 28 +--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/drivers/usb/serial/usb_debug.c b/drivers/usb/serial

[PATCH v5 10/12] usb: xhci: dbc: add handshake between debug target and host

2015-12-01 Thread Lu Baolu
'y' in the tty application. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 27 +++ 1 file changed, 27 insertions(+) diff --git a/drivers/usb/early/xhci-dbc.c b/drivers/usb/early/xhci-dbc.c index 6c24ba0..37c5c87 100644 --- a/drivers/usb/early/xhci-dbc

[PATCH v5 09/12] x86: early_printk: add USB3 debug port earlyprintk support

2015-12-01 Thread Lu Baolu
Add support for early printk by writing debug messages to the USB3 debug port. Users can use this type of early printk by specifying kernel parameter of "earlyprintk=xdbc". This gives users a chance of providing debug output. Signed-off-by: Lu Baolu --- Documentation/kernel-parameter

[PATCH v5 08/12] usb: xhci: dbc: handle endpoint stall

2015-12-01 Thread Lu Baolu
. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 36 1 file changed, 36 insertions(+) diff --git a/drivers/usb/early/xhci-dbc.c b/drivers/usb/early/xhci-dbc.c index c81df40..344d93e 100644 --- a/drivers/usb/early/xhci-dbc.c +++ b/drivers/usb/early

[PATCH v5 07/12] usb: xhci: dbc: handle dbc-configured exit

2015-12-01 Thread Lu Baolu
DbC might exit configured state in some cases (refer to 7.6.4.4 in xHCI spec 1.1). Software needs detect and clear this situation by clearing DCCTRL.DCR and wait until the DbC configured before read or write oprations. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 28

[PATCH v5 06/12] usb: xhci: dbc: add bulk out and bulk in interfaces

2015-12-01 Thread Lu Baolu
This patch adds interfaces for bulk out and bulk in ops. These interfaces could be used to implement early printk bootconsole or hook to various system debuggers. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 373 +++ include/linux/usb/xhci

[PATCH v5 05/12] usb: xhci: dbc: add debug buffer

2015-12-01 Thread Lu Baolu
DBC_DEBUG is defined. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 62 ++-- 1 file changed, 60 insertions(+), 2 deletions(-) diff --git a/drivers/usb/early/xhci-dbc.c b/drivers/usb/early/xhci-dbc.c index 41ce116..6855048 100644 --- a/drivers

[PATCH v5 02/12] x86: fixmap: add permanent fixmap for xhci debug port

2015-12-01 Thread Lu Baolu
fixed_addresses table for xHCI mmio access. Signed-off-by: Lu Baolu --- arch/x86/include/asm/fixmap.h | 4 1 file changed, 4 insertions(+) diff --git a/arch/x86/include/asm/fixmap.h b/arch/x86/include/asm/fixmap.h index f80d700..fbf452f 100644 --- a/arch/x86/include/asm/fixmap.h +++ b/arch/x86/include

[PATCH v5 04/12] usb: xhci: dbc: add support for Intel xHCI dbc quirk

2015-12-01 Thread Lu Baolu
a port reset to the debug port from the host xHCI. This patch introduces this work around. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 52 include/linux/usb/xhci-dbc.h | 2 ++ 2 files changed, 54 insertions(+) diff --git a/drivers/usb

[PATCH v5 00/12] usb: early: add support for early printk through USB3 debug port

2015-12-01 Thread Lu Baolu
de information. (3) All patches rebased to the new usb-next branch which contains commit d5ddcdf(xhci: rework xhci extended capability list parsing functions). Lu Baolu (12): usb: xhci: add sysfs file for xHCI debug port x86: fixmap: add permanent fixmap for xhci debug port usb: xhci: db

[PATCH v5 03/12] usb: xhci: dbc: probe and setup xhci debug capability

2015-12-01 Thread Lu Baolu
between the debug host and target. Signed-off-by: Lu Baolu --- MAINTAINERS | 7 + arch/x86/Kconfig.debug | 12 + drivers/usb/early/Makefile | 1 + drivers/usb/early/xhci-dbc.c | 774 +++ include/linux/usb/xhci-dbc.h | 187

[PATCH v5 01/12] usb: xhci: add sysfs file for xHCI debug port

2015-12-01 Thread Lu Baolu
file will show users the state (disabled, enabled or configured) of the debug port. With a host that does NOT support debug port, "debug_port_state" file won't be created. Signed-off-by: Lu Baolu --- .../ABI/testing/sysfs-bus-pci-drivers-xhci_hcd | 23

Re: [PATCH 2/2] usb: pci-quirks: register USB mux found on Cherrytrail SOC

2015-12-01 Thread Lu Baolu
> configure it. Normally BIOS takes care of it. > > The driver for the mux is an "extcon" driver. With this we > only register the mux if it's detected. > > Suggested-by: Lu Baolu > Signed-off-by: Heikki Krogerus > --- > drivers/usb/host/pci-quirks.c | 3

Re: xhci_hcd : Not enough bandwidth on HS bus for newly activated TT.

2015-03-01 Thread Lu, Baolu
I tried to reproduce this issue on an Intel Ivybridge machine. But I failed. Kernel version: 4.0.0-rc1 (built against master branch of Greg's usb tree) USB fabric: $ sudo lsusb -t /: Bus 04.Port 1: Dev 1, Class=root_hub, Driver=ehci-pci/3p, 480M |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hu

Re: xhci_hcd : Not enough bandwidth on HS bus for newly activated TT.

2015-03-02 Thread Lu, Baolu
exist. so I guess I get it like 5 minutes after I send this ;) On 2015-03-02 03:37, Lu, Baolu wrote: Include Kenneth Johansson. On 2015-03-02 10:33, Lu, Baolu wrote: I tried to reproduce this issue on an Intel Ivybridge machine. But I failed. Kernel version: 4.0.0-rc1 (built against master bran

Re: xhci_hcd : Not enough bandwidth on HS bus for newly activated TT.

2015-03-04 Thread Lu, Baolu
Hi Kenneth Johansson, Did you still get the bandwidth error when testing it with longer time? Thanks, Baolu On 2015-03-03 10:06, Lu, Baolu wrote: cc'ed usb mailing list. On 2015-03-02 21:23, Kenneth Johansson wrote: I have been running 3.19 prereleases and now 3.19 and have not got

Re: xhci_hcd : Not enough bandwidth on HS bus for newly activated TT.

2015-03-05 Thread Lu, Baolu
On 03/05/2015 09:17 PM, Kenneth Johansson wrote: On 2015-03-05 03:23, Lu, Baolu wrote: Hi Kenneth Johansson, Did you still get the bandwidth error when testing it with longer time? no I have not seen it on any 3.19 kernel I have used so far. But It could take a week to see it before so

[PATCH 1/1] usb: xhci: handle Config Error Change (CEC) in xhci driver

2015-03-06 Thread Lu Baolu
EC bit is cleared in xhci_clear_port_change_bit(). [Mathias Nyman contributed the idea. The commit log is based on patch posted at http://marc.info/?l=linux-kernel&m=142323612321434&w=2] Signed-off-by: Lu Baolu Cc: stable # v3.2+ --- drivers/usb/host/xhci-hub.c | 9 - 1 file changed, 8 insert

Re: [PATCH 1/1] usb: xhci: handle Config Error Change (CEC) in xhci driver

2015-03-08 Thread Lu, Baolu
Hi Alan, Do you have any comments for this patch? Thanks, Baolu On 03/06/2015 04:12 PM, Lu Baolu wrote: Linux xHCI driver doesn't report and handle port cofig error change. If Port Configure Error for root hub port occurs, CEC bit in PORTSC would be set by xHC and remains 1. This hap

Re: Control message failures kill entire XHCI stack

2015-03-10 Thread Lu, Baolu
Hi Devin, Do you mind to post output of "lspci -xv" on the machine where you saw this problem? We are facing the same problems in other cases. I could provide a patch for it later. Thanks, Baolu On 01/19/2015 04:55 AM, Devin Heitmueller wrote: Hello, I'm debugging some issues on a couple

Re: Control message failures kill entire XHCI stack

2015-03-10 Thread Lu, Baolu
r Device Status: 0x0001 Self Powered Devin On Tue, Mar 10, 2015 at 5:55 AM, Lu, Baolu wrote: Hi Devin, Do you mind to post output of "lspci -xv" on the machine where you saw this problem? We are facing the same problems in other cases. I could provide a patch for it later.

Re: [V4.0.0-rc3] Xhci Regression: ERROR Transfer event TRB DMA ptr not part of current TD

2015-03-11 Thread Lu, Baolu
On 03/11/2015 02:49 AM, Alan Stern wrote: On Tue, 10 Mar 2015, Mathias Nyman wrote: Mathias: Your patch description says this: The endpoint might already processesed some TRBs on the endpiont ring before we soft reset the endpoint. Make sure we set the dequeue pointer to where we were befe

[PATCH 1/1] usb: xhci: apply XHCI_AVOID_BEI quirk to Intel ValleyView and LynxPoint LP

2015-03-11 Thread Lu Baolu
uot; is not notified. As the result, the xHC looks like dead to user. The patch is to apply XHCI_AVOID_BEI to Intel VallyView and Lynx Point LP devices. And it should be backported to kernels as old as 3.0, that contains the commit 69e848c2090a ("Intel xhci: Support EHCI/xHCI port switching.&q

Re: [PATCH 1/1] usb: xhci: apply XHCI_AVOID_BEI quirk to Intel ValleyView and LynxPoint LP

2015-03-12 Thread Lu, Baolu
On 03/12/2015 04:46 PM, Mathias Nyman wrote: On 12.03.2015 03:39, Lu Baolu wrote: When a device with an isochronous endpoint is plugged into the Intel xHCI host controller, and the driver submits multiple frames per URB, the xHCI driver will set the Block Event Interrupt (BEI) flag on all but

Re: [PATCH 1/1] usb: xhci: apply XHCI_AVOID_BEI quirk to Intel ValleyView and LynxPoint LP

2015-03-12 Thread Lu, Baolu
On 03/12/2015 03:54 PM, Greg Kroah-Hartman wrote: On Thu, Mar 12, 2015 at 09:39:06AM +0800, Lu Baolu wrote: When a device with an isochronous endpoint is plugged into the Intel xHCI host controller, and the driver submits multiple frames per URB, the xHCI driver will set the Block Event

[PATCH v2 1/1] usb: xhci: apply XHCI_AVOID_BEI quirk to all Intel xHCI controllers

2015-03-12 Thread Lu Baolu
, the xHC looks like dead to user. This patch is to apply XHCI_AVOID_BEI quirk to Intel xHC devices. And it should be backported to kernels as old as 3.0, that contains the commit 69e848c2090a ("Intel xhci: Support EHCI/xHCI port switching."). Signed-off-by: Lu Baolu Cc: sta...@vger.ke

[PATCH v3 1/1] usb: xhci: apply XHCI_AVOID_BEI quirk to all Intel xHCI controllers

2015-03-12 Thread Lu Baolu
, the xHC looks like dead to user. This patch is to apply XHCI_AVOID_BEI quirk to Intel xHC devices. And it should be backported to kernels as old as 3.0, that contains the commit 69e848c2090a ("Intel xhci: Support EHCI/xHCI port switching."). Signed-off-by: Lu Baolu Tested-by: Al

[PATCH 1/1] usb: Apply hardware LPM attributes to 3.1 device

2017-10-13 Thread Lu Baolu
The devices running at SuperSpeedPlus speed are also LPM capable. Apply usb3 hardware LPM attributes to those devices as well. Signed-off-by: Lu Baolu --- drivers/usb/core/sysfs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/usb/core/sysfs.c b/drivers/usb/core

Re: [PATCH v3 2/3] usb: xhci: Add DbC support in xHCI driver

2017-11-01 Thread Lu Baolu
Hi Greg, On 09/05/2017 09:58 AM, Lu Baolu wrote: > xHCI compatible USB host controllers(i.e. super-speed USB3 controllers) > can be implemented with the Debug Capability(DbC). It presents a debug > device which is fully compliant with the USB framework and provides the > equivalent of

Re: [PATCH v3 2/3] usb: xhci: Add DbC support in xHCI driver

2017-11-02 Thread Lu Baolu
y. >>>>>>> > >> >> > >>>>>>> > >> >> > When the debug capability is enabled, it will present a debug >>>>>>> > >> >> > device >>>>>>> > >> >> >

Re: [PATCH v3 2/3] usb: xhci: Add DbC support in xHCI driver

2017-11-05 Thread Lu Baolu
Hi, On 11/03/2017 02:27 PM, Greg Kroah-Hartman wrote: > On Fri, Nov 03, 2017 at 08:45:46AM +0800, Lu Baolu wrote: >> Hi, >> >> On 11/03/2017 12:51 AM, Greg Kroah-Hartman wrote: >>> On Thu, Nov 02, 2017 at 12:38:57PM +0200, Felipe Balbi wrote: >>>>&g

Re: [PATCH v3 2/3] usb: xhci: Add DbC support in xHCI driver

2017-11-06 Thread Lu Baolu
Hi, On 11/06/2017 04:00 PM, Greg Kroah-Hartman wrote: > On Mon, Nov 06, 2017 at 08:35:41AM +0800, Lu Baolu wrote: >> Hi, >> >> On 11/03/2017 02:27 PM, Greg Kroah-Hartman wrote: >>> On Fri, Nov 03, 2017 at 08:45:46AM +0800, Lu Baolu wrote: >>>> Hi, &g

[PATCH 2/2] USB: serial: Change DbC debug device binding ID

2017-11-06 Thread Lu Baolu
# v4.12+ Cc: Johan Hovold Signed-off-by: Lu Baolu --- drivers/usb/serial/usb_debug.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/serial/usb_debug.c b/drivers/usb/serial/usb_debug.c index 12f4c5a..48f285a 100644 --- a/drivers/usb/serial/usb_debug.c +++

[PATCH 1/2] USB: early: Use new USB product ID and strings for DbC device

2017-11-06 Thread Lu Baolu
valid one. The description strings are changed accordingly. This patch should be back-ported to kernels as old as v4.12, that contain the commit aeb9dd1de98c ("usb/early: Add driver for xhci debug capability"). Cc: # v4.12+ Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.h | 6

Re: [PATCH 13/24] USB: early: Remove redundant license text

2017-11-06 Thread Lu Baolu
t to remove the 700+ different ways that files in > the kernel describe the GPL license text. And there's unneeded stuff > like the address (sometimes incorrect) for the FSF which is never > needed. > > No copyright headers or other non-license-description text was removed. >

Re: [PATCH v3 2/3] usb: xhci: Add DbC support in xHCI driver

2017-11-14 Thread Lu Baolu
return -ENOMEM; >>> + >>> + db->buf_size = size; >>> + db->buf_put = db->buf_buf; >>> + db->buf_get = db->buf_buf; >>> + >>> + return 0; >>> +} > you may wanna have a look at kfifo. > Yeah! kfifo

[PATCH 1/1] usb: serial: usb_debug: Add new USB device id

2017-11-27 Thread Lu Baolu
USB vendor id and product id for Linux USB Debug Target is added. Signed-off-by: Lu Baolu --- drivers/usb/serial/usb_debug.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/usb/serial/usb_debug.c b/drivers/usb/serial/usb_debug.c index ab5a2ac..47636b6 100644 --- a/drivers/usb

[PATCH 1/1] usb: gadget: u_serial: Use kfifo instead of homemade circular buffer

2017-11-27 Thread Lu Baolu
The kernel FIFO implementation, kfifo, provides interfaces to manipulate a first-in-first-out circular buffer. Use kfifo instead of the homemade one to make the code more concise and readable. Signed-off-by: Lu Baolu --- drivers/usb/gadget/function/u_serial.c | 192

[PATCH 1/1] usb: early: Correct the endpoint type value for bulk in endpoint

2017-11-27 Thread Lu Baolu
This corrects the endpiont type value set to the DbC bulk in endpoint. The previous value doesn't cause any problems because that we now only use the bulk out endpoint. Set the hardware with the correct value any way. Signed-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 2 +- 1

Re: [PATCH 1/1] usb: early: Correct the endpoint type value for bulk in endpoint

2017-11-27 Thread Lu Baolu
Hi, On 11/28/2017 03:29 PM, Greg Kroah-Hartman wrote: > On Tue, Nov 28, 2017 at 12:52:24PM +0800, Lu Baolu wrote: >> This corrects the endpiont type value set to the DbC bulk in endpoint. >> The previous value doesn't cause any problems because that we now only >> use

Re: [PATCH 1/1] usb: gadget: u_serial: Use kfifo instead of homemade circular buffer

2017-11-28 Thread Lu Baolu
Hi Felipe, On 11/28/2017 04:05 PM, Felipe Balbi wrote: > Hi, > > Lu Baolu writes: >> The kernel FIFO implementation, kfifo, provides interfaces to manipulate >> a first-in-first-out circular buffer. Use kfifo instead of the homemade >> one to make the cod

Re: [PATCH 1/1] usb: serial: usb_debug: Add new USB device id

2017-11-28 Thread Lu Baolu
Hi Johan, On 11/28/2017 05:01 PM, Johan Hovold wrote: > On Tue, Nov 28, 2017 at 12:40:59PM +0800, Lu Baolu wrote: >> USB vendor id and product id for Linux USB Debug Target is added. >> >> Signed-off-by: Lu Baolu >> --- >> drivers/usb/serial/usb_debug.c | 2 ++

[PATCH 1/1] usb: doc: Update document for USB3 debug port usage

2017-12-12 Thread Lu Baolu
Update Documentation/driver-api/usb/usb3-debug-port.rst. This update includes the guide for using xHCI debug capability based TTY serial link. Cc: Mathias Nyman Cc: Greg Kroah-Hartman Signed-off-by: Lu Baolu --- Documentation/driver-api/usb/usb3-debug-port.rst | 52 1

[PATCH 1/1] usb: xhci: dbc: Fix lockdep warning

2017-12-15 Thread Lu Baolu
33] ? kthread_delayed_work_timer_fn+0x80/0x80 [ 528.511755] ret_from_fork+0x24/0x30 Fixes: dfba2174dc42 ("usb: xhci: Add DbC support in xHCI driver") Signed-off-by: Lu Baolu --- drivers/usb/host/xhci-dbgcap.c | 20 drivers/usb/host/xhci-dbgtty.c | 20 --

[PATCH 1/1] usb: xhci: dbc: Add SPDX identifiers to dbc files

2017-12-21 Thread Lu Baolu
Update the xhci dbc files with the correct SPDX license identifiers. Fixes: dfba2174dc42 ("usb: xhci: Add DbC support in xHCI driver") Signed-off-by: Lu Baolu --- drivers/usb/host/xhci-dbgcap.c | 1 + drivers/usb/host/xhci-dbgcap.h | 2 +- drivers/usb/host/xhci-dbgtty.c | 1 + 3 fil

Re: [PATCH 1/1] usb: xhci: dbc: Add SPDX identifiers to dbc files

2017-12-22 Thread Lu Baolu
Hi, On 12/22/2017 04:32 PM, Philippe Ombredanne wrote: > Lu, > > On Fri, Dec 22, 2017 at 2:34 AM, Lu Baolu wrote: >> Update the xhci dbc files with the correct SPDX license identifiers. >> >> Fixes: dfba2174dc42 ("usb: xhci: Add DbC support in xHCI dri

[PATCH v2 1/1] usb: xhci: dbc: Add SPDX identifiers to dbc files

2017-12-22 Thread Lu Baolu
Update the xhci dbc files with the correct SPDX license identifiers. Fixes: dfba2174dc42 ("usb: xhci: Add DbC support in xHCI driver") Cc: Philippe Ombredanne Signed-off-by: Lu Baolu --- changes from v1: * Use plain C style comments in header file. drivers/usb/host/xhci-db

[PATCH 1/2] usb: xhci: Remove ep_trb from xhci_cleanup_halted_endpoint()

2018-01-09 Thread Lu Baolu
Function argument ep_trb for xhci_cleanup_halted_endpoint() isn't needed anymore. Cleanup it. Signed-off-by: Lu Baolu --- drivers/usb/host/xhci-ring.c | 11 --- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-r

[PATCH 2/2] usb: xhci: Remove ep_trb from finish_td()

2018-01-09 Thread Lu Baolu
Function argument ep_trb for finish_td() isn't needed anymore. Cleanup it. Signed-off-by: Lu Baolu --- drivers/usb/host/xhci-ring.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c index 642a070..88

Re: [PATCH v8 1/5] x86: add simple udelay calibration

2017-05-04 Thread Lu Baolu
Hi, On 05/03/2017 06:38 AM, Boris Ostrovsky wrote: > On 03/21/2017 04:01 AM, Lu Baolu wrote: >> Add a simple udelay calibration in x86 architecture-specific >> boot-time initializations. This will get a workable estimate >> for loops_per_jiffy. Hence, udelay() cou

Re: [PATCH v8 2/5] usb: early: add driver for xhci debug capability

2017-05-30 Thread Lu Baolu
Hi, On 05/30/2017 09:46 PM, Vlastimil Babka wrote: > On 03/21/2017 09:01 AM, Lu Baolu wrote: >> XHCI debug capability (DbC) is an optional but standalone >> functionality provided by an xHCI host controller. Software >> learns this capability by walking through the extended

Re: [PATCH v8 2/5] usb: early: add driver for xhci debug capability

2017-05-31 Thread Lu Baolu
Hi, On 05/31/2017 02:24 PM, Steven Rostedt wrote: > On Wed, 31 May 2017 11:27:19 +0800 > Lu Baolu wrote: > > >>>> + >>>> +#define XDBC_TRACE >>>> +#ifdef XDBC_TRACE >>>> +#define xdbc_trace trace_printk >>> Did you

Re: [PATCH v8 2/5] usb: early: add driver for xhci debug capability

2017-05-31 Thread Lu Baolu
Hi, On 05/31/2017 05:38 PM, Vlastimil Babka wrote: > On 05/31/2017 05:27 AM, Lu Baolu wrote: >> Hi, >> >> On 05/30/2017 09:46 PM, Vlastimil Babka wrote: >>> On 03/21/2017 09:01 AM, Lu Baolu wrote: >>>> XHCI debug capability (DbC) is an optional but st

[PATCH 1/1] usb/early: Remove trace_printk() callers in xhci-dbc

2017-06-03 Thread Lu Baolu
d-off-by: Lu Baolu --- drivers/usb/early/xhci-dbc.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/usb/early/xhci-dbc.c b/drivers/usb/early/xhci-dbc.c index 1268818..12fe70b 100644 --- a/drivers/usb/early/xhci-dbc.c +++ b/drivers/usb/early/xhci-dbc.c @@ -32,7 +32,6 @@ static s

Re: [PATCH v8 1/5] x86: add simple udelay calibration

2017-07-12 Thread Lu Baolu
Hi, On 07/12/2017 04:02 PM, Dou Liyang wrote: > Hi, Lu > > At 05/05/2017 08:50 PM, Boris Ostrovsky wrote: >> On 05/05/2017 01:41 AM, Lu Baolu wrote: >>> Hi, >>> >>> On 05/03/2017 06:38 AM, Boris Ostrovsky wrote: >>>> On 03/21/2017 04:01 AM, Lu

Re: [PATCH v8 1/5] x86: add simple udelay calibration

2017-07-12 Thread Lu Baolu
Hi, On 07/13/2017 09:39 AM, Dou Liyang wrote: > Hi, Lu > > At 07/13/2017 09:17 AM, Lu Baolu wrote: >> Hi, >> >> On 07/12/2017 04:02 PM, Dou Liyang wrote: >>> Hi, Lu >>> >>> At 05/05/2017 08:50 PM, Boris Ostrovsky wrote: >>>> On 0

[PATCH 2/3] usb: xhci: Add DbC support in xHCI driver

2017-07-21 Thread Lu Baolu
. Hence it can be remote accessed by a debug host. Another use case can probably be found in servers. It provides a peer-to-peer USB link between two host-only machines. This provides a reasonable out-of-band communication method between two servers. Signed-off-by: Lu Baolu --- .../ABI/testing/sysfs

<    1   2   3   4   5   6   7   >