summaryrefslogtreecommitdiffstats
path: root/sys/kern
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2004-02-14 17:19:43 +0000
committerphk <phk@FreeBSD.org>2004-02-14 17:19:43 +0000
commitff78c06dec44aa94ce0113ebbe73c879699a3072 (patch)
treed53313aa5114edbcb2ad02b81f9ffd651b881f9f /sys/kern
parent22f7e9501708f21ab1e2d3b70c1fdc388963c031 (diff)
downloadFreeBSD-src-ff78c06dec44aa94ce0113ebbe73c879699a3072.zip
FreeBSD-src-ff78c06dec44aa94ce0113ebbe73c879699a3072.tar.gz
Remove the check which used to protect us against make_dev() being
called until DEVFS had a chance to initialize. Since DEVFS is mandatory and things over in that department coincidentally works from without any initialization now, this is safe.
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/kern_conf.c19
1 files changed, 0 insertions, 19 deletions
diff --git a/sys/kern/kern_conf.c b/sys/kern/kern_conf.c
index 5e3022e..21052f1 100644
--- a/sys/kern/kern_conf.c
+++ b/sys/kern/kern_conf.c
@@ -64,8 +64,6 @@ static LIST_HEAD(, cdev) dev_hash[DEVT_HASH];
static LIST_HEAD(, cdev) dev_free;
-static int ready_for_devs;
-
static int free_devt;
SYSCTL_INT(_debug, OID_AUTO, free_devt, CTLFLAG_RW, &free_devt, 0, "");
@@ -368,12 +366,6 @@ make_dev(struct cdevsw *devsw, int minor, uid_t uid, gid_t gid, int perms, const
}
}
- if (!ready_for_devs) {
- printf("WARNING: Driver mistake: make_dev(%s) called before SI_SUB_DRIVERS\n",
- fmt);
- /* XXX panic here once drivers are cleaned up */
- }
-
dev = makedev(devsw->d_maj, minor);
if (dev->si_flags & SI_CHEAPCLONE &&
dev->si_flags & SI_NAMED &&
@@ -553,14 +545,3 @@ sysctl_devname(SYSCTL_HANDLER_ARGS)
SYSCTL_PROC(_kern, OID_AUTO, devname, CTLTYPE_OPAQUE|CTLFLAG_RW|CTLFLAG_ANYBODY,
NULL, 0, sysctl_devname, "", "devname(3) handler");
-
-/*
- * Set ready_for_devs; prior to this point, device creation is not allowed.
- */
-static void
-dev_set_ready(void *junk)
-{
- ready_for_devs = 1;
-}
-
-SYSINIT(dev_ready, SI_SUB_DEVFS, SI_ORDER_FIRST, dev_set_ready, NULL);
OpenPOWER on IntegriCloud