On Thu, 3 May 2012, Xiaofan Chen wrote:

> Last time we have a long discussion here and there is no good
> solution to the following ticket.
> http://www.libusb.org/ticket/125
> libusb_kernel_driver_active() and _detach() are racy
> "If the functionality is to be kept in the next API then let's do
> something that isn't racy."
> 
> Relevant discussion (long thread).
> http://libusb.6.n5.nabble.com/Patch-libusb-os-linux-usbfs-c-Distingush-between-usbfs-and-other-kernel-mode-drivers-td3199947.html
> 
> Any new thought on this topic? Is it even possible to do this
> without changing the Linux kernel usbfs driver?

I don't think so.  At the very least, it would be necessary to change 
the USBDEVFS_DISCONNECT ioctl to make it avoid doing anything if the 
current driver is usbfs.  A better approach would be to allow the user 
to specify a driver name, and have USBDEVFS_DISCONNECT do nothing if 
the current driver isn't the one specified.

Alan Stern


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
libusbx-devel mailing list
libusbx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libusbx-devel

Reply via email to