-
Notifications
You must be signed in to change notification settings - Fork 0
/
devd.conf
49 lines (42 loc) · 1.05 KB
/
devd.conf
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
45
46
47
48
# Install this to /usr/local/etc/devd/devd-mount.conf
# Derived from sysutils/automout
# USB drive attach
notify 100 {
match "system" "DEVFS";
match "type" "CREATE";
match "cdev" "(da|mmcsd|ugen)[0-9]+.*";
action "/usr/local/sbin/devd-mount $cdev &";
};
# USB drive detach
notify 100 {
match "system" "DEVFS";
match "type" "DESTROY";
match "cdev" "(da|mmcsd|ugen)[0-9]+.*";
action "/sbin/umount -f $cdev &";
};
# Optical media insert
notify 100 {
match "system" "DEVFS";
match "type" "CREATE|MEDIACHANGE";
match "cdev" "(cd)[0-9]+.*";
action "/usr/local/sbin/devd-mount $cdev &";
};
# Optical media eject
notify 100 {
match "system" "DEVFS";
match "type" "DESTROY";
match "cdev" "(cd)[0-9]+.*";
action "/usr/local/sbin/umount $cdev &";
};
# Not sure what this is good for yet
# CD-ROM no media
notify 100 {
match "system" "CAM";
match "subsystem" "periph";
match "type" "error";
match "cam_status" "0xcc";
match "scsi_status" "2";
match "scsi_sense" "70 02 3a 02";
match "device" "(cd)[0-9]+.*";
action "/usr/local/sbin/devd-mount $device &";
};