Re: Low & full speed devices stop working after testusb run

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

 



Alan Stern wrote:
> On Thu, 14 Jul 2011, Sebastian Andrzej Siewior wrote:
>> Is it possible that since you defer the unlinking you don't interrupt
>> the internal HUB in the middle of whatever it is doing? Maybe the way
>> the transfers are unlinked is something that confuses the internal hub.
> 
> Ah -- that was the clue I didn't notice before.
> 
> When an URB is unlinked, and it is for a full-speed/low-speed device
> attached via a high-speed hub, it is necessary to send a
> Clear-TT-Buffer request to the hub.  The usbmon log did not show any
> such requests being sent.  Without them, the TT buffers in the hub
> never drain and it becomes impossible to send any more control or bulk
> messages to that device (or to any other device sharing the same TT).
> 
> Any high-speed host controller driver has to call
> usb_hub_clear_tt_buffer() when a bulk or control URB going through a TT
> is unlinked or fails for any reason other than -EPIPE or -EREMOTEIO.  
> Also, the driver must define a .clear_tt_buffer_complete callback in
> its hc_driver structure, and it must not send any transactions to the
> URB's endpoint until the callback tells it the TT buffer has been
> cleared.
> 
> This is all explained in section 11.17 of the USB-2 spec.  See 
> especially 11.17.5 for a discussion of Clear-TT-Buffer.
> 

Yep, that seems to do the trick! I need to clean up my code a bit but then
I'll get back with some patches. (Wow, this is the first time since I
started working on the isp1760 - in, what was it, september? - that I have
no known problems with it! *woohoo!* :)

While greping drivers/usb/host/ I noticed that the only other driver that 
call usb_hub_clear_tt_buffer() is the ehci driver (drivers/usb/host/ehci-q.c).
Are all the other supported host controllers <= USB1.1 controllers? 

-- 
Arvid Brodin
Enea Services Stockholm AB
--
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