1 /* 2 * Copyright (c) 1989 The Regents of the University of California. 3 * All rights reserved. 4 * 5 * %sccs.include.redist.c% 6 * 7 * @(#)vfs_conf.c 7.6 (Berkeley) 02/05/92 8 */ 9 10 #include <sys/param.h> 11 #include <sys/mount.h> 12 13 #ifdef FFS 14 #include <ufs/ffs/ffs_extern.h> 15 16 /* 17 * This specifies the filesystem used to mount the root. 18 * This specification should be done by /etc/config. 19 */ 20 int (*mountroot)() = ffs_mountroot; 21 #endif 22 23 /* 24 * These define the root filesystem and device. 25 */ 26 struct mount *rootfs; 27 struct vnode *rootdir; 28 29 /* 30 * Set up the filesystem operations for vnodes. 31 * The types are defined in mount.h. 32 */ 33 #ifdef FFS 34 extern struct vfsops ufs_vfsops; 35 #define UFS_VFSOPS &ufs_vfsops 36 #else 37 #define UFS_VFSOPS NULL 38 #endif 39 40 #ifdef LFS 41 extern struct vfsops lfs_vfsops; 42 #define LFS_VFSOPS &lfs_vfsops 43 #else 44 #define LFS_VFSOPS NULL 45 #endif 46 47 #ifdef MFS 48 extern struct vfsops mfs_vfsops; 49 #define MFS_VFSOPS &mfs_vfsops 50 #else 51 #define MFS_VFSOPS NULL 52 #endif 53 54 #ifdef NFS 55 extern struct vfsops nfs_vfsops; 56 #define NFS_VFSOPS &nfs_vfsops 57 #else 58 #define NFS_VFSOPS NULL 59 #endif 60 61 struct vfsops *vfssw[] = { 62 NULL, /* 0 = MOUNT_NONE */ 63 UFS_VFSOPS, /* 1 = MOUNT_UFS */ 64 NFS_VFSOPS, /* 2 = MOUNT_NFS */ 65 MFS_VFSOPS, /* 3 = MOUNT_MFS */ 66 NULL, /* 4 = MOUNT_PC */ 67 LFS_VFSOPS, /* 5 = MOUNT_LFS */ 68 }; 69