All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] usb: xhci: Renesas uPD720202 needs short TX quirk
@ 2017-08-18  4:20 Kai-Heng Feng
  2017-08-18  7:22 ` Felipe Balbi
  0 siblings, 1 reply; 5+ messages in thread
From: Kai-Heng Feng @ 2017-08-18  4:20 UTC (permalink / raw)
  To: mathias.nyman; +Cc: gregkh, linux-usb, linux-kernel, Kai-Heng Feng

When plugging Logitech C920 webcam, warning messages filled up dmesg:
[77117.655018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?
[77117.659018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?
[77122.622952] handle_tx_event: 541 callbacks suppressed

No more warning messages with XHCI_TRUST_TX_LENGTH applied.

BugLink: https://bugs.launchpad.net/bugs/1710548
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
---
 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 8071c8fdd15e..8566b43e19ba 100644
--- a/drivers/usb/host/xhci-pci.c
+++ b/drivers/usb/host/xhci-pci.c
@@ -202,8 +202,10 @@ static void xhci_pci_quirks(struct device *dev, struct xhci_hcd *xhci)
 		xhci->quirks |= XHCI_BROKEN_STREAMS;
 	}
 	if (pdev->vendor == PCI_VENDOR_ID_RENESAS &&
-			pdev->device == 0x0015)
+			pdev->device == 0x0015) {
 		xhci->quirks |= XHCI_RESET_ON_RESUME;
+		xhci->quirks |= XHCI_TRUST_TX_LENGTH;
+	}
 	if (pdev->vendor == PCI_VENDOR_ID_VIA)
 		xhci->quirks |= XHCI_RESET_ON_RESUME;
 
-- 
2.14.1

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] usb: xhci: Renesas uPD720202 needs short TX quirk
  2017-08-18  4:20 [PATCH] usb: xhci: Renesas uPD720202 needs short TX quirk Kai-Heng Feng
@ 2017-08-18  7:22 ` Felipe Balbi
  2017-08-18  8:06   ` Kai-Heng Feng
  0 siblings, 1 reply; 5+ messages in thread
From: Felipe Balbi @ 2017-08-18  7:22 UTC (permalink / raw)
  To: Kai-Heng Feng, mathias.nyman
  Cc: gregkh, linux-usb, linux-kernel, Kai-Heng Feng

[-- Attachment #1: Type: text/plain, Size: 1532 bytes --]


hi,

Kai-Heng Feng <kai.heng.feng@canonical.com> writes:
> When plugging Logitech C920 webcam, warning messages filled up dmesg:
> [77117.655018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?
> [77117.659018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?

have you confirmed this is needed for this controller? Anybody from
Renesas has confirmed it? Do you have an errata document to refer to?

> [77122.622952] handle_tx_event: 541 callbacks suppressed
>
> No more warning messages with XHCI_TRUST_TX_LENGTH applied.
>
> BugLink: https://bugs.launchpad.net/bugs/1710548
> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> ---
>  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 8071c8fdd15e..8566b43e19ba 100644
> --- a/drivers/usb/host/xhci-pci.c
> +++ b/drivers/usb/host/xhci-pci.c
> @@ -202,8 +202,10 @@ static void xhci_pci_quirks(struct device *dev, struct xhci_hcd *xhci)
>  		xhci->quirks |= XHCI_BROKEN_STREAMS;
>  	}
>  	if (pdev->vendor == PCI_VENDOR_ID_RENESAS &&
> -			pdev->device == 0x0015)
> +			pdev->device == 0x0015) {

unnecessary

>  		xhci->quirks |= XHCI_RESET_ON_RESUME;
> +		xhci->quirks |= XHCI_TRUST_TX_LENGTH;

		xhci->quirks |= XHCI_RESET_ON_RESUME |
                		XHCI_TRUST_TX_LENGTH;

> +	}

unnecessary

-- 
balbi

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] usb: xhci: Renesas uPD720202 needs short TX quirk
  2017-08-18  7:22 ` Felipe Balbi
@ 2017-08-18  8:06   ` Kai-Heng Feng
  2017-08-18  8:10     ` Felipe Balbi
  0 siblings, 1 reply; 5+ messages in thread
From: Kai-Heng Feng @ 2017-08-18  8:06 UTC (permalink / raw)
  To: Felipe Balbi; +Cc: mathias.nyman, gregkh, USB list, LKML

Hi,

On Fri, Aug 18, 2017 at 3:22 PM, Felipe Balbi
<felipe.balbi@linux.intel.com> wrote:
>
> hi,
>
> Kai-Heng Feng <kai.heng.feng@canonical.com> writes:
>> When plugging Logitech C920 webcam, warning messages filled up dmesg:
>> [77117.655018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?
>> [77117.659018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?
>
> have you confirmed this is needed for this controller?
I just found commit d2f48f05cd2a2 ("usb: xhci: ASMedia ASM1042A
chipset need shorts TX quirk") and did the same thing for this
controller.

> Anybody from Renesas has confirmed it?
No, it's a user reported problem, please check the bug report in the link.

> Do you have an errata document to refer to?
No. Probably need Renesas guy to provide it.

>
>> [77122.622952] handle_tx_event: 541 callbacks suppressed
>>
>> No more warning messages with XHCI_TRUST_TX_LENGTH applied.
>>
>> BugLink: https://bugs.launchpad.net/bugs/1710548
>> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
>> ---
>>  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 8071c8fdd15e..8566b43e19ba 100644
>> --- a/drivers/usb/host/xhci-pci.c
>> +++ b/drivers/usb/host/xhci-pci.c
>> @@ -202,8 +202,10 @@ static void xhci_pci_quirks(struct device *dev, struct xhci_hcd *xhci)
>>               xhci->quirks |= XHCI_BROKEN_STREAMS;
>>       }
>>       if (pdev->vendor == PCI_VENDOR_ID_RENESAS &&
>> -                     pdev->device == 0x0015)
>> +                     pdev->device == 0x0015) {
>
> unnecessary
>
>>               xhci->quirks |= XHCI_RESET_ON_RESUME;
>> +             xhci->quirks |= XHCI_TRUST_TX_LENGTH;
>
>                 xhci->quirks |= XHCI_RESET_ON_RESUME |
>                                 XHCI_TRUST_TX_LENGTH;
>
>> +     }
>
> unnecessary

Do you mean that this quirk just hide the warning, it doesn't fix the
root cause?

>
> --
> balbi

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] usb: xhci: Renesas uPD720202 needs short TX quirk
  2017-08-18  8:06   ` Kai-Heng Feng
@ 2017-08-18  8:10     ` Felipe Balbi
  2017-09-06 16:23       ` Yoshihiro Shimoda
  0 siblings, 1 reply; 5+ messages in thread
From: Felipe Balbi @ 2017-08-18  8:10 UTC (permalink / raw)
  To: Kai-Heng Feng, Yoshihiro Shimoda; +Cc: mathias.nyman, gregkh, USB list, LKML


Hi,

Kai-Heng Feng <kai.heng.feng@canonical.com> writes:
>>> When plugging Logitech C920 webcam, warning messages filled up dmesg:
>>> [77117.655018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?
>>> [77117.659018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?
>>
>> have you confirmed this is needed for this controller?
> I just found commit d2f48f05cd2a2 ("usb: xhci: ASMedia ASM1042A
> chipset need shorts TX quirk") and did the same thing for this
> controller.
>
>> Anybody from Renesas has confirmed it?
> No, it's a user reported problem, please check the bug report in the link.
>
>> Do you have an errata document to refer to?
> No. Probably need Renesas guy to provide it.

or confirm it. Yoshihiro, do you know if this is needed?

>>> [77122.622952] handle_tx_event: 541 callbacks suppressed
>>>
>>> No more warning messages with XHCI_TRUST_TX_LENGTH applied.
>>>
>>> BugLink: https://bugs.launchpad.net/bugs/1710548
>>> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
>>> ---
>>>  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 8071c8fdd15e..8566b43e19ba 100644
>>> --- a/drivers/usb/host/xhci-pci.c
>>> +++ b/drivers/usb/host/xhci-pci.c
>>> @@ -202,8 +202,10 @@ static void xhci_pci_quirks(struct device *dev, struct xhci_hcd *xhci)
>>>               xhci->quirks |= XHCI_BROKEN_STREAMS;
>>>       }
>>>       if (pdev->vendor == PCI_VENDOR_ID_RENESAS &&
>>> -                     pdev->device == 0x0015)
>>> +                     pdev->device == 0x0015) {
>>
>> unnecessary
>>
>>>               xhci->quirks |= XHCI_RESET_ON_RESUME;
>>> +             xhci->quirks |= XHCI_TRUST_TX_LENGTH;
>>
>>                 xhci->quirks |= XHCI_RESET_ON_RESUME |
>>                                 XHCI_TRUST_TX_LENGTH;
>>
>>> +     }
>>
>> unnecessary
>
> Do you mean that this quirk just hide the warning, it doesn't fix the
> root cause?

no, I meant that you need to add {} if you make a single statement out
of the quirks.

-- 
balbi

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: [PATCH] usb: xhci: Renesas uPD720202 needs short TX quirk
  2017-08-18  8:10     ` Felipe Balbi
@ 2017-09-06 16:23       ` Yoshihiro Shimoda
  0 siblings, 0 replies; 5+ messages in thread
From: Yoshihiro Shimoda @ 2017-09-06 16:23 UTC (permalink / raw)
  To: Felipe Balbi, Kai-Heng Feng; +Cc: mathias.nyman, gregkh, USB list, LKML

Hi,

Sorry, I missed this email...

> -----Original Message-----
> From: Felipe Balbi
> Sent: Friday, August 18, 2017 10:10 AM
> 
> Hi,
> 
> Kai-Heng Feng <kai.heng.feng@canonical.com> writes:
> >>> When plugging Logitech C920 webcam, warning messages filled up dmesg:
> >>> [77117.655018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?
> >>> [77117.659018] xhci_hcd 0000:0c:00.0: WARN Successful completion on short TX: needs XHCI_TRUST_TX_LENGTH quirk?
> >>
> >> have you confirmed this is needed for this controller?
> > I just found commit d2f48f05cd2a2 ("usb: xhci: ASMedia ASM1042A
> > chipset need shorts TX quirk") and did the same thing for this
> > controller.
> >
> >> Anybody from Renesas has confirmed it?
> > No, it's a user reported problem, please check the bug report in the link.
> >
> >> Do you have an errata document to refer to?
> > No. Probably need Renesas guy to provide it.
> 
> or confirm it. Yoshihiro, do you know if this is needed?

I know. This behavior is the same as R-Car H3. But, I didn't find any errata
documents. So, I'm asking HW guys why this environment causes it. However,
I don't get any feedback yet. I think we need any reason for applying such a quirk.

Best regards,
Yoshihiro Shimoda

> >>> [77122.622952] handle_tx_event: 541 callbacks suppressed
> >>>
> >>> No more warning messages with XHCI_TRUST_TX_LENGTH applied.
> >>>
> >>> BugLink: https://bugs.launchpad.net/bugs/1710548
> >>> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> >>> ---
> >>>  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 8071c8fdd15e..8566b43e19ba 100644
> >>> --- a/drivers/usb/host/xhci-pci.c
> >>> +++ b/drivers/usb/host/xhci-pci.c
> >>> @@ -202,8 +202,10 @@ static void xhci_pci_quirks(struct device *dev, struct xhci_hcd *xhci)
> >>>               xhci->quirks |= XHCI_BROKEN_STREAMS;
> >>>       }
> >>>       if (pdev->vendor == PCI_VENDOR_ID_RENESAS &&
> >>> -                     pdev->device == 0x0015)
> >>> +                     pdev->device == 0x0015) {
> >>
> >> unnecessary
> >>
> >>>               xhci->quirks |= XHCI_RESET_ON_RESUME;
> >>> +             xhci->quirks |= XHCI_TRUST_TX_LENGTH;
> >>
> >>                 xhci->quirks |= XHCI_RESET_ON_RESUME |
> >>                                 XHCI_TRUST_TX_LENGTH;
> >>
> >>> +     }
> >>
> >> unnecessary
> >
> > Do you mean that this quirk just hide the warning, it doesn't fix the
> > root cause?
> 
> no, I meant that you need to add {} if you make a single statement out
> of the quirks.
> 
> --
> balbi

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2017-09-06 16:24 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-18  4:20 [PATCH] usb: xhci: Renesas uPD720202 needs short TX quirk Kai-Heng Feng
2017-08-18  7:22 ` Felipe Balbi
2017-08-18  8:06   ` Kai-Heng Feng
2017-08-18  8:10     ` Felipe Balbi
2017-09-06 16:23       ` Yoshihiro Shimoda

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.