Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Imagine I have a new device which it's not working on Linux. I get its device ID with lsusb:

Bus 001 Device 003: ID1164:7efdYUAN High-Tech Development Co., Ltd

Imagine I know that this device will work with this firmware /lib/firmware/dvb-usb-dib0700-1.20.fw

Then I would like to create a rule or something that could tell the operating system that the device 1164:7efd must be loaded with the firmware dvb-usb-dib0700-1.20.fw

I just want to link the device ID with the firmware, so my device will work. Is there any way to do that?

Thanks

share|improve this question

migrated from stackoverflow.com Jan 22 '12 at 1:03

This question came from our site for professional and enthusiast programmers.

1 Answer 1

I have this file:

/lib/udev/rules.d/50-firmware.rules

with this content:

# do not edit this file, it will be overwritten on update

# firmware-class requests, copies files into the kernel
SUBSYSTEM=="firmware", ACTION=="add", RUN+="firmware --firmware=$env{FIRMWARE} --devpath=$env{DEVPATH}"

See examples from rules.d directories in either /lib/udev/rules.d or /etc/udev/rules.d and place your custom udev rules to

 /etc/udev/rules.d/

At least these are the file locations on a ubuntu server.

My quick guess is that the line should be something like this, but I'm too cross-eyed to look any documents in more detail.

ATTRS{idVendor}=="1164", ATTRS{idProduct}=="7efd", SUBSYSTEM=="firmware", ACTION=="add", RUN+="firmware --firmware=/lib/firmware/dvb-usb-dib0700-1.20.fw --devpath=$env{DEVPATH}"

see man udev for more information.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.