Deleted Added
full compact
kern_fork.c (195104) kern_fork.c (195741)
1/*-
2 * Copyright (c) 1982, 1986, 1989, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

--- 21 unchanged lines hidden (view full) ---

30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 * SUCH DAMAGE.
33 *
34 * @(#)kern_fork.c 8.6 (Berkeley) 4/8/94
35 */
36
37#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 1982, 1986, 1989, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

--- 21 unchanged lines hidden (view full) ---

30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 * SUCH DAMAGE.
33 *
34 * @(#)kern_fork.c 8.6 (Berkeley) 4/8/94
35 */
36
37#include <sys/cdefs.h>
38__FBSDID("$FreeBSD: head/sys/kern/kern_fork.c 195104 2009-06-27 13:58:44Z rwatson $");
38__FBSDID("$FreeBSD: head/sys/kern/kern_fork.c 195741 2009-07-17 14:48:21Z jamie $");
39
40#include "opt_kdtrace.h"
41#include "opt_ktrace.h"
42
43#include <sys/param.h>
44#include <sys/systm.h>
45#include <sys/sysproto.h>
46#include <sys/eventhandler.h>

--- 15 unchanged lines hidden (view full) ---

62#include <sys/vnode.h>
63#include <sys/acct.h>
64#include <sys/ktr.h>
65#include <sys/ktrace.h>
66#include <sys/unistd.h>
67#include <sys/sdt.h>
68#include <sys/sx.h>
69#include <sys/signalvar.h>
39
40#include "opt_kdtrace.h"
41#include "opt_ktrace.h"
42
43#include <sys/param.h>
44#include <sys/systm.h>
45#include <sys/sysproto.h>
46#include <sys/eventhandler.h>

--- 15 unchanged lines hidden (view full) ---

62#include <sys/vnode.h>
63#include <sys/acct.h>
64#include <sys/ktr.h>
65#include <sys/ktrace.h>
66#include <sys/unistd.h>
67#include <sys/sdt.h>
68#include <sys/sx.h>
69#include <sys/signalvar.h>
70#include <sys/vimage.h>
71
72#include <security/audit/audit.h>
73#include <security/mac/mac_framework.h>
74
75#include <vm/vm.h>
76#include <vm/pmap.h>
77#include <vm/vm_map.h>
78#include <vm/vm_extern.h>

--- 279 unchanged lines hidden (view full) ---

358 goto fail;
359 }
360
361 /*
362 * Increment the nprocs resource before blocking can occur. There
363 * are hard-limits as to the number of processes that can run.
364 */
365 nprocs++;
70
71#include <security/audit/audit.h>
72#include <security/mac/mac_framework.h>
73
74#include <vm/vm.h>
75#include <vm/pmap.h>
76#include <vm/vm_map.h>
77#include <vm/vm_extern.h>

--- 279 unchanged lines hidden (view full) ---

357 goto fail;
358 }
359
360 /*
361 * Increment the nprocs resource before blocking can occur. There
362 * are hard-limits as to the number of processes that can run.
363 */
364 nprocs++;
366#ifdef VIMAGE
367 P_TO_VPROCG(p1)->nprocs++;
368#endif
369
370 /*
371 * Find an unused process ID. We remember a range of unused IDs
372 * ready to use (from lastpid+1 through pidchecked-1).
373 *
374 * If RFHIGHPID is set (used during system boot), do not allocate
375 * low-numbered pids.
376 */

--- 500 unchanged lines hidden ---
365
366 /*
367 * Find an unused process ID. We remember a range of unused IDs
368 * ready to use (from lastpid+1 through pidchecked-1).
369 *
370 * If RFHIGHPID is set (used during system boot), do not allocate
371 * low-numbered pids.
372 */

--- 500 unchanged lines hidden ---