Hello Alan, On Thursday 10 February 2005 16:41, Alan Stern wrote: > We've discussed in the past that the notion of unlinking a single URB > is unnatural. When a driver has multiple URBs queued for an endpoint > it will always want to unlink all of them together; it will never > want to unlink only some -- that wouldn't make any sense.
> The fly in the ointment is endpoint-0. It's different from all the > other endpoints because any other endpoint will be managed solely by > the device's driver. By contrast, multiple drivers are allowed to > send URBs to ep0. When one of them unlinks an URB it should not > interfere with any of the others. > > Now consider this. Normally a driver will want to send only one URB > to ep0 at a time, it won't try to queue a lot of URBs. My driver (auerswald) tries so send more than one URB to ep0 at a time! But - I have learned that this does not work reliable, especially with the UHCI hardware. This is mostly because of two facts: a) If there is a spike on the line, the retry mechanism of the host controler is so fast that the retry has no effect - the spike is much longer than the time needed for the 3 retries. So I think we will get a more reliable solution if the host controler will get only one control URB at a time, with retries = 0, and a timeout logik in software in the core. b) IMHO, the endpoint queues are lacking an important feature: the driver is not able to modify and control the queue. Restarting/Stopping and inserting an URB in front of the queue are necessary to do a good job for error recovery. Another lacking feature is un-stalling an endpoint from inside the callback function.... before we can attempt to retry the packet.... I have several installations with 24/7 runtime, and have spent far more time on error recovery as on writing the driver.... IMHO it is OK to unlink all URBs of an endpoint at once (but not for ep0), but this function should not be called unlink_urb() any more... Any comments? Wolfgang Muees ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ [email protected] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
