init_main.c (91066) | init_main.c (91140) |
---|---|
1/* 2 * Copyright (c) 1995 Terrence R. Lambert 3 * All rights reserved. 4 * 5 * Copyright (c) 1982, 1986, 1989, 1991, 1992, 1993 6 * The Regents of the University of California. All rights reserved. 7 * (c) UNIX System Laboratories, Inc. 8 * All or some portions of this file are derived from material licensed --- 25 unchanged lines hidden (view full) --- 34 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 35 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 36 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 37 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 38 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 39 * SUCH DAMAGE. 40 * 41 * @(#)init_main.c 8.9 (Berkeley) 1/21/94 | 1/* 2 * Copyright (c) 1995 Terrence R. Lambert 3 * All rights reserved. 4 * 5 * Copyright (c) 1982, 1986, 1989, 1991, 1992, 1993 6 * The Regents of the University of California. All rights reserved. 7 * (c) UNIX System Laboratories, Inc. 8 * All or some portions of this file are derived from material licensed --- 25 unchanged lines hidden (view full) --- 34 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 35 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 36 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 37 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 38 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 39 * SUCH DAMAGE. 40 * 41 * @(#)init_main.c 8.9 (Berkeley) 1/21/94 |
42 * $FreeBSD: head/sys/kern/init_main.c 91066 2002-02-22 13:32:01Z phk $ | 42 * $FreeBSD: head/sys/kern/init_main.c 91140 2002-02-23 11:12:57Z tanimura $ |
43 */ 44 45#include "opt_init_path.h" 46 47#include <sys/param.h> 48#include <sys/kernel.h> 49#include <sys/file.h> 50#include <sys/filedesc.h> --- 249 unchanged lines hidden (view full) --- 300 */ 301 vm_init2(); 302 303 /* 304 * Create process 0 (the swapper). 305 */ 306 LIST_INSERT_HEAD(&allproc, p, p_list); 307 LIST_INSERT_HEAD(PIDHASH(0), p, p_hash); | 43 */ 44 45#include "opt_init_path.h" 46 47#include <sys/param.h> 48#include <sys/kernel.h> 49#include <sys/file.h> 50#include <sys/filedesc.h> --- 249 unchanged lines hidden (view full) --- 300 */ 301 vm_init2(); 302 303 /* 304 * Create process 0 (the swapper). 305 */ 306 LIST_INSERT_HEAD(&allproc, p, p_list); 307 LIST_INSERT_HEAD(PIDHASH(0), p, p_hash); |
308 mtx_init(&pgrp0.pg_mtx, "process group", MTX_DEF); |
|
308 p->p_pgrp = &pgrp0; 309 LIST_INSERT_HEAD(PGRPHASH(0), &pgrp0, pg_hash); 310 LIST_INIT(&pgrp0.pg_members); 311 LIST_INSERT_HEAD(&pgrp0.pg_members, p, p_pglist); 312 313 pgrp0.pg_session = &session0; | 309 p->p_pgrp = &pgrp0; 310 LIST_INSERT_HEAD(PGRPHASH(0), &pgrp0, pg_hash); 311 LIST_INIT(&pgrp0.pg_members); 312 LIST_INSERT_HEAD(&pgrp0.pg_members, p, p_pglist); 313 314 pgrp0.pg_session = &session0; |
315 mtx_init(&session0.s_mtx, "session", MTX_DEF); |
|
314 session0.s_count = 1; 315 session0.s_leader = p; 316 317#ifdef __ELF__ 318 p->p_sysent = &elf_freebsd_sysvec; 319#else 320 p->p_sysent = &aout_sysvec; 321#endif --- 333 unchanged lines hidden --- | 316 session0.s_count = 1; 317 session0.s_leader = p; 318 319#ifdef __ELF__ 320 p->p_sysent = &elf_freebsd_sysvec; 321#else 322 p->p_sysent = &aout_sysvec; 323#endif --- 333 unchanged lines hidden --- |