On Mon, 18 Nov 2013, Luke-Jr wrote:

> Is there a way to tell if a USB device is in use or not before requesting the 
> kernel detach drivers?
> 
> I'd define "in use" as either an interface claimed on usbfs or tty/etc 
> provided by a kernel driver being opened. And "not in use" including "kernel 
> driver attached, but not interfacing device to any software".

There is a form of the detach-driver call in usbfs that will not do 
anything if the current driver is usbfs.  But there is no way to tell 
if a tty or other device file is open, or if the device is interfaced 
to any software.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to