I'm trying to understand better the process of binding a device to its driver. I have an USB tool (In System Programmer for Arduino) whose Id (Product and Vendor) are known. The driver, cdc_acm.ko, doesn't recognize it (of course, it's not in its internal device list!). So... I have loaded the module
sudo modprobe cdc_acm
lsmod | grep cdc
$>cdc_acm
$>dmesg
...
[41244.510906] usbcore: registered new interface driver cdc_acm
[41244.510915] cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters
Perfect. Then I insert the device and dmesg output is the following:
...
[41447.794431] usb 2-1.2: new full-speed USB device number 17 using ehci-pci
[41447.887680] usb 2-1.2: New USB device found, idVendor=03eb, idProduct=2ff7
[41447.887690] usb 2-1.2: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[41447.887695] usb 2-1.2: Product: Arduino USB-Serial DFU
That seems to me that usb driver has been dealing with. Let me check accordingly to the folllowing http://lwn.net/Articles/143397/
$>ls -la /sys/bus/usb/drivers/usb/usb2/2-1/2-1.2/2-1.2\:1.0/
total 0
drwxr-xr-x 3 root root 0 gen 20 19:29 .
drwxr-xr-x 5 root root 0 gen 20 12:51 ..
-r--r--r-- 1 root root 4096 gen 20 12:58 bAlternateSetting
-r--r--r-- 1 root root 4096 gen 20 12:51 bInterfaceClass
-r--r--r-- 1 root root 4096 gen 20 12:51 bInterfaceNumber
-r--r--r-- 1 root root 4096 gen 20 12:58 bInterfaceProtocol
-r--r--r-- 1 root root 4096 gen 20 12:58 bInterfaceSubClass
-r--r--r-- 1 root root 4096 gen 20 12:58 bNumEndpoints
-r--r--r-- 1 root root 4096 gen 20 12:58 modalias
drwxr-xr-x 2 root root 0 gen 20 12:58 power
lrwxrwxrwx 1 root root 0 gen 20 12:58 subsystem -> ../../../../../../../bus/usb
-r--r--r-- 1 root root 4096 gen 20 12:58 supports_autosuspend
-rw-r--r-- 1 root root 4096 gen 20 12:51 uevent
module link is not existing, therefore it seems that the device is not linked to usb module driver. Nice to note that the content of modalias file is what I was expecting:
usb:v03EBp2FF7d0000dc00dsc00dp00icFEisc01ip02in00
Now I try to link the device to the module cdc_acm with the following command:
$>sudo echo -n "2-1.2:1.0" > sudo /sys/bus/usb/drivers/cdc_acm/bind
dmesg output shows nothing specific to the command just issued.
What am I doing wrong here? I would expect at least some debug output, if I issued an offending request I would expect at least a kernel message back... At least having some system feedback would help me in understanding what the problem is... Anybody can help me? Thanks. PS. I'm using Ubuntu 14.10 64bit on Intel core i3 ASUS laptop F552C.