blob: 8ef0616eda0b2a8f3399aedc113ce8208c202c49 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
The DVB subsystem currently registers to the sysfs subsystem using the
"class_simple" interface.
This means that only the basic informations like module loading parameters
are presented through sysfs. Other things that might be interesting are
currently *not* available.
Nevertheless it's now possible to add proper udev rules so that the
DVB device nodes are created automatically.
We assume that you have udev already up and running and that have been
creating the DVB device nodes manually up to now due to the missing sysfs
support.
0. Don't forget to disable your current method of creating the
device nodes manually.
1. Unfortunately, you'll need a helper script to transform the kernel
sysfs device name into the well known dvb adapter / device naming scheme.
The script should be called "dvb.sh" and should be placed into a script
dir where udev can execute it, most likely /etc/udev/scripts/
So, create a new file /etc/udev/scripts/dvb.sh and add the following:
------------------------------schnipp------------------------------------------------
#!/bin/sh
/bin/echo $1 | /bin/sed -e 's,dvb\([0-9]\)\.\([^0-9]*\)\([0-9]\),dvb/adapter\1/\2\3,'
------------------------------schnipp------------------------------------------------
Don't forget to make the script executable with "chmod".
1. You need to add a proper rule to your udev rule file. The main
udev configuration file /etc/udev/udev.conf will tell you the
directory of the rules, most likely it's /etc/udev/rules.d/
Edit the main rule file and add the following rule to the end
of the file.
KERNEL="dvb*", PROGRAM="/etc/udev/scripts/dvb.sh %k", NAME="%c"
For every device that registers to the sysfs subsystem with a "dvb" prefix,
the helper script /etc/udev/scripts/dvb.sh is invoked, which will then
create the proper device name.
Now udev will create the device node in your /dev/ device tree.
|