diff options
author | phk <phk@FreeBSD.org> | 1999-11-20 10:00:46 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1999-11-20 10:00:46 +0000 |
commit | 1adcecffd93c2f4536a5031426a753b1218ed88a (patch) | |
tree | c111db9be70768372eebad9bfc9cbe47bb8a0a9d /sys/fs | |
parent | 5354776cb2ed414ffde1c1fe64dec67336140a07 (diff) | |
download | FreeBSD-src-1adcecffd93c2f4536a5031426a753b1218ed88a.zip FreeBSD-src-1adcecffd93c2f4536a5031426a753b1218ed88a.tar.gz |
struct mountlist and struct mount.mnt_list have no business being
a CIRCLEQ. Change them to TAILQ_HEAD and TAILQ_ENTRY respectively.
This removes ugly mp != (void*)&mountlist comparisons.
Requested by: phk
Submitted by: Jake Burkholder jake@checker.org
PR: 14967
Diffstat (limited to 'sys/fs')
-rw-r--r-- | sys/fs/coda/coda_vfsops.c | 7 | ||||
-rw-r--r-- | sys/fs/msdosfs/msdosfs_vfsops.c | 2 |
2 files changed, 4 insertions, 5 deletions
diff --git a/sys/fs/coda/coda_vfsops.c b/sys/fs/coda/coda_vfsops.c index 22808ed..229822a 100644 --- a/sys/fs/coda/coda_vfsops.c +++ b/sys/fs/coda/coda_vfsops.c @@ -507,10 +507,9 @@ getNewVnode(vpp) struct mount *devtomp(dev) dev_t dev; { - struct mount *mp, *nmp; - - for (mp = mountlist.cqh_first; mp != (void*)&mountlist; mp = nmp) { - nmp = mp->mnt_list.cqe_next; + struct mount *mp; + + TAILQ_FOREACH(mp, &mountlist, mnt_list) { if (((VFSTOUFS(mp))->um_dev == dev)) { /* mount corresponds to UFS and the device matches one we want */ return(mp); diff --git a/sys/fs/msdosfs/msdosfs_vfsops.c b/sys/fs/msdosfs/msdosfs_vfsops.c index efece99..5005de3 100644 --- a/sys/fs/msdosfs/msdosfs_vfsops.c +++ b/sys/fs/msdosfs/msdosfs_vfsops.c @@ -188,7 +188,7 @@ msdosfs_mountroot() return (error); } - CIRCLEQ_INSERT_TAIL(&mountlist, mp, mnt_list); + TAILQ_INSERT_TAIL(&mountlist, mp, mnt_list); mp->mnt_vnodecovered = NULLVP; (void) copystr("/", mp->mnt_stat.f_mntonname, MNAMELEN - 1, &size); |