summaryrefslogtreecommitdiffstats
path: root/sys/fs/coda/coda_subr.c
diff options
context:
space:
mode:
authorkan <kan@FreeBSD.org>2003-11-05 04:30:08 +0000
committerkan <kan@FreeBSD.org>2003-11-05 04:30:08 +0000
commit36d60f3bb735f38bbec69f4cc40ef27a24629c54 (patch)
treed6d549e791dd7c4a627af5beb25ec44a2fcdd02d /sys/fs/coda/coda_subr.c
parent932794c27cf2ec2241eadf3b4891463fa9eb2432 (diff)
downloadFreeBSD-src-36d60f3bb735f38bbec69f4cc40ef27a24629c54.zip
FreeBSD-src-36d60f3bb735f38bbec69f4cc40ef27a24629c54.tar.gz
Remove mntvnode_mtx and replace it with per-mountpoint mutex.
Introduce two new macros MNT_ILOCK(mp)/MNT_IUNLOCK(mp) to operate on this mutex transparently. Eventually new mutex will be protecting more fields in struct mount, not only vnode list. Discussed with: jeff
Diffstat (limited to 'sys/fs/coda/coda_subr.c')
-rw-r--r--sys/fs/coda/coda_subr.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/fs/coda/coda_subr.c b/sys/fs/coda/coda_subr.c
index e3999d3..7a192f1 100644
--- a/sys/fs/coda/coda_subr.c
+++ b/sys/fs/coda/coda_subr.c
@@ -307,12 +307,12 @@ coda_unmounting(whoIam)
void
coda_checkunmounting(mp)
struct mount *mp;
-{
+{
register struct vnode *vp, *nvp;
struct cnode *cp;
int count = 0, bad = 0;
- mtx_lock(&mntvnode_mtx);
+ MNT_ILOCK(mp);
for (vp = TAILQ_FIRST(&mp->mnt_nvnodelist); vp; vp = nvp) {
nvp = TAILQ_NEXT(vp, v_nmntvnodes);
if (vp->v_mount != mp)
@@ -331,7 +331,7 @@ coda_checkunmounting(mp)
}
VI_UNLOCK(vp);
}
- mtx_unlock(&mntvnode_mtx);
+ MNT_IUNLOCK(mp);
}
void
OpenPOWER on IntegriCloud