RE: Not enough resource for old configuration after USB bus reset

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

 



linux-usb-owner@xxxxxxxxxxxxxxx wrote:
> On Mon, Feb 25, 2013 at 01:42:44PM +0200, Felipe Balbi wrote:
>> HI,
>> 
>> On Mon, Feb 25, 2013 at 07:33:23PM +0800, Soar Hung wrote:
>>>> What's the actual issue here ? Can you explain to me Sarah ?
>>>> This may be a known issue regarding this particular host
>>>> controller and if it is, there might already be workarounds
>>>> available. 
>>> 
>>> I copy the previous content and try to make it more clear.
>>> 
>>> When calling usb_reset_and_verify_device, hcd issue a reset command.
>>> The reset device command make the endpoint state disabled without
>>> releaseing the bandwidth. 
>>> 
>>> After reset is done, the HCD try to reconfigure the device to
>>> previous active config by usb_hcd_alloc_bandwidth.
>>> The HCD does such thing by modifying drop and add flag in input
>>> context, and issue configure endpoint command to comoplete the
>>> operation. 
>>> 
>>> When executing drop_endpoint, the endpoint is already in the
>>> disabled state. This behavior is correct according to the spec. And
>>> the HC will not evaluate drop flag of disable endpoint,too.
>> 

>>> As a result, the HC can not drop the endpoint to release the
>>> bandwidth.
>> 
>> But if the endpoint is already dropped, why hasn't bandwidth
>> allocation being released too ? Sarah ?
> 
> I think we're talking past each other. :)  Soar, what
> bandwidth allocation resources are you talking about?  In the
> xHC hardware, or in the xHCI driver?  I've been talking about
> resources in the hardware only, but I want to confirm we're talking
> about the same thing. 
> 
As my understading, the bandwidth is managed by xHC(hardware),
The HCD(driver) only use xHCI input context and command to tell xHC do something.

> As I understand it, the Reset Device command should drop all
> bandwidth allocated within the xHC hardware.  Then we go back
> and re-add the endpoints, setting only the add flag in the
> input context.  As Soar mentioned, this is spec-compliant,
> but the host eventually gives an out-of-bandwidth completion
> code for the Configure Endpoint command.
> 

Now I understand why this is QUIRK not a fix.
Spec 4.6.11 says the xHC shall release bandwidth automatically when doing reset device command.


Best regards,
Soar
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


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

  Powered by Linux