Re: [PATCH v2] usb: serial: Repair FTDI FT232R bricked eeprom

From: Hector Martin
Date: Thu Sep 10 2020 - 15:56:14 EST

On 11/09/2020 03.51, James Hilliard wrote:
I haven't tested this yet but my assumption was that either a kernel driver
or libusb can issue usb control messages, but both can not be bound to
a device at the same time. I figured this wouldn't have come up when you
tested your python script since the script likely predated adding the brick PID
to the ftdi_sio Linux kernel driver.

Binding to interfaces is exclusive, but global device control messages are not issued to an interface. I think it should work even if the kernel driver is bound (this is how lsusb works too, since it issues control requests even to devices bound to drivers). Even if it is necessary to unbind it, though, libusb already provides a single function to do that (libusb_detach_kernel_driver).

Hector Martin (hector@xxxxxxxxxxxxxx)
Public Key: