From f7e588347b3192f4351b4e27c498cc085021b6e4 Mon Sep 17 00:00:00 2001 From: jeff Date: Wed, 25 Sep 2002 02:32:42 +0000 Subject: - Use vrefcnt() where it is safe to do so instead of doing direct and unlocked accesses to v_usecount. - Lock access to the buf lists in the various sync routines. interlock locking could be avoided almost entirely in leaf filesystems if the fsync function had a generic helper. --- sys/fs/ntfs/ntfs_vnops.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/fs/ntfs/ntfs_vnops.c') diff --git a/sys/fs/ntfs/ntfs_vnops.c b/sys/fs/ntfs/ntfs_vnops.c index fc46617..d46b88b 100644 --- a/sys/fs/ntfs/ntfs_vnops.c +++ b/sys/fs/ntfs/ntfs_vnops.c @@ -196,7 +196,7 @@ ntfs_inactive(ap) dprintf(("ntfs_inactive: vnode: %p, ntnode: %d\n", vp, ip->i_number)); - if (ntfs_prtactive && vp->v_usecount != 0) + if (ntfs_prtactive && vrefcnt(vp) != 0) vprint("ntfs_inactive: pushing active", vp); VOP_UNLOCK(vp, 0, ap->a_td); @@ -223,7 +223,7 @@ ntfs_reclaim(ap) dprintf(("ntfs_reclaim: vnode: %p, ntnode: %d\n", vp, ip->i_number)); - if (ntfs_prtactive && vp->v_usecount != 0) + if (ntfs_prtactive && vrefcnt(vp) != 0) vprint("ntfs_reclaim: pushing active", vp); if ((error = ntfs_ntget(ip)) != 0) -- cgit v1.1