Hi,
On 05/03/2016 07:49 PM, Mark Brown wrote:
> On Tue, May 03, 2016 at 09:43:58AM +0800, Lu Baolu wrote:
>> On 05/02/2016 07:00 PM, Mark Brown wrote:
>>> On Fri, Apr 29, 2016 at 02:26:32PM +0800, Lu Baolu wrote:
>>>> + gpiod = gpiod_get(dev, "vbus_en"
Several Intel PCHs and SOCs have an internal mux that is used to
share one USB port between device controller and host controller.
The mux is handled through the Dual Role Configuration Register.
Signed-off-by: Heikki Krogerus
Signed-off-by: Lu Baolu
Signed-off-by: Wu Hao
Reviewed-by: Felipe
Add a maintainer entry for Intel USB dual role mux drivers and
add myself as a maintainer.
Signed-off-by: Lu Baolu
---
MAINTAINERS | 10 ++
1 file changed, 10 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index 1d5b4be..6ab9e02 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
mux switch.
Signed-off-by: Lu Baolu
Reviewed-by: Felipe Balbi
---
drivers/usb/host/pci-quirks.c| 45 ++--
drivers/usb/host/xhci-ext-caps.h | 2 ++
2 files changed, 45 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/host/pci-quirks.c b/drivers/usb
-by: Lu Baolu
Reviewed-by: Heikki Krogerus
Reviewed-by: Felipe Balbi
---
drivers/usb/mux/Kconfig | 11 +++
drivers/usb/mux/Makefile | 1 +
drivers/usb/mux/portmux-intel-gpio.c | 149 +++
3 files changed, 161 insertions(+)
create mode
Add support to retrieve fixed voltage configure information through
ACPI interface. This is needed for Intel Bay Trail devices, where a
GPIO is used to control the USB vbus.
Signed-off-by: Lu Baolu
---
drivers/regulator/fixed.c | 46 ++
1 file changed
control the port mux from
user space.
Some other archs (e.g. Renesas R-Car gen2 SoCs) need an external mux to
swap usb roles as well. This code could be leveraged for those archs
as well.
Signed-off-by: Lu Baolu
Reviewed-by: Heikki Krogerus
Reviewed-by: Felipe Balbi
Reviewed-by: Chanwoo Choi
owner per platform_no_drv_owner.cocci]
Suggested-by: David Cohen
Signed-off-by: Lu Baolu
Reviewed-by: Felipe Balbi
---
drivers/mfd/Kconfig| 8 +
drivers/mfd/Makefile | 1 +
drivers/mfd/intel-vuport.c | 89 ++
3 files change
series includes a driver for GPIO USB mux.
(3) Drivers for USB port mux controlled through memory mapped
registers and the logic to create the mux device. This type
of dual role port mux could be found in Cherry Trail and
Broxton devices.
Lu Baolu (7):
regulator: fixed: add support for
Hi,
On 05/13/2016 07:17 PM, Mark Brown wrote:
> On Thu, May 05, 2016 at 01:32:57PM +0800, Lu Baolu wrote:
>
>> +gpiod = gpiod_get(dev, "gpio", GPIOD_ASIS);
>> +if (IS_ERR(gpiod))
>> +return ERR_PTR(-ENODEV);
>> +config->
faces.
struct portmux_dev *portmux_register(struct portmux_desc *desc);
void portmux_unregister(struct portmux_dev *pdev);
I will add below ones.
struct portmux_dev *portmux_lookup_by_name(char *name);
int portmux_switch(struct portmux_dev *pdev, enum port_role);
The normal usage mode is
1) the mux device is registered as soon as a mux is detected with
portmux_register();
2) In components like USB PHY or changer drivers, the mux could
be retrieved with portmux_lookup_by_name() and controlled via
portmux_switch().
Is this helpful?
Best regards,
Lu Baolu
--
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
x could
>> > be retrieved with portmux_lookup_by_name() and controlled via
>> > portmux_switch().
>> >
>> > Is this helpful?
> It works for me, and we can improve it later if needed.
Okay, thanks.
Best regards,
Lu Baolu
--
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
mux could be found in Cherry Trail and
Broxton devices.
All patches have been verified to work on Intel's BayTrail,
CherryTrail, and Broxton P platforms.
Lu Baolu (7):
regulator: fixed: add support for ACPI interface
usb: mux: add generic code for dual role port mux
usb: mux: add d
users are able
to control the port role from user space.
Some other archs (e.g. Renesas R-Car gen2 SoCs) need an external mux to
swap usb roles as well. This code could also be leveraged for those archs.
Signed-off-by: Lu Baolu
Reviewed-by: Heikki Krogerus
Reviewed-by: Felipe Balbi
owner per platform_no_drv_owner.cocci]
Suggested-by: David Cohen
Signed-off-by: Lu Baolu
Reviewed-by: Felipe Balbi
Acked-by: Lee Jones
---
drivers/mfd/Kconfig| 8 +
drivers/mfd/Makefile | 1 +
drivers/mfd/intel-vuport.c | 86 ++
3
mux switch.
Signed-off-by: Lu Baolu
Reviewed-by: Felipe Balbi
---
drivers/usb/host/pci-quirks.c| 42 +++-
drivers/usb/host/xhci-ext-caps.h | 2 ++
2 files changed, 43 insertions(+), 1 deletion(-)
diff --git a/drivers/usb/host/pci-quirks.c b/drivers/usb
Add a maintainer entry for Intel USB dual role mux drivers and
add myself as a maintainer.
Signed-off-by: Lu Baolu
---
MAINTAINERS | 10 ++
1 file changed, 10 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index ed1229e..edaeebe 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
Several Intel PCHs and SOCs have an internal mux that is used to
share one USB port between device controller and host controller.
The mux is handled through the Dual Role Configuration Register.
Signed-off-by: Heikki Krogerus
Signed-off-by: Lu Baolu
Signed-off-by: Wu Hao
Reviewed-by: Felipe
Chanwoo Choi]
Signed-off-by: David Cohen
Signed-off-by: Lu Baolu
Reviewed-by: Heikki Krogerus
Reviewed-by: Felipe Balbi
Reviewed-by: Chanwoo Choi
---
drivers/usb/mux/Kconfig | 13 +++
drivers/usb/mux/Makefile | 1 +
drivers/usb/mux/portmux-intel-gpio.c | 183
Add support to retrieve fixed voltage configure information through
ACPI interface. This is needed for Intel Bay Trail devices, where a
GPIO is used to control the USB vbus.
Signed-off-by: Lu Baolu
---
drivers/regulator/fixed.c | 46 ++
1 file changed
Hi Heikki,
On 05/30/2016 04:16 PM, Heikki Krogerus wrote:
> Hi Baolu,
>
> On Mon, May 30, 2016 at 01:51:44PM +0800, Lu Baolu wrote:
>> Add a maintainer entry for Intel USB dual role mux drivers and
>> add myself as a maintainer.
>>
>> Signed-off-by: Lu B
Hi,
On 05/30/2016 08:53 PM, Lu Baolu wrote:
> Hi Heikki,
>
> On 05/30/2016 04:16 PM, Heikki Krogerus wrote:
>> Hi Baolu,
>>
>> On Mon, May 30, 2016 at 01:51:44PM +0800, Lu Baolu wrote:
>>> Add a maintainer entry for Intel USB dual role mux driver
Several Intel PCHs and SOCs have an internal mux that is used to
share one USB port between device controller and host controller.
The mux is handled through the Dual Role Configuration Register.
Signed-off-by: Heikki Krogerus
Signed-off-by: Lu Baolu
Signed-off-by: Wu Hao
Reviewed-by: Felipe
Add a maintainer entry for Intel USB dual role mux drivers and
add myself as a maintainer.
Signed-off-by: Lu Baolu
---
MAINTAINERS | 10 ++
1 file changed, 10 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index 7304d2e..56a98d2 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
mux switch.
Signed-off-by: Lu Baolu
Reviewed-by: Felipe Balbi
---
drivers/usb/host/pci-quirks.c| 42 +++-
drivers/usb/host/xhci-ext-caps.h | 2 ++
2 files changed, 43 insertions(+), 1 deletion(-)
diff --git a/drivers/usb/host/pci-quirks.c b/drivers/usb
owner per platform_no_drv_owner.cocci]
Suggested-by: David Cohen
Signed-off-by: Lu Baolu
Reviewed-by: Felipe Balbi
Acked-by: Lee Jones
---
drivers/mfd/Kconfig| 8 +
drivers/mfd/Makefile | 1 +
drivers/mfd/intel-vuport.c | 86 ++
3
users are able
to control the port role from user space.
Some other archs (e.g. Renesas R-Car gen2 SoCs) need an external mux to
swap usb roles as well. This code could also be leveraged for those archs.
Signed-off-by: Lu Baolu
Reviewed-by: Heikki Krogerus
Reviewed-by: Felipe Balbi
mux could be found in Cherry Trail and
Broxton devices.
All patches have been verified on Intel's BayTrail, CherryTrail,
and Broxton P platforms.
Lu Baolu (7):
regulator: fixed: add support for ACPI interface
usb: mux: add generic code for dual role port mux
usb: mux: add drive
Chanwoo Choi]
Signed-off-by: David Cohen
Signed-off-by: Lu Baolu
Reviewed-by: Heikki Krogerus
Reviewed-by: Felipe Balbi
Reviewed-by: Chanwoo Choi
---
drivers/usb/mux/Kconfig | 13 +++
drivers/usb/mux/Makefile | 1 +
drivers/usb/mux/portmux-intel-gpio.c | 183
Add support to retrieve fixed voltage configure information through
ACPI interface. This is needed for Intel Bay Trail devices, where a
GPIO is used to control the USB vbus.
Signed-off-by: Lu Baolu
---
drivers/regulator/fixed.c | 46 ++
1 file changed
Hi Peter,
On 06/03/2016 03:41 PM, Peter Chen wrote:
> On Thu, Jun 02, 2016 at 09:37:24AM +0800, Lu Baolu wrote:
>> > Several Intel platforms implement USB dual role by having completely
>> > separate xHCI and dwc3 IPs in PCH or SOC silicons. These two IPs share
>> &g
Hi Peter,
On 06/04/2016 10:28 AM, Peter Chen wrote:
> On Sat, Jun 04, 2016 at 12:06:06AM +0800, Lu Baolu wrote:
>>> from my point,it is a dual-role switch
>>> driver too,
>> No, it's not a dual-role switch driver, but a driver for USB port
>> multiplexing.
equirement, we
> should improve it, Roger also provide an example of dual role switch with
> USB3 based on his OTG core.
Why do we need an OTG framework to support a device driver?
Is it something like a bus or class driver?
Best regards,
Lu Baolu
--
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
Hi Jun,
On 06/06/2016 09:08 AM, Jun Li wrote:
>
>> -Original Message-
>> From: Lu Baolu [mailto:baolu...@linux.intel.com]
>> Sent: Sunday, June 05, 2016 4:47 PM
>> To: Jun Li ; Peter Chen
>> Cc: felipe.ba...@linux.intel.com; Mathias Nyman ;
>> Gre
Hi Peter,
On 06/06/2016 10:05 AM, Peter Chen wrote:
> On Sun, Jun 05, 2016 at 04:46:55PM +0800, Lu Baolu wrote:
>> Hi,
>>
>> On 06/05/2016 04:33 PM, Jun Li wrote:
>>>> Port mux is part of dual role switch, but not the whole thing.
>>>>> Dual role sw
Hi Peter,
On 06/06/2016 09:25 AM, Peter Chen wrote:
> On Sun, Jun 05, 2016 at 02:55:56PM +0800, Lu Baolu wrote:
>> Hi Peter,
>>
>> On 06/04/2016 10:28 AM, Peter Chen wrote:
>>> On Sat, Jun 04, 2016 at 12:06:06AM +0800, Lu Baolu wrote:
>>>>> from my po
ocumentation/ABI/testing/sysfs-bus-platform.
>
> I agree with Roger that the dual-role switch part in your code is better
> to use OTG framework to reduce redundancy.
I agree that we should use dual-role framework for role switch. Actually,
my code doesn't do this work. It only adds a generic framework for port
mux device and two mux device drivers used in Intel platform.
Best regards,
Lu Baolu
--
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
t we have concern, do dual role switch through
> OTG/dual-role core, not do it by itself.
That really depends on how do you define "dual role". Can you please
provide an unambiguous definition of "dual role" used in OTG/dual-role
framework?
Best regards,
Lu Baolu
>
>
OTG/dual-role code, my understanding is that "dual-role" is a
"reduced OTG" which is for DRD devices lacking of some OTG negotiation
protocols.
We really can't say "it's the scope of OTG/dual-role" whenever it comes to
"host and peripheral".
Best regards,
Lu Baolu
--
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
t run an unnecessary OTG state machine, even thought it
has nothing to do with my system, only because the two sides of my port
mux device is a host and peripheral controller.
Why?
Best regards,
Lu Baolu
--
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
Hi Greg,
On 06/08/2016 12:45 PM, Greg Kroah-Hartman wrote:
> On Thu, Jun 02, 2016 at 09:37:28AM +0800, Lu Baolu wrote:
>> In some Intel platforms, a single usb port is shared between USB host
>> and device controllers. The shared port is under control of a switch
>> which is
Hi Greg,
On 06/08/2016 11:45 PM, Greg Kroah-Hartman wrote:
> On Wed, Jun 08, 2016 at 03:56:04PM +0800, Lu Baolu wrote:
>> Hi Greg,
>>
>> On 06/08/2016 12:45 PM, Greg Kroah-Hartman wrote:
>>> On Thu, Jun 02, 2016 at 09:37:28AM +0800, Lu Baolu wrote:
>>>>
Hi Felipe and Heikki,
On 06/08/2016 12:42 PM, Greg Kroah-Hartman wrote:
> On Thu, Jun 02, 2016 at 09:37:23AM +0800, Lu Baolu wrote:
>> Add support to retrieve fixed voltage configure information through
>> ACPI interface. This is needed for Intel Bay Trail devices, where a
>
Hi Greg,
On 06/09/2016 10:39 AM, Lu Baolu wrote:
> Hi Greg,
>
> On 06/08/2016 11:45 PM, Greg Kroah-Hartman wrote:
>> On Wed, Jun 08, 2016 at 03:56:04PM +0800, Lu Baolu wrote:
>>> Hi Greg,
>>>
>>> On 06/08/2016 12:45 PM, Greg Kroah-Hartman wrote:
>>
Hi Greg,
On 06/18/2016 08:58 AM, Greg Kroah-Hartman wrote:
> On Thu, Jun 16, 2016 at 08:27:41AM +0800, Lu Baolu wrote:
>> Hi Greg,
>>
>> On 06/09/2016 10:39 AM, Lu Baolu wrote:
>>> Hi Greg,
>>>
>>> On 06/08/2016 11:45 PM, Greg Kroah-Hartman wrote:
&
stop endpoint commands. If the timer is the tail end of the last
- * stop endpoint command, and the endpoint's command is still pending, we
assume
- * the host is dying.
Best regards,
Lu Baolu
>
> We also need to clean up the command queue before trying to halt the
> xHCI host in xh
Hi,
On 12/01/2016 02:04 PM, Baolin Wang wrote:
> Hi Baolu,
>
> On 1 December 2016 at 13:45, Lu Baolu wrote:
>> Hi,
>>
>> On 11/30/2016 05:02 PM, Baolin Wang wrote:
>>> If the hardware never responds to the stop endpoint command, the
>>> URBs will
Hi,
On 12/01/2016 03:35 PM, Baolin Wang wrote:
> On 1 December 2016 at 14:35, Lu Baolu wrote:
>> Hi,
>>
>> On 12/01/2016 02:04 PM, Baolin Wang wrote:
>>> Hi Baolu,
>>>
>>> On 1 December 2016 at 13:45, Lu Baolu wrote:
>>>> Hi,
>&
Hi,
On 12/01/2016 04:03 PM, Baolin Wang wrote:
> On 1 December 2016 at 15:44, Lu Baolu wrote:
>> Hi,
>>
>> On 12/01/2016 03:35 PM, Baolin Wang wrote:
>>> On 1 December 2016 at 14:35, Lu Baolu wrote:
>>>> Hi,
>>>>
>>>> On 12/01/
# v3.16+
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci-ring.c | 16 +++-
1 file changed, 11 insertions(+), 5 deletions(-)
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c
index bdf6b13..13e05f6 100644
--- a/drivers/usb/host/xhci-ring.c
+++ b/drivers/usb/h
Hi,
On 12/02/2016 12:18 PM, Baolin Wang wrote:
> On 2 December 2016 at 10:29, Lu Baolu wrote:
>> handle_cmd_completion() frees a command structure which might
>> be still referenced by xhci->current_cmd. This might cause
>> problem when xhci->current_cmd is accessed af
Hi,
On 12/02/2016 09:39 PM, Mathias Nyman wrote:
> On 02.12.2016 04:29, Lu Baolu wrote:
>> handle_cmd_completion() frees a command structure which might
>> be still referenced by xhci->current_cmd. This might cause
>> problem when xhci->current_cmd is accessed after t
atch for that one case
> it seems that patch 2/2 can be replaced by a single line change:
>
> if (!xhci->current_cmd || timer_pending(&xhci->cmd_timer))
>
> Right?
>
> -Mathias
>
It seems that the watch dog algorithm for command queue becomes
more and more complica
Hi,
On 12/20/2016 02:06 PM, Baolin Wang wrote:
> Hi,
>
> On 20 December 2016 at 12:29, Lu Baolu wrote:
>> Hi Mathias,
>>
>> On 12/19/2016 08:13 PM, Mathias Nyman wrote:
>>> On 19.12.2016 13:34, Baolin Wang wrote:
>>>> Hi Mathias,
>>>>
Hi,
On 12/20/2016 02:46 PM, Baolin Wang wrote:
> On 20 December 2016 at 14:39, Lu Baolu wrote:
>> Hi,
>>
>> On 12/20/2016 02:06 PM, Baolin Wang wrote:
>>> Hi,
>>>
>>> On 20 December 2016 at 12:29, Lu Baolu wrote:
>>>> Hi Mathias,
>
n");
368 xhci_cleanup_command_queue(xhci);
369 } else {
370 unsigned long flags;
371
372 spin_lock_irqsave(&xhci->lock, flags);
373 xhci_handle_stopped_cmd_ring(xhci,
xhci_next_queued_cmd(xhci));
374 spin_u
>current_cmd);
1327 spin_unlock_irqrestore(&xhci->lock, flags);
This part of code is tricky. I have no idea about in which case should this
code be executed? Anyway, we shouldn't call xhci_handle_stopped_cmd_ring()
here, right?
1328 return;
1329 }
Best regards,
Lu Baolu
--
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
Hi,
On 12/21/2016 08:57 PM, Mathias Nyman wrote:
> On 21.12.2016 08:57, Lu Baolu wrote:
>> Hi Mathias,
>>
>> I have some comments for the implementation of
>> xhci_handle_command_timeout() as well.
>>
>> On 12/20/2016 11:13 PM, Mathias Nyman wrote:
>
Hi,
On 12/21/2016 08:48 PM, Mathias Nyman wrote:
> On 21.12.2016 08:17, Lu Baolu wrote:
>> Hi Mathias,
>>
>> I have some comments for the implementation of xhci_abort_cmd_ring() below.
>>
>> On 12/20/2016 11:13 PM, Mathias Nyman wrote:
>>&
D to
>> CMD_RING_STATE_RUNNING so ring will really restart in the interrupt
>> handler.
> Just for record (no chance to make patch I myself for now, sorry), while
> checking locking slightly, I noticed unrelated missing locking.
>
> xhci_cleanup_command_queue()
>
>
= platform_get_resource(pdev, IORESOURCE_MEM, 0);
> + size = (res->end + 1) - res->start;
"res" is used without check.
> + phy->base = devm_ioremap_nocache(dev, res->start, size);
This resource is part of xHCI MMIO. xHCI driver has already declared
to use the who
be an acceptable solution ?
> For me? sure :-) Let's get Greg and Oliver to agree though.
>
>> About the "other 2-patch dwc3 series", I'm fine with you not taking
>> the IDA patch, but the first patch is unrelated to IDA, it is a pure
>> bug-fix and real
but the first patch is unrelated to IDA, it is a pure
>>> bug-fix and really should be upstreamed.
>>>
>>> Matthias, assuming Felipe is ok with putting this in drivers/misc
>>> (minus the phy bindings), are you ok with the xhci blurb which
>>> registers t
of calling functions without
locking in xhci_handle_command_timeout().
Cc: # 3.7+
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci-ring.c | 13 +
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c
index 7971
Hi Mathias,
This is a follow-up patch for below comment
"fix the lock to cover abort+CRR check, and send it to usb-linus +stable"
in below discussion thread.
https://lkml.org/lkml/2016/12/21/186
It's based on v4.9.
Best regards,
Lu Baolu
Lu Baolu (1):
usb: xhci:
ng
waiting for the command stopped event.
It sits at the same place in your timeout_race_fixes branch.
(git://git.kernel.org/pub/scm/linux/kernel/git/mnyman/xhci.git
timeout_race_fixes)
Best regards,
Lu Baolu
OGAWA Hirofumi (1):
xhci: Fix race related to abort operation
drivers/usb/host
CMD_RING_PAUSE
operation]
[baolu: release xhci->lock before wait and apply it back again after
wait. This is the reason my signed-off-by is added.]
CC:
Signed-off-by: OGAWA Hirofumi
Signed-off-by: Lu Baolu
Signed-off-by: Mathias Nyman
---
drivers/usb/host/xhci-mem.c | 1 +
drivers/usb/host/x
situation to the upper layer. In rare cases,
if the driver sees a command timeout in a stopped command
ring, driver should let the user know it.
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci-ring.c | 8 ++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/host/xhci
usb: xhci: warn on command timeout in stopped command ring
are my proposals.
They base on the top of your timeout_race_fixes branch.
(git://git.kernel.org/pub/scm/linux/kernel/git/mnyman/xhci.git
timeout_race_fixes)
Lu Baolu (4):
usb: xhci: remove unnecessary second abort try
usb: xhci: r
The second try was a workaround for (what we thought was) command
ring failing to stop in the first place. But this turns out to be
due to the race that we have fixed(see "xhci: Fix race related to
abort operation"). With that fix, it is time to remove the second
try.
Signed-off-by
cpu cycles are wasted on polling
registers. This patch removes polling for CRR (Command Ring
Running). Wait for completion, and check CRR if completion
times out is enough.
Suggested-by: Mathias Nyman
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci-ring.c | 49
ts, if the command completion for abort command
ring misses, we shall assume that there are larger problems
with the host and assert HCRST.
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci-ring.c | 17 +
drivers/usb/host/xhci.h | 6 ++
2 files changed, 11 insertions(+), 12
and interrupt threads. Or, I missed anything?
Best regards,
Lu Baolu
>
> Signed-off-by: Baolin Wang
> ---
> drivers/usb/dwc3/gadget.c |6 +-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
>
Hi,
On 12/27/2016 10:58 AM, Baolin Wang wrote:
> Hi,
>
> On 27 December 2016 at 10:39, Lu Baolu wrote:
>> Hi,
>>
>> On 12/26/2016 04:01 PM, Baolin Wang wrote:
>>> On some platfroms(like x86 platform), when one core is running the USB
>>> gadget
&g
td->urb->ep->desc.bEndpointAddress,
> - requested, remaining);
> - }
> + dev_WARN_ONCE(dev, (ep_trb != td->last_trb) || remaining,
> + "ep%d%s: unexpected success! TRB %p/%p size
> %d/%d\n",
> +
d as a RW type.
724 temp = readl(&xhci->op_regs->status);
725 writel(temp & ~STS_EINT, &xhci->op_regs->status);
I will correct these in a separated patch and cc stable as well.
Best regards,
Lu Baolu
>
> Signed-off-by: Felipe Balbi
> ---
>
trb->generic.field[1] = 0;
> + trb->generic.field[2] = 0;
> + /* Preserve only the cycle bit of this TRB */
> + trb->generic.field[3] &= cpu_to_le32(TRB_CYCLE);
> + trb->generic.field[3] = cpu_to_le32(TRB_TYPE(TRB_CMD
S(ring, trb)
> +);
> +
> +DEFINE_EVENT(xhci_log_trb, xhci_handle_command,
> + TP_PROTO(struct xhci_ring *ring, struct xhci_generic_trb *trb),
> + TP_ARGS(ring, trb)
> +);
> +
> +DEFINE_EVENT(xhci_log_trb, xhci_handle_transfer,
> + TP_PROTO(struct xhci_ring *r
4+
CC: Felipe Balbi
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c
index 1cd5641..18ea6b8 100644
--- a/drivers/usb/host/xhci.c
+++ b/drivers/usb/host/xhci.c
@@ -721,7 +
Hi,
On 12/30/2016 03:52 PM, Felipe Balbi wrote:
> Hi,
>
> Lu Baolu writes:
>> On 12/29/2016 07:00 PM, Felipe Balbi wrote:
>>> Many other bits in USBSTS register are "clear-by-writing-1". Let's make
>>> sure that we clear *only* STS_EINT and not a
Hi,
On 12/30/2016 03:54 PM, Felipe Balbi wrote:
> Hi,
>
> Lu Baolu writes:
>> On 12/29/2016 07:00 PM, Felipe Balbi wrote:
>>> instead of open coding how to convert a TRB to no-op, let's use our
>>> newly introduced helper.
>>>
>>> Signed-
Hi,
On 12/30/2016 03:47 PM, Felipe Balbi wrote:
> Hi,
>
> Lu Baolu writes:
>>> +DEFINE_EVENT(xhci_log_trb, xhci_handle_event,
>>> + TP_PROTO(struct xhci_ring *ring, struct xhci_generic_trb *trb),
>>> + TP_ARGS(ring, trb)
>>> +);
>>>
Hi,
On 01/02/2017 04:47 PM, Felipe Balbi wrote:
> Hi,
>
> Lu Baolu writes:
>> Hi,
>>
>> On 12/30/2016 03:52 PM, Felipe Balbi wrote:
>>> Hi,
>>>
>>> Lu Baolu writes:
>>>> On 12/29/2016 07:00 PM, Felipe Balbi wrote:
>>>
Hi,
On 01/02/2017 04:53 PM, Felipe Balbi wrote:
> Hi,
>
> Lu Baolu writes:
>> Hi,
>>
>> On 12/30/2016 03:47 PM, Felipe Balbi wrote:
>>> Hi,
>>>
>>> Lu Baolu writes:
>>>>> +DEFINE_EVENT(xhci_log_trb, xhci_handle_event,
4+
Cc: Felipe Balbi
Signed-off-by: Lu Baolu
---
Change log:
v1->v2:
- Fixed a warning reported by 0-day kbuild robot.
drivers/usb/host/xhci.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c
index 1cd5641..bb08c6b 1006
Use list_is_singular() to check if cmd_list has only one entry.
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci-ring.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c
index 95be9e8..40947e7 100644
--- a
Remove the unnecessary return line in xhci_pci_setup().
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci-pci.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/usb/host/xhci-pci.c b/drivers/usb/host/xhci-pci.c
index e96ae80..ace3f57 100644
--- a/drivers/usb/host/xhci-pci.c
+++ b
Hi Mathias,
This series includes several tiny cleanup patches for xhci host
controller driver. These make the code slightly more readable.
There's no functional change.
Please consider it for your for-usb-next branch.
Best regards,
Lu Baolu
Lu Baolu (4):
usb: xhci: remove unnece
Drop an unnecessary assignment in prepare_transfer().
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci-ring.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c
index bdf6b13..3cc303f 100644
--- a/drivers/usb/host/xhci-ring.c
+++ b
No need to calculate remainder and length_field, if there is
no data phase of a control transfer.
Signed-off-by: Lu Baolu
---
drivers/usb/host/xhci-ring.c | 20 ++--
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host
Hi,
On 01/05/2017 02:12 AM, Andy Shevchenko wrote:
> On Wed, Jan 4, 2017 at 3:51 AM, Lu Baolu wrote:
>> Remove the unnecessary return line in xhci_pci_setup().
>>
>> Signed-off-by: Lu Baolu
>> ---
>> drivers/usb/host/xhci-pci.c | 2 --
>> 1 file cha
d-off-by: Lu Baolu
---
drivers/usb/host/xhci.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c
index 0c8deb9..d887e09 100644
--- a/drivers/usb/host/xhci.c
+++ b/drivers/usb/host/xhci.c
@@ -4191,7 +4191,
Hi Mathias,
On 01/12/2017 04:53 PM, Lu Baolu wrote:
> Xhci spec requires in section 4.23.5.1.1.1 that the RWE bit of USB2
> PORTPMSC register should only set for remote wakeup capble devices.
>
> This was suggested by Mathias in the following discussion thread.
> http://marc.info
B_CYCLE ? 'C' : 'c');
> + break;
> + case TRB_STOP_RING:
> + sprintf(str, "%s: slot %d sp %d ep %d flags %c",
> + xhci_trb_type_string(TRB_FIELD_TO_TYPE(field3)),
> + TRB_TO_SL
gt; +++ b/drivers/usb/host/xhci.c
> @@ -1383,6 +1383,8 @@ int xhci_urb_enqueue(struct usb_hcd *hcd, struct urb
> *urb, gfp_t mem_flags)
> urb_priv->td_cnt = 0;
> urb->hcpriv = urb_priv;
>
> + trace_xhci_urb_enqueue(urb);
> +
> if (usb_endpoint_xf
Hi,
On 01/16/2017 03:03 PM, Felipe Balbi wrote:
> Hi,
>
> Lu Baolu writes:
>> On 12/29/2016 07:01 PM, Felipe Balbi wrote:
>>> instead of having a tracer that can only trace command completions,
>>> let's promote this tracer so it can trace and decode any TRB
m + 1));
> ),
> - TP_printk("\nctx_64=%d, ctx_type=%u, ctx_dma=@%llx, ctx_va=@%p",
> + TP_printk("ctx_64=%d, ctx_type=%u, ctx_dma=@%llx, ctx_va=@%p",
> __entry->ctx_64, __entry->ctx_type,
> (unsigned long
t the same time.
> +
> DECLARE_EVENT_CLASS(xhci_log_urb,
> TP_PROTO(struct urb *urb),
> TP_ARGS(urb),
> diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c
> index c0f3670e5a51..e5f095b276fc 100644
> --- a/drivers/usb/host/xhci.c
> +++ b/drivers/usb/host/xh
Hi,
On 01/16/2017 04:55 PM, Felipe Balbi wrote:
> Hi,
>
> Lu Baolu writes:
>>>>> + __entry->type = ring->type;
>>>>> + __entry->field0 = le32_to_cpu(trb->field[0]);
>>>>> + __entry->field1 = le32_to_
Hi,
On 01/16/2017 04:59 PM, Felipe Balbi wrote:
> Hi,
>
> Lu Baolu writes:
>> Hi,
>>
>> On 12/29/2016 07:01 PM, Felipe Balbi wrote:
>>> These three new tracers will help us tie TRBs into URBs by *also*
>>> looking into URB lifetime.
>>
1 - 100 of 653 matches
Mail list logo