Re: dwc2 - ChHltd set, but reason is unknown

2017-10-20 Thread Minas Harutyunyan
On 10/19/2017 2:22 PM, Anders Montonen wrote:
> On Thu, 19 Oct 2017, Minas Harutyunyan wrote:
> 
>> Could you please apply this patch.
>> If you confirm that this patch fix your issue with "Transaction Error"
>> and " ChHltd set, but reason is unknown" I'll submit to LKML as final patch.
>>
>> diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c index
>> f4ef159b538e..7da22152df68 100644
>> --- a/drivers/usb/dwc2/hcd.c
>> +++ b/drivers/usb/dwc2/hcd.c
>> @@ -331,6 +331,9 @@ static void dwc2_gusbcfg_init(struct dwc2_hsotg *hsotg)
>>  usbcfg = dwc2_readl(hsotg->regs + GUSBCFG);
>>  usbcfg &= ~(GUSBCFG_HNPCAP | GUSBCFG_SRPCAP);
>>
>> +   /* Set HS/FS Timeout Calibration */
>> +   usbcfg |= GUSBCFG_TOUTCAL(7);
>> +
>>  switch (hsotg->hw_params.op_mode) {
>>  case GHWCFG2_OP_MODE_HNP_SRP_CAPABLE:
>>  if (hsotg->params.otg_cap ==
> 
> Hi Minas,
> 
> The patch clearly reduced the amount of errors logged, but did not fully
> fix the problem. This was with kernel 4.9.39, I can also try with a 4.13
> kernel.
> 
> Regards,
> Anders Montonen
> 
Hi Anders,

In addition to above patch please apply new one:


@@ -2311,10 +2314,17 @@ static int dwc2_core_init(struct dwc2_hsotg 
*hsotg, bool initial_setup)
   */
  static void dwc2_core_host_init(struct dwc2_hsotg *hsotg)
  {
-   u32 hcfg, hfir, otgctl;
+   u32 hcfg, hfir, otgctl, usbcfg, trdtrim;

 dev_dbg(hsotg->dev, "%s(%p)\n", __func__, hsotg);

+   /* Set USBTrdTim value */
+   usbcfg = dwc2_readl(hsotg->regs + GUSBCFG);
+   usbcfg &= ~GUSBCFG_USBTRDTIM_MASK;
+   trdtrim = (hsotg->phyif == GUSBCFG_PHYIF8) ? 9 : 5;
+   usbcfg |= (trdtrim << GUSBCFG_USBTRDTIM_SHIFT);
+   dwc2_writel(usbcfg, hsotg->regs + GUSBCFG);
+
 /* Restart the Phy Clock */
 dwc2_writel(0, hsotg->regs + PCGCTL);


Thanks,
Minas

--
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: dwc2 - ChHltd set, but reason is unknown

2017-10-19 Thread Anders Montonen

On Thu, 19 Oct 2017, Minas Harutyunyan wrote:


Could you please apply this patch.
If you confirm that this patch fix your issue with "Transaction Error" 
and " ChHltd set, but reason is unknown" I'll submit to LKML as final patch.


diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c index 
f4ef159b538e..7da22152df68 100644

--- a/drivers/usb/dwc2/hcd.c
+++ b/drivers/usb/dwc2/hcd.c
@@ -331,6 +331,9 @@ static void dwc2_gusbcfg_init(struct dwc2_hsotg *hsotg)
usbcfg = dwc2_readl(hsotg->regs + GUSBCFG);
usbcfg &= ~(GUSBCFG_HNPCAP | GUSBCFG_SRPCAP);

+   /* Set HS/FS Timeout Calibration */
+   usbcfg |= GUSBCFG_TOUTCAL(7);
+
switch (hsotg->hw_params.op_mode) {
case GHWCFG2_OP_MODE_HNP_SRP_CAPABLE:
if (hsotg->params.otg_cap ==


Hi Minas,

The patch clearly reduced the amount of errors logged, but did not fully 
fix the problem. This was with kernel 4.9.39, I can also try with a 4.13 
kernel.


Regards,
Anders Montonen
--
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: dwc2 - ChHltd set, but reason is unknown

2017-10-19 Thread Minas Harutyunyan
On 10/16/2017 7:16 PM, Anders Montonen wrote:
> On Mon, 16 Oct 2017, Minas Harutyunyan wrote:
>> On 10/16/2017 12:12 PM, Anders Montonen wrote:
>>> On Mon, 16 Oct 2017, Minas Harutyunyan wrote:
 On 10/10/2017 4:35 PM, Anders Montonen wrote:
> On Mon, 9 Oct 2017, Minas Harutyunyan wrote:
>> On 10/9/2017 5:15 PM, Anders Montonen wrote:
>
>>> We have a custom Altera Cyclone V SoCFPGA board, where connecting a
>>> particular brand of USB memory sticks produces and enless stream of
>>> console errors messages until it is removed from the system.
>> Could you please provide log with enabled VERBOSE debug messages.
> I uploaded a log to 
> .
 Hi Anders,
 1. Lot of "Transaction Error--" seen in log related to mentioned by you
 mass storage device (addr=4 and addr=5).
 2. In log seen 2 additional devices with addresses 2 and 3 (Control
 transfers). Could you please elaborate what kind of devices? Did you
 connected any hub to dwc2 root hub? Or any internal to board hub's
 connected to dwc2?
>>> Thanks for taking a look at this. As I mentioned in the original post, the
>>> dwc2 root hub is connected to a Microchip LAN9152 combined USB
>>> hub/Ethernet MAC. This is a fixed (PCB trace) connection.
>>> 
>> Hi,
>> Could you please also send register dump.
> 
> I made two dumps, before inserting the USB stick and with the memory stick
> inserted.
> 
> Before:
> GOTGCTL = 0x002c0001
> GOTGINT = 0x
> GAHBCFG = 0x0027
> GUSBCFG = 0x21101710
> GRSTCTL = 0x8000
> GINTSTS = 0x04200021
> GINTMSK = 0xf300080e
> GRXSTSR = 0x3ea8c000
> GRXSTSP = 0x3ea8c000
> GRXFSIZ = 0x0214
> GNPTXFSIZ = 0x01000214
> GNPTXSTS = 0x08080100
> GI2CCTL = 0x
> GPVNDCTL = 0x
> GGPIO = 0x
> GUID = 0x12345678
> GSNPSID = 0x4f54293a
> GHWCFG1 = 0x
> GHWCFG2 = 0x238ffc90
> GHWCFG3 = 0x1f8002e8
> GHWCFG4 = 0xfe0f0020
> GLPMCFG = 0x
> GPWRDN = 0x
> GDFIFOCFG = 0x06142000
> ADPCTL = 0x
> HPTXFSIZ = 0x03000314
> DPTXFSIZN(1) = 0x03000314
> DPTXFSIZN(2) = 0x03000314
> DPTXFSIZN(3) = 0x03000314
> DPTXFSIZN(4) = 0x03000314
> DPTXFSIZN(5) = 0x03000314
> DPTXFSIZN(6) = 0x03000314
> DPTXFSIZN(7) = 0x03000314
> DPTXFSIZN(8) = 0x03000314
> DPTXFSIZN(9) = 0x03000314
> DPTXFSIZN(10) = 0x03000314
> DPTXFSIZN(11) = 0x03000314
> DPTXFSIZN(12) = 0x03000314
> DPTXFSIZN(13) = 0x03000314
> DPTXFSIZN(14) = 0x03000314
> DPTXFSIZN(15) = 0x03000314
> DCFG = 0x
> DCTL = 0x
> DSTS = 0x00018c02
> DIEPMSK = 0x
> DOEPMSK = 0x
> DAINT = 0x
> DAINTMSK = 0x
> DTKNQR1 = 0x
> DTKNQR2 = 0x
> DTKNQR3 = 0x0c100020
> DTKNQR4 = 0x
> DVBUSDIS = 0x00011d4b
> DVBUSPULSE = 0x05b8
> DIEPCTL(0) = 0x00d00040
> DIEPCTL(1) = 0x00d08040
> DIEPCTL(2) = 0x00d00040
> DIEPCTL(3) = 0x00d00040
> DIEPCTL(4) = 0x00d08040
> DIEPCTL(5) = 0x00d00040
> DIEPCTL(6) = 0x00d00040
> DIEPCTL(7) = 0x00d00040
> DIEPCTL(8) = 0x00dc9810
> DIEPCTL(9) = 0x00d00040
> DIEPCTL(10) = 0x00d08040
> DIEPCTL(11) = 0x00d00040
> DIEPCTL(12) = 0x00dc9810
> DIEPCTL(13) = 0x00d00040
> DIEPCTL(14) = 0x00d08040
> DIEPCTL(15) = 0x20dc9810
> DOEPCTL(0) = 0x00d00040
> DOEPCTL(1) = 0x00d08040
> DOEPCTL(2) = 0x00d00040
> DOEPCTL(3) = 0x00d00040
> DOEPCTL(4) = 0x00d08040
> DOEPCTL(5) = 0x00d00040
> DOEPCTL(6) = 0x00d00040
> DOEPCTL(7) = 0x00d00040
> DOEPCTL(8) = 0x00dc9810
> DOEPCTL(9) = 0x00d00040
> DOEPCTL(10) = 0x00d08040
> DOEPCTL(11) = 0x00d00040
> DOEPCTL(12) = 0x00dc9810
> DOEPCTL(13) = 0x00d00040
> DOEPCTL(14) = 0x00d08040
> DOEPCTL(15) = 0x20dc9810
> DIEPINT(0) = 0x0080
> DIEPINT(1) = 0x
> DIEPINT(2) = 0x
> DIEPINT(3) = 0x
> DIEPINT(4) = 0x
> DIEPINT(5) = 0x
> DIEPINT(6) = 0x
> DIEPINT(7) = 0x
> DIEPINT(8) = 0x0002
> DIEPINT(9) = 0x
> DIEPINT(10) = 0x
> DIEPINT(11) = 0x
> DIEPINT(12) = 0x
> DIEPINT(13) = 0x
> DIEPINT(14) = 0x
> DIEPINT(15) = 0x
> DOEPINT(0) = 0x
> DOEPINT(1) = 0x
> DOEPINT(2) = 0x
> DOEPINT(3) = 0x
> DOEPINT(4) = 0x
> DOEPINT(5) = 0x
> DOEPINT(6) = 0x
> DOEPINT(7) = 0x
> DOEPINT(8) = 0x0002
> DOEPINT(9) = 0x
> DOEPINT(10) = 0x
> DOEPINT(11) = 0x
> DOEPINT(12) = 0x
> DOEPINT(13) = 0x
> DOEPINT(14) = 0x
> DOEPINT(15) = 0x
> DIEPTSIZ(0) = 0x0004
> DIEPTSIZ(1) = 

Re: dwc2 - ChHltd set, but reason is unknown

2017-10-16 Thread Anders Montonen

On Mon, 16 Oct 2017, Minas Harutyunyan wrote:

On 10/16/2017 12:12 PM, Anders Montonen wrote:

On Mon, 16 Oct 2017, Minas Harutyunyan wrote:

On 10/10/2017 4:35 PM, Anders Montonen wrote:

On Mon, 9 Oct 2017, Minas Harutyunyan wrote:

On 10/9/2017 5:15 PM, Anders Montonen wrote:



We have a custom Altera Cyclone V SoCFPGA board, where connecting a
particular brand of USB memory sticks produces and enless stream of
console errors messages until it is removed from the system.

Could you please provide log with enabled VERBOSE debug messages.

I uploaded a log to 
.

Hi Anders,
1. Lot of "Transaction Error--" seen in log related to mentioned by you
mass storage device (addr=4 and addr=5).
2. In log seen 2 additional devices with addresses 2 and 3 (Control
transfers). Could you please elaborate what kind of devices? Did you
connected any hub to dwc2 root hub? Or any internal to board hub's
connected to dwc2?

Thanks for taking a look at this. As I mentioned in the original post, the
dwc2 root hub is connected to a Microchip LAN9152 combined USB
hub/Ethernet MAC. This is a fixed (PCB trace) connection.


Hi,
Could you please also send register dump.


I made two dumps, before inserting the USB stick and with the memory stick 
inserted.


Before:
GOTGCTL = 0x002c0001
GOTGINT = 0x
GAHBCFG = 0x0027
GUSBCFG = 0x21101710
GRSTCTL = 0x8000
GINTSTS = 0x04200021
GINTMSK = 0xf300080e
GRXSTSR = 0x3ea8c000
GRXSTSP = 0x3ea8c000
GRXFSIZ = 0x0214
GNPTXFSIZ = 0x01000214
GNPTXSTS = 0x08080100
GI2CCTL = 0x
GPVNDCTL = 0x
GGPIO = 0x
GUID = 0x12345678
GSNPSID = 0x4f54293a
GHWCFG1 = 0x
GHWCFG2 = 0x238ffc90
GHWCFG3 = 0x1f8002e8
GHWCFG4 = 0xfe0f0020
GLPMCFG = 0x
GPWRDN = 0x
GDFIFOCFG = 0x06142000
ADPCTL = 0x
HPTXFSIZ = 0x03000314
DPTXFSIZN(1) = 0x03000314
DPTXFSIZN(2) = 0x03000314
DPTXFSIZN(3) = 0x03000314
DPTXFSIZN(4) = 0x03000314
DPTXFSIZN(5) = 0x03000314
DPTXFSIZN(6) = 0x03000314
DPTXFSIZN(7) = 0x03000314
DPTXFSIZN(8) = 0x03000314
DPTXFSIZN(9) = 0x03000314
DPTXFSIZN(10) = 0x03000314
DPTXFSIZN(11) = 0x03000314
DPTXFSIZN(12) = 0x03000314
DPTXFSIZN(13) = 0x03000314
DPTXFSIZN(14) = 0x03000314
DPTXFSIZN(15) = 0x03000314
DCFG = 0x
DCTL = 0x
DSTS = 0x00018c02
DIEPMSK = 0x
DOEPMSK = 0x
DAINT = 0x
DAINTMSK = 0x
DTKNQR1 = 0x
DTKNQR2 = 0x
DTKNQR3 = 0x0c100020
DTKNQR4 = 0x
DVBUSDIS = 0x00011d4b
DVBUSPULSE = 0x05b8
DIEPCTL(0) = 0x00d00040
DIEPCTL(1) = 0x00d08040
DIEPCTL(2) = 0x00d00040
DIEPCTL(3) = 0x00d00040
DIEPCTL(4) = 0x00d08040
DIEPCTL(5) = 0x00d00040
DIEPCTL(6) = 0x00d00040
DIEPCTL(7) = 0x00d00040
DIEPCTL(8) = 0x00dc9810
DIEPCTL(9) = 0x00d00040
DIEPCTL(10) = 0x00d08040
DIEPCTL(11) = 0x00d00040
DIEPCTL(12) = 0x00dc9810
DIEPCTL(13) = 0x00d00040
DIEPCTL(14) = 0x00d08040
DIEPCTL(15) = 0x20dc9810
DOEPCTL(0) = 0x00d00040
DOEPCTL(1) = 0x00d08040
DOEPCTL(2) = 0x00d00040
DOEPCTL(3) = 0x00d00040
DOEPCTL(4) = 0x00d08040
DOEPCTL(5) = 0x00d00040
DOEPCTL(6) = 0x00d00040
DOEPCTL(7) = 0x00d00040
DOEPCTL(8) = 0x00dc9810
DOEPCTL(9) = 0x00d00040
DOEPCTL(10) = 0x00d08040
DOEPCTL(11) = 0x00d00040
DOEPCTL(12) = 0x00dc9810
DOEPCTL(13) = 0x00d00040
DOEPCTL(14) = 0x00d08040
DOEPCTL(15) = 0x20dc9810
DIEPINT(0) = 0x0080
DIEPINT(1) = 0x
DIEPINT(2) = 0x
DIEPINT(3) = 0x
DIEPINT(4) = 0x
DIEPINT(5) = 0x
DIEPINT(6) = 0x
DIEPINT(7) = 0x
DIEPINT(8) = 0x0002
DIEPINT(9) = 0x
DIEPINT(10) = 0x
DIEPINT(11) = 0x
DIEPINT(12) = 0x
DIEPINT(13) = 0x
DIEPINT(14) = 0x
DIEPINT(15) = 0x
DOEPINT(0) = 0x
DOEPINT(1) = 0x
DOEPINT(2) = 0x
DOEPINT(3) = 0x
DOEPINT(4) = 0x
DOEPINT(5) = 0x
DOEPINT(6) = 0x
DOEPINT(7) = 0x
DOEPINT(8) = 0x0002
DOEPINT(9) = 0x
DOEPINT(10) = 0x
DOEPINT(11) = 0x
DOEPINT(12) = 0x
DOEPINT(13) = 0x
DOEPINT(14) = 0x
DOEPINT(15) = 0x
DIEPTSIZ(0) = 0x0004
DIEPTSIZ(1) = 0x803c
DIEPTSIZ(2) = 0x
DIEPTSIZ(3) = 0x2008
DIEPTSIZ(4) = 0x803c
DIEPTSIZ(5) = 0x
DIEPTSIZ(6) = 0x
DIEPTSIZ(7) = 0x2008
DIEPTSIZ(8) = 0x80080010
DIEPTSIZ(9) = 0x2008
DIEPTSIZ(10) = 0x803c
DIEPTSIZ(11) = 0x
DIEPTSIZ(12) = 0x80080010
DIEPTSIZ(13) = 0x2008
DIEPTSIZ(14) = 0x8040
DIEPTSIZ(15) = 0x80080010
DOEPTSIZ(0) = 0x0004
DOEPTSIZ(1) = 

Re: dwc2 - ChHltd set, but reason is unknown

2017-10-16 Thread Minas Harutyunyan
On 10/16/2017 12:12 PM, Anders Montonen wrote:
> On Mon, 16 Oct 2017, Minas Harutyunyan wrote:
>> On 10/10/2017 4:35 PM, Anders Montonen wrote:
>>> On Mon, 9 Oct 2017, Minas Harutyunyan wrote:
 On 10/9/2017 5:15 PM, Anders Montonen wrote:
>>>
> We have a custom Altera Cyclone V SoCFPGA board, where connecting a
> particular brand of USB memory sticks produces and enless stream of
> console errors messages until it is removed from the system.
 Could you please provide log with enabled VERBOSE debug messages.
>>> I uploaded a log to 
>>> .
>> Hi Anders,
>> 1. Lot of "Transaction Error--" seen in log related to mentioned by you
>> mass storage device (addr=4 and addr=5).
>> 2. In log seen 2 additional devices with addresses 2 and 3 (Control
>> transfers). Could you please elaborate what kind of devices? Did you
>> connected any hub to dwc2 root hub? Or any internal to board hub's
>> connected to dwc2?
> 
> Hi,
> 
> Thanks for taking a look at this. As I mentioned in the original post, the
> dwc2 root hub is connected to a Microchip LAN9152 combined USB
> hub/Ethernet MAC. This is a fixed (PCB trace) connection.
> 
> 
> Regards,
> Anders Montonen
> 

Hi,
Could you please also send register dump.
Thanks,
Minas

--
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: dwc2 - ChHltd set, but reason is unknown

2017-10-16 Thread Anders Montonen

On Mon, 16 Oct 2017, Minas Harutyunyan wrote:

On 10/10/2017 4:35 PM, Anders Montonen wrote:

On Mon, 9 Oct 2017, Minas Harutyunyan wrote:

On 10/9/2017 5:15 PM, Anders Montonen wrote:



We have a custom Altera Cyclone V SoCFPGA board, where connecting a
particular brand of USB memory sticks produces and enless stream of
console errors messages until it is removed from the system.

Could you please provide log with enabled VERBOSE debug messages.

I uploaded a log to 
.

Hi Anders,
1. Lot of "Transaction Error--" seen in log related to mentioned by you
mass storage device (addr=4 and addr=5).
2. In log seen 2 additional devices with addresses 2 and 3 (Control
transfers). Could you please elaborate what kind of devices? Did you
connected any hub to dwc2 root hub? Or any internal to board hub's
connected to dwc2?


Hi,

Thanks for taking a look at this. As I mentioned in the original post, the 
dwc2 root hub is connected to a Microchip LAN9152 combined USB 
hub/Ethernet MAC. This is a fixed (PCB trace) connection.



Regards,
Anders Montonen
--
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: dwc2 - ChHltd set, but reason is unknown

2017-10-16 Thread Minas Harutyunyan
On 10/10/2017 4:35 PM, Anders Montonen wrote:
> Hi,
> 
> On Mon, 9 Oct 2017, Minas Harutyunyan wrote:
>> On 10/9/2017 5:15 PM, Anders Montonen wrote:
> 
>>> We have a custom Altera Cyclone V SoCFPGA board, where connecting a
>>> particular brand of USB memory sticks produces and enless stream of
>>> console errors messages until it is removed from the system.
>> Could you please provide log with enabled VERBOSE debug messages.
> 
> I uploaded a log to 
> .
> 
> Regards,
> Anders
> 
Hi Anders,
1. Lot of "Transaction Error--" seen in log related to mentioned by you 
mass storage device (addr=4 and addr=5).
2. In log seen 2 additional devices with addresses 2 and 3 (Control 
transfers). Could you please elaborate what kind of devices? Did you 
connected any hub to dwc2 root hub? Or any internal to board hub's 
connected to dwc2?
Thanks,
Minas


--
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: dwc2 - ChHltd set, but reason is unknown

2017-10-10 Thread Anders Montonen

Hi,

On Mon, 9 Oct 2017, Minas Harutyunyan wrote:

On 10/9/2017 5:15 PM, Anders Montonen wrote:



We have a custom Altera Cyclone V SoCFPGA board, where connecting a
particular brand of USB memory sticks produces and enless stream of
console errors messages until it is removed from the system.

Could you please provide log with enabled VERBOSE debug messages.


I uploaded a log to .

Regards,
Anders
--
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: dwc2 - ChHltd set, but reason is unknown

2017-10-09 Thread Minas Harutyunyan
Hi Anders,

On 10/9/2017 5:15 PM, Anders Montonen wrote:
> Hi,
>
> We have a custom Altera Cyclone V SoCFPGA board, where connecting a
> particular brand of USB memory sticks produces and enless stream of
> console errors messages until it is removed from the system.
>
> On the board, the SoC has a fixed connection to a Microchip LAN9152
> Ethernet/hub device with two downstream ports. Apart from this issue,
> every other device we have connected appears to work fine.
>
> The sticks are "Intenso Rainbow Line"-branded generic memory sticks using
> an Alcor Micro controller with VID/PID 0x058f/0x6387. The device
> descriptor has a bcdDevice field of 1.ff, but otherwise look valid. The
> sticks work fine on every other host I've tried, both Windows and desktop
> and embedded Linux (none with the dwc2 controller though). The stick also
> works with our board if I add another USB hub in between.
>
> I've reproduced this with kernels 4.9.39 and 4.13.5. The controller is
> configured as host-only. Any suggestions on how to proceed? I noticed that
> unusual_devs.h contained an entry for another device with the same VID/PID
> pair, but adding the same quirks for this device did not help.
>
> Regards,
> Anders Montonen
>
> usb 1-1.2: new high-speed USB device number 4 using dwc2
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 13 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_update_urb_state_abn(): trimming xfer length
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 5 - ChHltd set, but
> reason is unknown
> dwc2 ffb40000.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 11 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x00000002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 7 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x04600029
> usb 1-1.2: New USB device found, idVendor=058f, idProduct=6387
> usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
> usb 1-1.2: Product: Intenso Rainbow Line
> usb 1-1.2: Manufacturer: 6989
> usb 1-1.2: SerialNumber: 194D3F5F
> usb-storage 1-1.2:1.0: USB Mass Storage device detected
> scsi host0: usb-storage 1-1.2:1.0
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 5 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_update_urb_state_abn(): trimming xfer length
> dwc2 ffb4.usb: dwc2_update_urb_state(): trimming xfer length
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 11 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 12 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 1 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 15 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 14 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 11 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb40000.usb: dwc2_hc_chhltd_intr_dma: Channel 0 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 8 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x06600029
> dwc2 ffb40000.usb: dwc2_hc_chhltd_intr_dma: Channel 11 - ChHltd set, but
> reason is unknown
> dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 8 - ChHltd set, but
> reason is unknown
> dwc2 ffb40000.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 8 - ChHltd set, but
> reason is unknown
> dwc2 ffb40000.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 7 - ChHltd set, but
> reason is unknown
> dwc2 ffb40000.usb: hcint 0x00000002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 7 - ChHltd set, but
> reason is unknown
> dwc2 ffb40000.usb: hcint 0x0002, intsts 0x0469
> dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 5 - ChHltd set, but
> reason is unknown
> dwc2 ffb40000.usb: hcint 0x0002, i

dwc2 - ChHltd set, but reason is unknown

2017-10-09 Thread Anders Montonen

Hi,

We have a custom Altera Cyclone V SoCFPGA board, where connecting a 
particular brand of USB memory sticks produces and enless stream of 
console errors messages until it is removed from the system.


On the board, the SoC has a fixed connection to a Microchip LAN9152 
Ethernet/hub device with two downstream ports. Apart from this issue, 
every other device we have connected appears to work fine.


The sticks are "Intenso Rainbow Line"-branded generic memory sticks using 
an Alcor Micro controller with VID/PID 0x058f/0x6387. The device 
descriptor has a bcdDevice field of 1.ff, but otherwise look valid. The 
sticks work fine on every other host I've tried, both Windows and desktop 
and embedded Linux (none with the dwc2 controller though). The stick also 
works with our board if I add another USB hub in between.


I've reproduced this with kernels 4.9.39 and 4.13.5. The controller is 
configured as host-only. Any suggestions on how to proceed? I noticed that 
unusual_devs.h contained an entry for another device with the same VID/PID 
pair, but adding the same quirks for this device did not help.


Regards,
Anders Montonen

usb 1-1.2: new high-speed USB device number 4 using dwc2
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 13 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_update_urb_state_abn(): trimming xfer length
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 5 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 11 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 7 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x04600029
usb 1-1.2: New USB device found, idVendor=058f, idProduct=6387
usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-1.2: Product: Intenso Rainbow Line
usb 1-1.2: Manufacturer: 6989
usb 1-1.2: SerialNumber: 194D3F5F
usb-storage 1-1.2:1.0: USB Mass Storage device detected
scsi host0: usb-storage 1-1.2:1.0
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 5 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_update_urb_state_abn(): trimming xfer length
dwc2 ffb4.usb: dwc2_update_urb_state(): trimming xfer length
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 11 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 12 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 1 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 15 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 14 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 11 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 0 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 8 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x06600029
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 11 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 8 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 8 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 7 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 7 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 5 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 2 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 10 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ffb4.usb: dwc2_hc_chhltd_intr_dma: Channel 2 - ChHltd set, but 
reason is unknown

dwc2 ffb4.usb: hcint 0x0002, intsts 0x0469
dwc2 ff