[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: How to know if USB device has driver properly installed?



On Fri, Mar 12, 2010 at 14:12:37 -0500, Celejar wrote:
> On Fri, 12 Mar 2010 18:18:30 +0200 Dotan Cohen wrote:

[...]

> > If after running "sudo update-usbids.sh" the device name is still not
> > shown, is that a sign that the driver is not properly installed?
> 
> As others (Florian) have explained, no.  IIUC, the usbids list is just
> a list of mappings between USB IDs and the organizations to which they
> have been allotted - it has no connection whatsoever to any executable
> code.  Drivers often contain (hardcoded) lists of USB IDs which they
> (think that they) can handle, and, IIUC, they sometimes will pick up
> any device whose data seems to be following a protocol that they know.

The kernel seems to use the information in 

/lib/modules/$(uname -r)/modules.alias

to decide which module(s) to try for a given device. AFAIK, this
information is generated/updated by running depmod, which is handled
automatically if you install a Debian kernel package or if you use
module-assistant/DKMS to handle additional modules.

> For example, I recently purchased a cheap, no-name USB webcam from a
> Far Eastern distributor.  lsusb didn't display anything helpful, but
> the uvc kernel driver handled the camera fine, apparently because the
> camera was speaking the uvc protocol.

That is also how I understand the process. Some of the entries in
modules.alias are straightforward vendor/device-ID pairs, while others
use wildcards for these values and rely on capabilities such as "a modem
of class X, subclass Y that understands protocol Z". The module then
often uses dedicated diagnostic code to find out if it really supports
that particular device. Syslog/dmesg should reveal which modules the
kernel tried in response to a USB hotplug event and if there were any
problems. Modprobing the module with a higher debug level (if that
option is available) should provide additional clues.

-- 
Regards,            |
          Florian   |


Reply to: