diff options
| author | Poul-Henning Kamp <phk@FreeBSD.org> | 2003-01-19 11:03:07 +0000 |
|---|---|---|
| committer | Poul-Henning Kamp <phk@FreeBSD.org> | 2003-01-19 11:03:07 +0000 |
| commit | 7e760e148a2caa4873b7aeddbeab49b52b74b1ac (patch) | |
| tree | a1836e6e7bd999b9e7099048c5c2bd9535ef95cd /sys/kern/init_main.c | |
| parent | 87d35aadd9d2874910b7b34e0724b0eef50df84f (diff) | |
Notes
Diffstat (limited to 'sys/kern/init_main.c')
| -rw-r--r-- | sys/kern/init_main.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c index 354536fd6a32..74424ccd41b2 100644 --- a/sys/kern/init_main.c +++ b/sys/kern/init_main.c @@ -554,21 +554,21 @@ start_init(void *dummy) mac_create_root_mount(td->td_ucred, TAILQ_FIRST(&mountlist)); #endif - if (devfs_present) { - /* - * For disk based systems, we probably cannot do this yet - * since the fs will be read-only. But a NFS root - * might be ok. It is worth a shot. - */ - error = kern_mkdir(td, "/dev", UIO_SYSSPACE, 0700); - if (error == EEXIST) - error = 0; - if (error == 0) - error = kernel_vmount(0, "fstype", "devfs", - "fspath", "/dev", NULL); - if (error != 0) - init_does_devfs = 1; - } +#ifndef NODEVFS + /* + * For disk based systems, we probably cannot do this yet + * since the fs will be read-only. But a NFS root + * might be ok. It is worth a shot. + */ + error = kern_mkdir(td, "/dev", UIO_SYSSPACE, 0700); + if (error == EEXIST) + error = 0; + if (error == 0) + error = kernel_vmount(0, "fstype", "devfs", + "fspath", "/dev", NULL); + if (error != 0) + init_does_devfs = 1; +#endif /* * Need just enough stack to hold the faked-up "execve()" arguments. |
