[7e161ea] | 1 | ########################################################################
|
---|
| 2 | #
|
---|
[1f7827a2] | 3 | # Description : 50-udev.rules
|
---|
[7e161ea] | 4 | #
|
---|
| 5 | # Authors : Based on Open Suse Udev Rules
|
---|
| 6 | # kay.sievers@suse.de
|
---|
| 7 | #
|
---|
| 8 | # Adapted to : Jim Gifford
|
---|
[1f7827a2] | 9 | # LFS : Alexander E. Patrakov
|
---|
[7e161ea] | 10 | #
|
---|
| 11 | # Version : 00.01
|
---|
| 12 | #
|
---|
| 13 | # Notes :
|
---|
| 14 | #
|
---|
| 15 | ########################################################################
|
---|
| 16 |
|
---|
[5e2628a1] | 17 | # block devices
|
---|
| 18 | SUBSYSTEM=="block", GROUP="disk", MODE="0640"
|
---|
| 19 |
|
---|
[7e161ea] | 20 | # console
|
---|
[1f7827a2] | 21 | KERNEL=="pty[pqrstuvwxyzabcdef][0123456789abcdef]", NAME="%k", GROUP="tty", MODE="666", OPTIONS="last_rule"
|
---|
| 22 | KERNEL=="tty[pqrstuvwxyzabcdef][0123456789abcdef]", NAME="%k", GROUP="tty", MODE="666", OPTIONS="last_rule"
|
---|
| 23 | KERNEL=="vcs*", NAME="%k", GROUP="tty", MODE="620", OPTIONS="last_rule"
|
---|
| 24 | KERNEL=="tty", NAME="%k", GROUP="tty", MODE="666", OPTIONS="last_rule"
|
---|
| 25 | KERNEL=="tty[0-9]*", NAME="%k", GROUP="tty", MODE="620", OPTIONS="last_rule"
|
---|
| 26 | KERNEL=="console", NAME="%k", MODE="600", OPTIONS="last_rule"
|
---|
| 27 | KERNEL=="ptmx", NAME="%k", GROUP="tty", MODE="666", OPTIONS="last_rule"
|
---|
[7e161ea] | 28 |
|
---|
| 29 | # serial devices
|
---|
| 30 | KERNEL=="tty[A-Z]*", NAME="%k", GROUP="uucp"
|
---|
| 31 | KERNEL=="pppox*", NAME="%k", GROUP="uucp"
|
---|
| 32 | KERNEL=="ircomm*", NAME="%k", GROUP="uucp"
|
---|
| 33 | KERNEL=="modems/mwave*", NAME="%k", GROUP="uucp"
|
---|
| 34 | KERNEL=="hvc*", NAME="%k", GROUP="uucp"
|
---|
| 35 | KERNEL=="hvsi*", NAME="%k", GROUP="uucp"
|
---|
| 36 | KERNEL=="iseries/vtty*", NAME="%k", GROUP="uucp"
|
---|
[1f7827a2] | 37 | KERNEL=="ttyUSB*", SYSFS{product}=="[Pp]alm*Handheld*", SYMLINK+="pilot"
|
---|
[a66f0df] | 38 | KERNEL=="ttyUSB*", SYSFS{product}=="[Hh]andspring*Treo*|[Hh]andspring*Visor*", SYMLINK+="pilot"
|
---|
[7e161ea] | 39 |
|
---|
| 40 | # video/graphics
|
---|
| 41 | SUBSYSTEM=="video4linux", GROUP="video"
|
---|
| 42 | SUBSYSTEM=="graphics" GROUP="video"
|
---|
| 43 | KERNEL=="vtx*", NAME="%k", GROUP="video"
|
---|
| 44 | KERNEL=="vbi*", NAME="%k", GROUP="video"
|
---|
| 45 | KERNEL=="winradio*", NAME="%k", GROUP="video"
|
---|
| 46 | KERNEL=="vttuner*", NAME="%k", GROUP="video"
|
---|
| 47 | KERNEL=="nvidia*", NAME="%k", GROUP="video"
|
---|
| 48 | KERNEL=="video0", SYMLINK+="video"
|
---|
| 49 | KERNEL=="radio0", SYMLINK+="radio"
|
---|
| 50 | KERNEL=="vbi0", SYMLINK+="vbi"
|
---|
| 51 | KERNEL=="pmu", GROUP="video"
|
---|
| 52 |
|
---|
| 53 | # dvb
|
---|
[f59ed2c] | 54 | SUBSYSTEM=="dvb", PROGRAM="/bin/sh -c 'K=%k; K=$${K#dvb}; printf dvb/adapter%%i/%%s $${K%%%%.*} $${K#*.}'", NAME="%c", GROUP="video"
|
---|
[7e161ea] | 55 |
|
---|
| 56 | # input devices
|
---|
| 57 | KERNEL=="mice", NAME="input/%k", MODE="0640"
|
---|
| 58 | KERNEL=="mouse*", NAME="input/%k", MODE="0640"
|
---|
| 59 | KERNEL=="event*", NAME="input/%k", MODE="0640"
|
---|
| 60 | KERNEL=="js*", NAME="input/%k", MODE="0644"
|
---|
| 61 | KERNEL=="ts*", NAME="input/%k", MODE="0600"
|
---|
| 62 | KERNEL=="uinput", NAME="input/%k", MODE="0600"
|
---|
| 63 | KERNEL=="lirc0", NAME="%k", SYMLINK+="lirc"
|
---|
| 64 |
|
---|
| 65 | # printer
|
---|
| 66 | SUBSYSTEM=="usb", KERNEL=="lp*", NAME="usb/%k", SYMLINK+="usb%k", GROUP="lp"
|
---|
| 67 | SUBSYSTEM=="printer", KERNEL=="lp*", NAME="%k", GROUP="lp"
|
---|
| 68 | KERNEL=="irlpt*", NAME="%k", GROUP="lp"
|
---|
| 69 |
|
---|
| 70 | # cpu devices
|
---|
| 71 | KERNEL=="cpu[0-9]*", NAME="cpu/%n/cpuid"
|
---|
| 72 | KERNEL=="msr[0-9]*", NAME="cpu/%n/msr"
|
---|
| 73 | KERNEL=="microcode", NAME="cpu/microcode", MODE="0600"
|
---|
| 74 |
|
---|
| 75 | # IEEE1394 devices
|
---|
| 76 | KERNEL=="raw1394*", NAME="%k", GROUP="video"
|
---|
| 77 | KERNEL=="dv1394*", NAME="%k", SYMLINK+="dv1394/%n", GROUP="video"
|
---|
| 78 | KERNEL=="video1394*", NAME="%k", SYMLINK+="video1394/%n", GROUP="video"
|
---|
| 79 |
|
---|
| 80 | # 183 = /dev/hwrng Generic random number generator
|
---|
| 81 | KERNEL=="hw_random", NAME="hwrng", SYMLINK+="%k"
|
---|
[1f7827a2] | 82 |
|
---|
[7e161ea] | 83 | # 219 /dev/modems/mwave MWave modem firmware upload
|
---|
| 84 | KERNEL=="mwave", NAME="modems/%k"
|
---|
[1f7827a2] | 85 |
|
---|
[7e161ea] | 86 | # 169 /dev/specialix_rioctl Specialix RIO serial control
|
---|
| 87 | KERNEL=="rioctl", NAME="specialix_rioctl", SYMLINK+="%k"
|
---|
[1f7827a2] | 88 |
|
---|
[7e161ea] | 89 | # 167 /dev/specialix_sxctl Specialix serial control
|
---|
| 90 | KERNEL=="sxctl", NAME="specialix_sxctl", SYMLINK+="%k"
|
---|
| 91 |
|
---|
[a6cd72e] | 92 | # network
|
---|
[1f7827a2] | 93 | KERNEL=="tun", NAME="net/%k", MODE="0600"
|
---|
[a6cd72e] | 94 |
|
---|
[7e161ea] | 95 | # misc devices
|
---|
| 96 | KERNEL=="mem", NAME="%k", GROUP="kmem", MODE="640"
|
---|
| 97 | KERNEL=="kmem", NAME="%k", GROUP="kmem", MODE="640"
|
---|
| 98 | KERNEL=="port", NAME="%k", GROUP="kmem", MODE="640"
|
---|
| 99 | KERNEL=="nvram", NAME="%k", GROUP="kmem", MODE="600"
|
---|
| 100 | KERNEL=="null", NAME="%k", MODE="666"
|
---|
| 101 | KERNEL=="zero", NAME="%k", MODE="666"
|
---|
| 102 | KERNEL=="full", NAME="%k", MODE="622"
|
---|
| 103 | KERNEL=="random", NAME="%k", MODE="666"
|
---|
| 104 | KERNEL=="urandom", NAME="%k", MODE="644"
|
---|
| 105 | KERNEL=="rtc", GROUP="audio"
|
---|
| 106 | KERNEL=="sonypi", MODE="0666"
|
---|
| 107 | KERNEL=="agpgart", MODE="0600", GROUP="video"
|
---|
| 108 | KERNEL=="djs*", NAME="%k", MODE="644"
|
---|
| 109 | KERNEL=="sgi_*", NAME="%k", MODE="666"
|
---|
| 110 | KERNEL=="rrom*", NAME="%k", MODE="400"
|
---|
| 111 | KERNEL=="rflash*", NAME="%k", MODE="400"
|
---|
| 112 | KERNEL=="usbscanner*", NAME="%k", MODE="644"
|
---|
| 113 | KERNEL=="3270/ttycons*", NAME="%k", MODE="600"
|
---|
| 114 | KERNEL=="3270/tub*", NAME="%k", MODE="666"
|
---|
| 115 | KERNEL=="3270/tubcons*", NAME="%k", MODE="600"
|
---|
| 116 | KERNEL=="ica", NAME="%k", MODE="666"
|
---|
| 117 | KERNEL=="z90crypt", NAME="%k", MODE="666"
|
---|
| 118 | KERNEL=="mmtimer", NAME="%k", MODE="444"
|
---|
| 119 | KERNEL=="auer[0-9]*" NAME="usb/%k"
|
---|
| 120 |
|
---|
[a6cd72e] | 121 | # packet writing interface
|
---|
[7e161ea] | 122 | KERNEL=="pktcdvd", NAME="pktcdvd/control"
|
---|
| 123 | KERNEL=="pktcdvd[0-9]*", NAME="pktcdvd/%k"
|
---|
| 124 |
|
---|
| 125 | # fix floppy devices
|
---|
[529837f] | 126 | KERNEL=="fd[0-9]*", ACTION=="add", GROUP="floppy", MODE="660"
|
---|
[1f7827a2] | 127 | KERNEL=="fd[0-9]*", ACTION=="remove", RUN+="/bin/rm -f $root/%k*"
|
---|
[7e161ea] | 128 |
|
---|
| 129 | # sd: 0 TYPE_DISK, 7 TYPE_MOD, 14 TYPE_RBC
|
---|
| 130 | # sr: 4 TYPE_WORM, 5 TYPE_ROM
|
---|
| 131 | # st/osst: 1 TYPE_TAPE
|
---|
[a66f0df] | 132 | ACTION=="add", SUBSYSTEM=="scsi" , SYSFS{type}=="0|7|14", RUN+="/bin/sh -c 'echo 60 > /sys/$DEVPATH/timeout'"
|
---|
| 133 | ACTION=="add", SUBSYSTEM=="scsi" , SYSFS{type}=="1", RUN+="/bin/sh -c 'echo 900 > /sys/$DEVPATH/timeout'"
|
---|
[7e161ea] | 134 |
|
---|
| 135 | # device mapper
|
---|
[1f7827a2] | 136 | KERNEL=="device-mapper", NAME="%k", SYMLINK+="mapper/control"
|
---|
[7e161ea] | 137 |
|
---|
| 138 | # misc storage devices (non-block)
|
---|
| 139 | KERNEL=="sg*", NAME="%k", GROUP="disk", MODE="640"
|
---|
[1f7827a2] | 140 | KERNEL=="st*", NAME="%k", GROUP="tape"
|
---|
| 141 | KERNEL=="nst*", NAME="%k", GROUP="tape"
|
---|
[7e161ea] | 142 | KERNEL=="initrd", NAME="%k", GROUP="disk"
|
---|
[1f7827a2] | 143 | KERNEL=="qft*", NAME="%k", GROUP="tape"
|
---|
| 144 | KERNEL=="nqft*", NAME="%k", GROUP="tape"
|
---|
| 145 | KERNEL=="zqft*", NAME="%k", GROUP="tape"
|
---|
| 146 | KERNEL=="nzqft*", NAME="%k", GROUP="tape"
|
---|
| 147 | KERNEL=="rawqft*", NAME="%k", GROUP="tape"
|
---|
| 148 | KERNEL=="nrawqft*", NAME="%k", GROUP="tape"
|
---|
[7e161ea] | 149 | KERNEL=="pf*", NAME="%k", GROUP="disk"
|
---|
| 150 | KERNEL=="sch*", NAME="%k", GROUP="disk"
|
---|
[1f7827a2] | 151 | KERNEL=="pt*", NAME="%k", GROUP="tape"
|
---|
| 152 | KERNEL=="npt*", NAME="%k", GROUP="tape"
|
---|
[7e161ea] | 153 | KERNEL=="pg*", NAME="%k", GROUP="disk"
|
---|
| 154 | KERNEL=="evms/block_device*", NAME="%k", GROUP="disk"
|
---|
[a66f0df] | 155 | KERNEL=="rawctl*", NAME="raw/%k", GROUP="disk"
|
---|
| 156 | KERNEL=="raw[0-9]*", NAME="raw/%k", GROUP="disk"
|
---|
[1f7827a2] | 157 | KERNEL=="osst*", NAME="%k", GROUP="tape"
|
---|
| 158 | KERNEL=="nosst*", NAME="%k", GROUP="tape"
|
---|
[7e161ea] | 159 | KERNEL=="iseries/vt*", NAME="%k", GROUP="disk"
|
---|
| 160 | KERNEL=="iseries/nvt*", NAME="%k", GROUP="disk"
|
---|
| 161 | KERNEL=="iseries/ibmsis*", NAME="%k", GROUP="disk"
|
---|
| 162 |
|
---|
| 163 | # libusb device access
|
---|
[1f7827a2] | 164 | SUBSYSTEM=="usb_device", PROGRAM="/bin/sh -c 'K=%k; K=$${K#usbdev}; printf bus/usb/%%03i/%%03i $${K%%%%.*} $${K#*.}'", NAME="%c", MODE="0644"
|
---|
[c2504ea] | 165 |
|
---|