libftdi Archives

Subject: Re: Claiming devices has no effect under Linux

From: Thomas Klose <thomas.klose@xxxxxxxxxxxxx>
To: libftdi@xxxxxxxxxxxxxxxxxxxxxxx
Date: Thu, 07 Oct 2010 10:53:26 +0200
Am Donnerstag, den 07.10.2010, 09:04 +0800 schrieb Xiaofan Chen: 
> On Thu, Oct 7, 2010 at 4:56 AM, Thomas Klose <thomas.klose@xxxxxxxxxxxxx> 
> wrote:
> > Am Mittwoch, den 06.10.2010, 16:30 -0400 schrieb DJ Delorie:
> >> > In this case you could detach sio with modprobe, rmmod,
> >>
> >> ... detaching all my modems...
> >>
> >> > usb_detach_kernel_driver(), or whatever in your *application*.
> >>
> >> My application does not have root privs, so it cannot do any of the
> >> above.  The FTDI device in question has a "device name" string that
> >> the kernel matches to set the device permissions to allow libftdi (and
> >> thus my custom application) to detach the driver though.
> >
> > You do not need root privileges for usb_detach_kernel_driver().
> >
> And that is one of the the beauties of using libusb and kernel
> driver detaching. You do not need root privileges. But you do
> need to set up proper udev rules.

Yes, libusb this is great. One thing is interesting about it: Even
though libusb depends on the fact that no module is attached to the USB
device, it does not call the detach/re-attach functions automatically.
The programmer who uses the library decides if it is necessary or useful
to do so. And that is exactly my point.

libftdi - see for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx   

Current Thread