O Oliver Neukum #
Message details and related content
Am Samstag, 21. April 2012, 02:37:35 schrieb Alan Stern:
On Fri, 20 Apr 2012, Oliver Neukum wrote:quoted
As I said, I'd very much appreciate sane semantics for usb_unlink_urb().Aside from the practicality issue of altering a large number of existing drivers, changing the semantics the way you want would be difficult because it would force the HCDs to defer some giveback operations to a bottom half or timer routine.
Or a work queue, which would have to be dedicated to avoid deadlocks
with storage.
Think about what happens if the URB being unlinked hasn't been presented to the hardware yet. Once it has been removed from the HCD's internal lists, there's no reason not to give it back right away. And there's no natural time to give it back later.
Now. The question is not when, but from which context. The context should be uniform, so that the requirements for locking should also be uniform. Regards Oliver -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html