change mountlist to CIRCLEQ so we can do unmountall (from mycroft)
authorKirk McKusick <mckusick@ucbvax.Berkeley.EDU>
Wed, 10 May 1995 03:28:47 +0000 (19:28 -0800)
committerKirk McKusick <mckusick@ucbvax.Berkeley.EDU>
Wed, 10 May 1995 03:28:47 +0000 (19:28 -0800)
SCCS-vsn: sys/isofs/cd9660/cd9660_vfsops.c 8.11
SCCS-vsn: sys/nfs/nfs_vfsops.c 8.8
SCCS-vsn: sys/nfs/nfs_nqlease.c 8.7
SCCS-vsn: sys/ufs/lfs/lfs_bio.c 8.8
SCCS-vsn: sys/ufs/mfs/mfs_vfsops.c 8.6

usr/src/sys/isofs/cd9660/cd9660_vfsops.c
usr/src/sys/nfs/nfs_nqlease.c
usr/src/sys/nfs/nfs_vfsops.c
usr/src/sys/ufs/lfs/lfs_bio.c
usr/src/sys/ufs/mfs/mfs_vfsops.c

index 4c1eb40..5a5e4c6 100644 (file)
@@ -9,7 +9,7 @@
  *
  * %sccs.include.redist.c%
  *
  *
  * %sccs.include.redist.c%
  *
- *     @(#)cd9660_vfsops.c     8.10 (Berkeley) %G%
+ *     @(#)cd9660_vfsops.c     8.11 (Berkeley) %G%
  */
 
 #include <sys/param.h>
  */
 
 #include <sys/param.h>
@@ -91,7 +91,7 @@ cd9660_mountroot()
                free(mp, M_MOUNT);
                return (error);
        }
                free(mp, M_MOUNT);
                return (error);
        }
-       TAILQ_INSERT_TAIL(&mountlist, mp, mnt_list);
+       CIRCLEQ_INSERT_TAIL(&mountlist, mp, mnt_list);
        mp->mnt_flag |= MNT_ROOTFS;
        mp->mnt_vnodecovered = NULLVP;
        imp = VFSTOISOFS(mp);
        mp->mnt_flag |= MNT_ROOTFS;
        mp->mnt_vnodecovered = NULLVP;
        imp = VFSTOISOFS(mp);
index 3c9b1c0..da8ad74 100644 (file)
@@ -7,7 +7,7 @@
  *
  * %sccs.include.redist.c%
  *
  *
  * %sccs.include.redist.c%
  *
- *     @(#)nfs_nqlease.c       8.6 (Berkeley) %G%
+ *     @(#)nfs_nqlease.c       8.7 (Berkeley) %G%
  */
 
 
  */
 
 
@@ -1127,7 +1127,8 @@ nqnfs_lease_updatetime(deltat)
         * Search the mount list for all nqnfs mounts and do their timer
         * queues.
         */
         * Search the mount list for all nqnfs mounts and do their timer
         * queues.
         */
-       for (mp = mountlist.tqh_first; mp != NULL; mp = mp->mnt_list.tqe_next) {
+       for (mp = mountlist.cqh_first; mp != (void *)&mountlist;
+            mp = mp->mnt_list.cqe_next) {
                if (mp->mnt_stat.f_type != nfs_mount_type)
                        continue;
                nmp = VFSTONFS(mp);
                if (mp->mnt_stat.f_type != nfs_mount_type)
                        continue;
                nmp = VFSTONFS(mp);
index ff457bd..3a060e9 100644 (file)
@@ -7,7 +7,7 @@
  *
  * %sccs.include.redist.c%
  *
  *
  * %sccs.include.redist.c%
  *
- *     @(#)nfs_vfsops.c        8.7 (Berkeley) %G%
+ *     @(#)nfs_vfsops.c        8.8 (Berkeley) %G%
  */
 
 #include <sys/param.h>
  */
 
 #include <sys/param.h>
@@ -360,7 +360,7 @@ nfs_mountroot()
 
        if (vfs_lock(mp))
                panic("nfs_mountroot: vfs_lock");
 
        if (vfs_lock(mp))
                panic("nfs_mountroot: vfs_lock");
-       TAILQ_INSERT_TAIL(&mountlist, mp, mnt_list);
+       CIRCLEQ_INSERT_TAIL(&mountlist, mp, mnt_list);
        mp->mnt_flag |= MNT_ROOTFS;
        mp->mnt_vnodecovered = NULLVP;
        vfs_unlock(mp);
        mp->mnt_flag |= MNT_ROOTFS;
        mp->mnt_vnodecovered = NULLVP;
        vfs_unlock(mp);
index dacd1c7..49f8af1 100644 (file)
@@ -4,7 +4,7 @@
  *
  * %sccs.include.redist.c%
  *
  *
  * %sccs.include.redist.c%
  *
- *     @(#)lfs_bio.c   8.7 (Berkeley) %G%
+ *     @(#)lfs_bio.c   8.8 (Berkeley) %G%
  */
 
 #include <sys/param.h>
  */
 
 #include <sys/param.h>
@@ -114,7 +114,8 @@ lfs_flush()
        if (lfs_writing)
                return;
        lfs_writing = 1;
        if (lfs_writing)
                return;
        lfs_writing = 1;
-       for (mp = mountlist.tqh_first; mp != NULL; mp = mp->mnt_list.tqe_next) {
+       for (mp = mountlist.cqh_first; mp != (void *)&mountlist;
+            mp = mp->mnt_list.cqe_next) {
                /* The lock check below is to avoid races with unmount. */
                if (mp->mnt_stat.f_type == lfs_mount_type &&
                    (mp->mnt_flag & (MNT_MLOCK|MNT_RDONLY|MNT_UNMOUNT)) == 0 &&
                /* The lock check below is to avoid races with unmount. */
                if (mp->mnt_stat.f_type == lfs_mount_type &&
                    (mp->mnt_flag & (MNT_MLOCK|MNT_RDONLY|MNT_UNMOUNT)) == 0 &&
index e8fb015..3d47f95 100644 (file)
@@ -4,7 +4,7 @@
  *
  * %sccs.include.redist.c%
  *
  *
  * %sccs.include.redist.c%
  *
- *     @(#)mfs_vfsops.c        8.5 (Berkeley) %G%
+ *     @(#)mfs_vfsops.c        8.6 (Berkeley) %G%
  */
 
 #include <sys/param.h>
  */
 
 #include <sys/param.h>
@@ -102,7 +102,7 @@ mfs_mountroot()
                free(mfsp, M_MFSNODE);
                return (error);
        }
                free(mfsp, M_MFSNODE);
                return (error);
        }
-       TAILQ_INSERT_TAIL(&mountlist, mp, mnt_list);
+       CIRCLEQ_INSERT_TAIL(&mountlist, mp, mnt_list);
        mp->mnt_flag |= MNT_ROOTFS;
        mp->mnt_vnodecovered = NULLVP;
        ump = VFSTOUFS(mp);
        mp->mnt_flag |= MNT_ROOTFS;
        mp->mnt_vnodecovered = NULLVP;
        ump = VFSTOUFS(mp);