makestuff/libusbwrap — pull request #1 by mithro (2014-04-28 00:19:03+00:00)
Title: Detact the kernel driver to allow libusb to control the device.

On our Atlys board, we flash the Cypress with "fx2loader -v 1d50:602b HDMI2USB-firmware-prebuilt/hdmi2usb.hex ram" and then uvcvideo and cdc-acm drivers connect to the new endpoints.

This patch lets us use "flcli -v 1d50:602b:9994 -i fb9a:fb9a" to return the Cypress into programming mode.

```
[94023.794451] cdc_acm 2-1.1:1.2: ttyACM0: USB ACM device
[94026.571620] usb 2-1.1: USB disconnect, device number 19
[94028.051519] usb 2-1.1: new high-speed USB device number 20 using ehci-pci
[94028.144983] usb 2-1.1: New USB device found, idVendor=1d50, idProduct=602b
[94028.144995] usb 2-1.1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[94028.145002] usb 2-1.1: Product: FPGALink/FX2 20140311
[94028.145007] usb 2-1.1: Manufacturer: MakeStuff
[95015.404214] usb 2-1.1: USB disconnect, device number 20
[95017.138867] usb 2-1.1: new high-speed USB device number 21 using ehci-pci
[95017.231537] usb 2-1.1: config 1 interface 2 altsetting 0 endpoint 0x81 has an invalid bInterval 17, changing to 8
[95017.232517] usb 2-1.1: New USB device found, idVendor=fb9a, idProduct=fb9a
[95017.232527] usb 2-1.1: New USB device strings: Mfr=2, Product=1, SerialNumber=1
[95017.232533] usb 2-1.1: Product: HDMI2USB
[95017.232538] usb 2-1.1: Manufacturer: JANI
[95017.232542] usb 2-1.1: SerialNumber: HDMI2USB
[95017.233332] uvcvideo: Found UVC 1.00 device HDMI2USB (fb9a:fb9a)
[95017.233558] uvcvideo: UVC non compliance - GET_DEF(PROBE) not supported. Enabling workaround.
[95017.234742] cdc_acm 2-1.1:1.2: This device cannot do calls on its own. It is not a modem.
[95017.234852] cdc_acm 2-1.1:1.2: ttyACM0: USB ACM device
[95023.085273] usb 2-1.1: USB disconnect, device number 21
[95024.564253] usb 2-1.1: new high-speed USB device number 22 using ehci-pci
[95024.657215] usb 2-1.1: New USB device found, idVendor=1d50, idProduct=602b
[95024.657228] usb 2-1.1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[95024.657234] usb 2-1.1: Product: FPGALink/FX2 20140311
[95024.657239] usb 2-1.1: Manufacturer: MakeStuff
```