Re: [PATCH v2 6/7] usb: xhci: Workaround lost disconnect port status

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Mathias Nyman wrote:
> On 10.4.2021 3.47, Thinh Nguyen wrote:
>> If an eSS device with active periodic transfers is disconnected from the
>> DWC_usb31 (v1.90a and prior) host controller at root port, the host
>> controller may not detect a disconnection. By active transfers, it
>> means that the endpoint is not in flow control, and there are active
>> Transfer Descriptors available for the host to initiate transfers to the
>> endpoint. This issue can occur if the endpoint periodic interval is in
>> 2ms, 4ms, or 8ms.
>>
>> In addition, the host controller will not be able to detect a new device
>> connection while the disconnection is not processed. The controller will
>> set the link state of the affected port to eSS_INACTIVE.
>>
>> To workaround this, have the xHCI driver polls for the eSS root port
>> status every 2 seconds. If eSS_INACTIVE state is detected, initiate a
>> fake connection change to stop all the active endpoints and start
>> polling for new connection change.
> 
> 
> If this only happens with active periodic transfers can we skip the polling
> and check port link state in the transfer error event handling?
> 
> Like in the previous case there the periodic device was behind a hub.
> 

No, this occurs with an application with interrupt endpoint (but also
affects isoc). We may not get a transfer completion event to notify to
check for port link state. I hope this change is not too intrusive since
we can reuse a timer polling for port status.

Thanks,
Thinh





[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux