summaryrefslogtreecommitdiffstats
path: root/sys/kern
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1999-04-06 03:03:34 +0000
committerpeter <peter@FreeBSD.org>1999-04-06 03:03:34 +0000
commit8cc7f5626955ccd3a683d4c44a63c9f6019a23cd (patch)
tree77a4305e614d77b938ca571032e575a4fcfbf6f4 /sys/kern
parent28b4daeeaecf4755af70763ca53cf26df2947656 (diff)
downloadFreeBSD-src-8cc7f5626955ccd3a683d4c44a63c9f6019a23cd.zip
FreeBSD-src-8cc7f5626955ccd3a683d4c44a63c9f6019a23cd.tar.gz
Use the reference-counted PHOLD()/PRELE() rather than P_NOSWAP.
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/kern_fork.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/kern/kern_fork.c b/sys/kern/kern_fork.c
index 2877636..c5d9e6c 100644
--- a/sys/kern/kern_fork.c
+++ b/sys/kern/kern_fork.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_fork.c 8.6 (Berkeley) 4/8/94
- * $Id: kern_fork.c,v 1.55 1999/01/26 02:38:10 julian Exp $
+ * $Id: kern_fork.c,v 1.56 1999/03/02 00:28:08 julian Exp $
*/
#include "opt_ktrace.h"
@@ -439,7 +439,7 @@ again:
* This begins the section where we must prevent the parent
* from being swapped.
*/
- p1->p_flag |= P_NOSWAP;
+ PHOLD(p1);
/*
* Finish creating the child process. It will return via a different
@@ -470,7 +470,7 @@ again:
/*
* Now can be swapped.
*/
- p1->p_flag &= ~P_NOSWAP;
+ PRELE(p1);
/*
* Preserve synchronization semantics of vfork. If waiting for
OpenPOWER on IntegriCloud