From: Peter S. <pe...@st...> - 2010-10-09 20:05:02
|
Alan Stern wrote: > It might also be desirable to avoid ever detaching the usbfs driver > -- however this is a matter to be settled by the designers and > users of libusb. It should not be enforced by the kernel. Why not? I can only think of one use case; two different apps which both use usbfs (via libusb or otherwise) but do not communicate between themselves to negotiate access so they end up fighting over it by detaching each other over and over. I think it would make good sense if usbfs would never detach itself. Then the second app wouldn't be able to "steal" the interface from another app which has already opened it. Most if not all other APIs in the kernel that I know of don't allow similar operations, even if two apps are run by the same user. A serial port might be read by several apps at once, but in that case access is shared, not exclusive as with USB interfaces. > Certainly libusb-0.1's ability to report the name of the current > driver shouldn't be given up in libusb-1.0. That's a backward > step. It's certainly a reduction in functionality, but I don't know if that is a problem as long as libusb can still be used by the app to do what they need. //Peter |