diff options
| author | John Baldwin <jhb@FreeBSD.org> | 2001-01-24 12:23:17 +0000 | 
|---|---|---|
| committer | John Baldwin <jhb@FreeBSD.org> | 2001-01-24 12:23:17 +0000 | 
| commit | 69b40456576eda9dd4dbcdc186e4a7f4020d8906 (patch) | |
| tree | 170c791c7d239a2e659627cfd5d0fc6ea1e8a994 | |
| parent | f6f24f55c3eb6861adef29b7698a30e15517a10c (diff) | |
Notes
| -rw-r--r-- | sys/vm/vm_glue.c | 19 | 
1 files changed, 9 insertions, 10 deletions
diff --git a/sys/vm/vm_glue.c b/sys/vm/vm_glue.c index 6e6f79859437..f91540306158 100644 --- a/sys/vm/vm_glue.c +++ b/sys/vm/vm_glue.c @@ -448,20 +448,19 @@ retry:  		struct vmspace *vm;  		PROC_LOCK(p); -		if (!(p->p_lock == 0 && -		    (p->p_flag & (P_TRACED|P_SYSTEM|P_WEXIT)) == 0)) { -			mtx_enter(&sched_lock, MTX_SPIN); -			if ((p->p_sflag & (PS_INMEM|PS_SWAPPING)) == PS_INMEM) { -				mtx_exit(&sched_lock, MTX_SPIN); -				PROC_UNLOCK(p); -				continue; -			} -			mtx_exit(&sched_lock, MTX_SPIN); +		if (p->p_lock != 0 || +		    (p->p_flag & (P_TRACED|P_SYSTEM|P_WEXIT)) != 0) { +			PROC_UNLOCK(p); +			continue;  		}  		vm = p->p_vmspace;  		PROC_UNLOCK(p); -  		mtx_enter(&sched_lock, MTX_SPIN); +		if ((p->p_sflag & (PS_INMEM|PS_SWAPPING)) != PS_INMEM) { +			mtx_exit(&sched_lock, MTX_SPIN); +			continue; +		} +  		switch (p->p_stat) {  		default:  			mtx_exit(&sched_lock, MTX_SPIN);  | 
