summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_conf.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2003-02-04 10:32:40 +0000
committerphk <phk@FreeBSD.org>2003-02-04 10:32:40 +0000
commit9d6d3f16738b4468cf07e93bd017adae88c16871 (patch)
tree9f5f3c6b75f01b4b8fd3121c797b479bf00e432b /sys/kern/kern_conf.c
parent1abb95308bcc72d0a245f8d4c0f779f3cbe67d90 (diff)
downloadFreeBSD-src-9d6d3f16738b4468cf07e93bd017adae88c16871.zip
FreeBSD-src-9d6d3f16738b4468cf07e93bd017adae88c16871.tar.gz
Pave the road to removing the fixed size limit on device nodes:
Change the si_name of dev_t's to be a char * and put a private buffer for holding the name at then end of the struct. Initialize si_name to point to the private buffer. Put a KASSERT in geom_disk to prevent overrun on the fake dev_t we still have to generate for the disk_drivers.
Diffstat (limited to 'sys/kern/kern_conf.c')
-rw-r--r--sys/kern/kern_conf.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/kern/kern_conf.c b/sys/kern/kern_conf.c
index 6aedd81..e405d11 100644
--- a/sys/kern/kern_conf.c
+++ b/sys/kern/kern_conf.c
@@ -155,6 +155,8 @@ allocdev(void)
bzero(si, sizeof *si);
si->si_flags |= SI_STASHED;
}
+ si->__si_namebuf[0] = '\0';
+ si->si_name = si->__si_namebuf;
LIST_INIT(&si->si_children);
TAILQ_INIT(&si->si_snapshots);
return (si);
OpenPOWER on IntegriCloud