BSD 4_4 release
[unix-history] / usr / src / sys / kern / vfs_conf.c
index 22448f7..6f785fb 100644 (file)
@@ -1,10 +1,36 @@
 /*
 /*
- * Copyright (c) 1989 The Regents of the University of California.
- * All rights reserved.
+ * Copyright (c) 1989, 1993
+ *     The Regents of the University of California.  All rights reserved.
  *
  *
- * %sccs.include.redist.c%
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ *    must display the following acknowledgement:
+ *     This product includes software developed by the University of
+ *     California, Berkeley and its contributors.
+ * 4. Neither the name of the University nor the names of its contributors
+ *    may be used to endorse or promote products derived from this software
+ *    without specific prior written permission.
  *
  *
- *     @(#)vfs_conf.c  7.14 (Berkeley) %G%
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ *     @(#)vfs_conf.c  8.1 (Berkeley) 6/10/93
  */
 
 #include <sys/param.h>
  */
 
 #include <sys/param.h>
@@ -80,6 +106,28 @@ extern      struct vfsops portal_vfsops;
 #define        PORTAL_VFSOPS   NULL
 #endif
 
 #define        PORTAL_VFSOPS   NULL
 #endif
 
+#ifdef NULLFS
+extern struct vfsops null_vfsops;
+#define NULL_VFSOPS    &null_vfsops
+#else
+#define NULL_VFSOPS    NULL
+#endif
+
+#ifdef UMAPFS
+extern struct vfsops umap_vfsops;
+#define UMAP_VFSOPS    &umap_vfsops
+#else
+#define UMAP_VFSOPS    NULL
+#endif
+
+#ifdef KERNFS
+extern struct vfsops kernfs_vfsops;
+#define KERNFS_VFSOPS  &kernfs_vfsops
+#else
+#define KERNFS_VFSOPS  NULL
+#endif
+
+
 struct vfsops *vfssw[] = {
        NULL,                   /* 0 = MOUNT_NONE */
        UFS_VFSOPS,             /* 1 = MOUNT_UFS */
 struct vfsops *vfssw[] = {
        NULL,                   /* 0 = MOUNT_NONE */
        UFS_VFSOPS,             /* 1 = MOUNT_UFS */
@@ -90,6 +138,10 @@ struct vfsops *vfssw[] = {
        LOFS_VFSOPS,            /* 6 = MOUNT_LOFS */
        FDESC_VFSOPS,           /* 7 = MOUNT_FDESC */
        PORTAL_VFSOPS,          /* 8 = MOUNT_PORTAL */
        LOFS_VFSOPS,            /* 6 = MOUNT_LOFS */
        FDESC_VFSOPS,           /* 7 = MOUNT_FDESC */
        PORTAL_VFSOPS,          /* 8 = MOUNT_PORTAL */
+       NULL_VFSOPS,            /* 9 = MOUNT_NULL */
+       UMAP_VFSOPS,            /* 10 = MOUNT_UMAP */
+       KERNFS_VFSOPS,          /* 11 = MOUNT_KERNFS */
+       0
 };
 
 
 };
 
 
@@ -99,8 +151,6 @@ struct vfsops *vfssw[] = {
  * vnode operation vector.  It is consulted at system boot to build operation
  * vectors.  It is NULL terminated.
  *
  * vnode operation vector.  It is consulted at system boot to build operation
  * vectors.  It is NULL terminated.
  *
- * Out-of-kernel, someone else (more knowlegable about what file systems live
- * in this address space) must specify this table.
  */
 extern struct vnodeopv_desc ffs_vnodeop_opv_desc;
 extern struct vnodeopv_desc ffs_specop_opv_desc;
  */
 extern struct vnodeopv_desc ffs_vnodeop_opv_desc;
 extern struct vnodeopv_desc ffs_specop_opv_desc;
@@ -118,6 +168,9 @@ extern struct vnodeopv_desc fifo_nfsv2nodeop_opv_desc;
 extern struct vnodeopv_desc lofs_vnodeop_opv_desc;
 extern struct vnodeopv_desc fdesc_vnodeop_opv_desc;
 extern struct vnodeopv_desc portal_vnodeop_opv_desc;
 extern struct vnodeopv_desc lofs_vnodeop_opv_desc;
 extern struct vnodeopv_desc fdesc_vnodeop_opv_desc;
 extern struct vnodeopv_desc portal_vnodeop_opv_desc;
+extern struct vnodeopv_desc null_vnodeop_opv_desc;
+extern struct vnodeopv_desc umap_vnodeop_opv_desc;
+extern struct vnodeopv_desc kernfs_vnodeop_opv_desc;
 
 struct vnodeopv_desc *vfs_opv_descs[] = {
        &ffs_vnodeop_opv_desc,
 
 struct vnodeopv_desc *vfs_opv_descs[] = {
        &ffs_vnodeop_opv_desc,
@@ -155,6 +208,15 @@ struct vnodeopv_desc *vfs_opv_descs[] = {
 #endif
 #ifdef PORTAL
        &portal_vnodeop_opv_desc,
 #endif
 #ifdef PORTAL
        &portal_vnodeop_opv_desc,
+#endif
+#ifdef NULLFS
+       &null_vnodeop_opv_desc,
+#endif
+#ifdef UMAPFS
+       &umap_vnodeop_opv_desc,
+#endif
+#ifdef KERNFS
+       &kernfs_vnodeop_opv_desc,
 #endif
        NULL
 };
 #endif
        NULL
 };