summaryrefslogtreecommitdiffstats
path: root/etc/rc.d/devd
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2002-11-30 00:40:53 +0000
committerimp <imp@FreeBSD.org>2002-11-30 00:40:53 +0000
commit5993de8d7f96ca1c37ff1cd4afc2c2c4b29983b6 (patch)
tree09ba9b07c36b9450f88e1e247f7fd29415fada40 /etc/rc.d/devd
parent56ef2e511b48a864612c1332672fa67848911709 (diff)
downloadFreeBSD-src-5993de8d7f96ca1c37ff1cd4afc2c2c4b29983b6.zip
FreeBSD-src-5993de8d7f96ca1c37ff1cd4afc2c2c4b29983b6.tar.gz
Two fixes for devd:
1) Move devd to the start of the head of the boot process rather than the end. 2) Disable devctl if devd is disabled.
Diffstat (limited to 'etc/rc.d/devd')
-rw-r--r--etc/rc.d/devd7
1 files changed, 6 insertions, 1 deletions
diff --git a/etc/rc.d/devd b/etc/rc.d/devd
index 7702c77..9636eaa 100644
--- a/etc/rc.d/devd
+++ b/etc/rc.d/devd
@@ -4,7 +4,7 @@
#
# PROVIDE: devd
-# REQUIRE: devfs
+# BEFORE: disks
# KEYWORD: FreeBSD
. /etc/rc.subr
@@ -15,3 +15,8 @@ command="/sbin/devd"
load_rc_config $name
run_rc_command "$1"
+
+# If devd is disabled, turn it off in the kernel to avoid memory leaks.
+if ! checkyesno ${rcvar}; then
+ sysctl hw.bus.devctl_disable=1
+fi
OpenPOWER on IntegriCloud