chiark / gitweb /
rules: move aoe rules to default rules file
[elogind.git] / rules / rules.d / 50-udev-default.rules
1 # do not edit this file, it will be overwritten on update
2
3 SUBSYSTEM=="block", SYMLINK+="block/%M:%m"
4 SUBSYSTEM!="block", SYMLINK+="char/%M:%m"
5
6 KERNEL=="pty[pqrstuvwxyzabcdef][0123456789abcdef]", GROUP="tty", MODE="0660", OPTIONS+="last_rule"
7 KERNEL=="tty[pqrstuvwxyzabcdef][0123456789abcdef]", GROUP="tty", MODE="0660", OPTIONS+="last_rule"
8 KERNEL=="ptmx",                 GROUP="tty", MODE="0666", OPTIONS+="last_rule"
9 KERNEL=="tty",                  GROUP="tty", MODE="0666", OPTIONS+="last_rule"
10 KERNEL=="tty[0-9]*",            GROUP="tty", MODE="0620", OPTIONS+="last_rule"
11 KERNEL=="vcs|vcs[0-9]*|vcsa|vcsa[0-9]*", GROUP="tty", OPTIONS+="last_rule"
12 KERNEL=="console",              MODE="0600", OPTIONS+="last_rule"
13
14 # serial
15 KERNEL=="tty[A-Z]*|pppox*|ircomm*|noz*", GROUP="uucp"
16 KERNEL=="ppp",                  MODE="0600", OPTIONS+="ignore_remove"
17 KERNEL=="mwave",                NAME="modems/mwave", GROUP="uucp"
18 KERNEL=="hvc*|hvsi*",           GROUP="uucp"
19 KERNEL=="lirc0",                SYMLINK+="lirc"
20
21 # mem
22 KERNEL=="null|zero|full|random|urandom", MODE="0666"
23 KERNEL=="null",                 SYMLINK+="X0R"
24 KERNEL=="mem|kmem|port|nvram",  GROUP="kmem", MODE="0640"
25 KERNEL=="ram0",                 SYMLINK+="ramdisk"
26 KERNEL=="ram1",                 SYMLINK+="ram"
27
28 # input
29 KERNEL=="mouse*|mice|event*",   NAME="input/%k", MODE="0640"
30 KERNEL=="ts[0-9]*|uinput",      NAME="input/%k", MODE="0600"
31 KERNEL=="js[0-9]*",             NAME="input/%k", MODE="0644", SYMLINK+="%k"
32
33 # video4linux
34 SUBSYSTEM=="video4linux",       GROUP="video"
35 KERNEL=="vttuner*",             GROUP="video"
36 KERNEL=="vtx*|vbi*",            GROUP="video"
37 KERNEL=="winradio*",            GROUP="video"
38 KERNEL=="vbi0",                 SYMLINK+="vbi"
39 KERNEL=="radio0",               SYMLINK+="radio"
40 KERNEL=="video0",               SYMLINK+="video"
41
42 # graphics
43 KERNEL=="agpgart",              MODE="0600", GROUP="video"
44 KERNEL=="card[0-9]*",           NAME="dri/%k", MODE="0666"
45 KERNEL=="fb0",                  SYMLINK+="fb"
46 KERNEL=="pmu",                  GROUP="video"
47 KERNEL=="nvidia*|nvidiactl*",   GROUP="video"
48 SUBSYSTEM=="graphics",          GROUP="video"
49
50 # DVB video
51 SUBSYSTEM=="dvb", PROGRAM="/bin/sh -c 'K=%k; K=$${K#dvb}; printf dvb/adapter%%i/%%s $${K%%%%.*} $${K#*.}'", NAME="%c"
52 SUBSYSTEM=="dvb",               GROUP="video"
53
54 # Firewire
55 KERNEL=="dv1394*",              SYMLINK+="dv1394/%n"
56 KERNEL=="video1394*",           NAME="video1394/%n"
57 KERNEL=="dv1394*|video1394*|raw1394*",  GROUP="video"
58
59 # firmware class requests
60 SUBSYSTEM=="firmware", ACTION=="add", RUN+="firmware.sh"
61
62 # libusb device nodes
63 SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", MODE="0644"
64
65 # printer
66 KERNEL=="parport[0-9]*",        GROUP="lp"
67 SUBSYSTEM=="printer",           KERNEL=="lp*", GROUP="lp"
68 SUBSYSTEM=="usb",               KERNEL=="lp*", NAME="usb/%k", SYMLINK+="usb%k", GROUP="lp"
69 KERNEL=="lp[0-9]*",             GROUP="lp", SYMLINK+="par%n"
70 KERNEL=="irlpt[0-9]*",          GROUP="lp"
71
72 # block, tapes, block-releated
73 SUBSYSTEM=="block", GROUP="disk"
74 SUBSYSTEM=="block", KERNEL=="sr[0-9]*", SYMLINK+="scd%n"
75 KERNEL=="hd*", SUBSYSTEMS=="ide", ATTRS{media}=="floppy", OPTIONS+="all_partitions"
76 KERNEL=="fd[0-9]",              GROUP="floppy"
77 KERNEL=="fd[0-9]", ACTION=="add", ATTRS{cmos}=="?*", RUN+="create_floppy_devices -c -t $attr{cmos} -m %M -M 0640 -G floppy $root/%k"
78 KERNEL=="sch[0-9]*",            GROUP="disk"
79 KERNEL=="sg[0-9]*",             ATTRS{type}!="3|6", GROUP="disk", MODE="0640"
80 KERNEL=="ht[0-9]*|nht[0-9]*",   GROUP="disk"
81 KERNEL=="pg[0-9]*",             GROUP="disk"
82 KERNEL=="pt[0-9]*|npt[0-9]*",   GROUP="disk"
83 KERNEL=="qft[0-9]*|nqft[0-9]*|zqft[0-9]*|nzqft[0-9]*|rawqft[0-9]*|nrawqft[0-9]*", GROUP="disk"
84 KERNEL=="rawctl",               NAME="raw/%k", GROUP="disk"
85 SUBSYSTEM=="raw", KERNEL=="raw[0-9]*", NAME="raw/%k", GROUP="disk"
86 KERNEL=="pktcdvd[0-9]*",        NAME="pktcdvd/%k"
87 KERNEL=="pktcdvd",              NAME="pktcdvd/control"
88 KERNEL=="qft0",                 SYMLINK+="ftape"
89 SUBSYSTEM=="bsg",               NAME="bsg/%k"
90 SUBSYSTEM=="aoe",               NAME="etherd/%k", GROUP="disk", MODE="0220"
91 SUBSYSTEM=="aoe", KERNEL=="err", MODE="0440"
92
93 # network
94 KERNEL=="tun",                  NAME="net/%k", MODE="0666", OPTIONS+="ignore_remove"
95
96 # CPU
97 KERNEL=="cpu[0-9]*",            NAME="cpu/%n/cpuid"
98 KERNEL=="msr[0-9]*",            NAME="cpu/%n/msr"
99 KERNEL=="microcode",            NAME="cpu/microcode", MODE="0600"
100
101 # miscellaneous
102 KERNEL=="fuse",                 MODE="0666"
103 KERNEL=="rtc|rtc0",             MODE="0644"
104 KERNEL=="rtc0",                 SYMLINK+="rtc"
105 KERNEL=="auer[0-9]*",           NAME="usb/%k"
106 KERNEL=="hw_random",            NAME="hwrng", SYMLINK+="%k"
107 KERNEL=="mmtimer",              MODE="0644"
108 KERNEL=="rflash[0-9]*",         MODE="0400"
109 KERNEL=="rrom[0-9]*",           MODE="0400"
110 KERNEL=="sbpcd0",               SYMLINK+="sbpcd"
111 KERNEL=="slram[0-9]*",          SYMLINK+="xpram%n"
112 KERNEL=="sxctl",                NAME="specialix_sxctl", SYMLINK+="%k"
113 KERNEL=="rioctl",               NAME="specialix_rioctl", SYMLINK+="%k"
114 KERNEL=="iowarrior[0-9]*",      NAME="usb/%k"
115 KERNEL=="hiddev[0-9]*",         NAME="usb/%k"
116 KERNEL=="legousbtower[0-9]*",   NAME="usb/%k"
117 KERNEL=="dabusb[0-9]*",         NAME="usb/%k"
118 KERNEL=="usbdpfp[0-9]*",        NAME="usb/%k"
119 KERNEL=="cpad[0-9]*",           NAME="usb/%k"
120
121 # do not delete static device nodes
122 ACTION=="remove", NAME=="?*", TEST=="/lib/udev/devices/$name", OPTIONS+="ignore_remove"
123