Taking the GENERIC kernel and commenting out MSDOSFS, CD9660{,_ROOT}, PROCFS,

NFS_ROOT will produce kernel that cannot mount a UFS /.

Vfs type numbers must be distinct from VFS_GENERIC (and VFS_VFSCONF, but
that has the same value and should go away).

The problem happens because NFS is the first vfs (in sys/conf order) so it
gets type number 0 and conflicts harmfully with VFS_GENERIC which is also 0.
The conflict is apparently harmless in the usual case when another vfs
gets type number 0, because nfs is the only vfs that has sysctls.

Inital fix by:	Dima <dima@tejblum.dnttm.rssi.ru>
Reason why it worked by:	bde
This commit is contained in:
David E. O'Brien 1998-10-05 11:10:55 +00:00
parent 264ba5c0fe
commit efcddb8e39

View File

@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)vfs_init.c 8.3 (Berkeley) 1/4/94
* $Id: vfs_init.c,v 1.32 1998/02/09 06:09:33 eivind Exp $
* $Id: vfs_init.c,v 1.33 1998/09/05 17:13:27 bde Exp $
*/
@ -249,9 +249,10 @@ vfsinit(dummy)
vfs_opv_init(vfs_opv_descs); /* finish the job */
/*
* Initialize each file system type.
* Vfs type numbers must be distinct from VFS_GENERIC (and VFS_VFSCONF).
*/
vattr_null(&va_null);
maxtypenum = 0;
maxtypenum = VFS_GENERIC + 1;
vfc = (struct vfsconf **)vfs_set.ls_items;
vfsconf = *vfc;
for (; *vfc != NULL; maxtypenum++, vfc++) {