summaryrefslogtreecommitdiffstats
path: root/sys/vm
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2003-04-23 18:21:41 +0000
committerjhb <jhb@FreeBSD.org>2003-04-23 18:21:41 +0000
commit485007051ab7027550f5cf7b6684707536004dcc (patch)
treebb2139ccb5ea6d40a250b0c2aba24ada42e8178d /sys/vm
parent3df03e83166dcc7271c926fb3323d633ffdc6209 (diff)
downloadFreeBSD-src-485007051ab7027550f5cf7b6684707536004dcc.zip
FreeBSD-src-485007051ab7027550f5cf7b6684707536004dcc.tar.gz
Fix compiling in the NO_SWAPPING case.
Submitted by: bde (partially)
Diffstat (limited to 'sys/vm')
-rw-r--r--sys/vm/vm_glue.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/sys/vm/vm_glue.c b/sys/vm/vm_glue.c
index 1edd45c..e211e5d 100644
--- a/sys/vm/vm_glue.c
+++ b/sys/vm/vm_glue.c
@@ -513,14 +513,16 @@ void
faultin(p)
struct proc *p;
{
- struct thread *td;
+#ifdef NO_SWAPPING
- GIANT_REQUIRED;
PROC_LOCK_ASSERT(p, MA_OWNED);
-#ifdef NO_SWAPPING
if ((p->p_sflag & PS_INMEM) == 0)
panic("faultin: proc swapped out with NO_SWAPPING!");
-#else
+#else /* !NO_SWAPPING */
+ struct thread *td;
+
+ GIANT_REQUIRED;
+ PROC_LOCK_ASSERT(p, MA_OWNED);
/*
* If another process is swapping in this process,
* just wait until it finishes.
@@ -558,7 +560,7 @@ faultin(p)
/* Allow other threads to swap p out now. */
--p->p_lock;
}
-#endif
+#endif /* NO_SWAPPING */
}
/*
OpenPOWER on IntegriCloud