summaryrefslogtreecommitdiffstats
path: root/sys/vm/vm_swap.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>1997-08-31 07:32:39 +0000
committerphk <phk@FreeBSD.org>1997-08-31 07:32:39 +0000
commit0b3a12b83eb2feac881bc220304736c7fc61556a (patch)
treecdd844c554de3bb51aaf1b188cf99f92ac8467ee /sys/vm/vm_swap.c
parent2fd4aa4ddff6800e1a692d84c9a3fbf1ef3df97a (diff)
downloadFreeBSD-src-0b3a12b83eb2feac881bc220304736c7fc61556a.zip
FreeBSD-src-0b3a12b83eb2feac881bc220304736c7fc61556a.tar.gz
Change the 0xdeadb hack to a flag called VDOOMED.
Introduce VFREE which indicates that vnode is on freelist. Rename vholdrele() to vdrop(). Create vfree() and vbusy() to add/delete vnode from freelist. Add vfree()/vbusy() to keep (v_holdcnt != 0 || v_usecount != 0) vnodes off the freelist. Generalize vhold()/v_holdcnt to mean "do not recycle". Fix reassignbuf()s lack of use of vhold(). Use vhold() instead of checking v_cache_src list. Remove vtouch(), the vnodes are always vget'ed soon enough after for it to have any measuable effect. Add sysctl debug.freevnodes to keep track of things. Move cache_purge() up in getnewvnodes to avoid race. Decrement v_usecount after VOP_INACTIVE(), put a vhold() on it during VOP_INACTIVE() Unmacroize vhold()/vdrop() Print out VDOOMED and VFREE flags (XXX: should use %b) Reviewed by: dyson
Diffstat (limited to 'sys/vm/vm_swap.c')
-rw-r--r--sys/vm/vm_swap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/vm/vm_swap.c b/sys/vm/vm_swap.c
index 6082278..9fc4935 100644
--- a/sys/vm/vm_swap.c
+++ b/sys/vm/vm_swap.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)vm_swap.c 8.5 (Berkeley) 2/17/94
- * $Id: vm_swap.c,v 1.42 1997/02/22 09:48:40 peter Exp $
+ * $Id: vm_swap.c,v 1.43 1997/03/23 03:37:54 bde Exp $
*/
#include <sys/param.h>
@@ -136,7 +136,7 @@ swstrategy(bp)
biodone(bp);
return;
}
- VHOLD(sp->sw_vp);
+ vhold(sp->sw_vp);
if ((bp->b_flags & B_READ) == 0) {
vp = bp->b_vp;
if (vp) {
OpenPOWER on IntegriCloud