libftdi Archives

Subject: RE: Claiming devices has no effect under Linux

From: "Michael Plante" <michael.plante@xxxxxxxxx>
To: <libftdi@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Tue, 5 Oct 2010 11:49:42 -0500
Uwe Bonnes [mailto:bon@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx] wrote:
>> >>>>> "Thomas" == Thomas Klose <thomas.klose@xxxxxxxxxxxxx> writes:
>>
>>
>>     Thomas> Now it works as expected. What is this function needed for,
>>     Thomas> anyway? I whitch case is it necessary to detach a module
>>     Thomas> explicitly?
>>
>> There are a lot of FTDI devices out there, and in most cases ftdi_sio is
>> loaded for that device when the device is plugged in. Without the call to
>> usb_detach_kernel_driver_np(), in that case libftdi can't talk to the
>> device. So the call to usb_detach_kernel_driver_np() is needed in many
>> situations.
>>
>> In your situation, however it is wrong. Ideas how to handle that
situation
>> are welcome.

I'm confused about something.  It seems that in the case Sven and Eberhard
describe on the libusb-devel thread

http://libusb.6.n5.nabble.com/How-to-establish-EXCLUSIVE-instead-of-SHARED-a
ccess-to-usb-device-td6878.html

, the detach call comes BEFORE the call to claim an interface.  It also
seems this happens in libftdi.  Given the order these two operations happen
in, why does detaching the driver break a claim that theoretically shouldn't
even exist (YET)?

Thanks,
Michael


--
libftdi - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx   

Current Thread