# /etc/mdev.conf

# Syntax:
# [-]devicename_regex user:group mode [=path]|[>path]|[!] [@|$|*cmd args...]
# [-]$ENVVAR=regex    user:group mode [=path]|[>path]|[!] [@|$|*cmd args...]
# [-]@maj,min[-min2]  user:group mode [=path]|[>path]|[!] [@|$|*cmd args...]
#
# [-]: do not stop on this match, continue reading mdev.conf
# =: move, >: move and create a symlink
# !: do not create device node
# @|$|*: run cmd if $ACTION=remove, @cmd if $ACTION=add, *cmd in all cases

# Support module loading on hotplug
#$MODALIAS=.*		root:root	0660	@/bin/busybox modprobe "$MODALIAS"

null			root:root	0666
zero			root:root	0666
full			root:root	0666
random			root:root	0666
urandom			root:root	0444

# Console device
console			root:tty	0600

# TTY devices
ttyS[0-9]*		root:root	0660
ttyUSB[0-9]*		root:root	0660

# DVB devices
dvb([0-9])\.(.*)([0-9])	root:root	0660	=dvb/adapter%1/%2%3
# Framebuffer
fb([0-2])		root:root	0660	>fb/%1

ram[0-9].*		root:root	0660	>ram

# Input layer
event[0-9]+		root:root	0640	=input/
mice			root:root	0640	=input/
mouse[0-9]+		root:root	0640	=input/

# USB devices
usbdev[0-9].[0-9]*	root:root	0660	!
(.*)-(.*):1.0		root:root	0660	*/lib/mdev/usb/mdev-usb

# Mass-storage devices
sd[a-z][0-9]		root:root	0664	*/lib/mdev/fs/mdev-mount
# Disc devices
sr[0-9]			root:root	0664	*/lib/mdev/fs/mdev-mount
# Memory cards
mmcblk[0-9]p[0-9]	root:root	0664	*/lib/mdev/fs/mdev-mount

# WLAN devices
ra[0-9]*		root:root	0644	*/lib/mdev/net/mdev-wlan
rausb[0-9]*		root:root	0644	*/lib/mdev/net/mdev-wlan
wlan[0-9]*		root:root	0644	*/lib/mdev/net/mdev-wlan

# Block devices: group -> disk
mtdblock[0-9]		root:root	0600

# Double up flash characters devices
mtd[0-9]+		root:root	0600
mtd[0-9]+ro		root:root	0600

# Log all other devices. Right now useful only for debuging.
.*			root:root	0600	*/lib/mdev/common/mdev-log-only
