Move the initailization of the proc lock for proc0 very early into the MD

startup code.
This commit is contained in:
John Baldwin 2001-02-09 16:25:16 +00:00
parent a91fe908db
commit 929604ec9b
7 changed files with 6 additions and 1 deletions

View File

@ -1012,6 +1012,7 @@ alpha_init(pfn, ptb, bim, bip, biv)
*/ */
mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE); mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE);
mtx_init(&sched_lock, "sched lock", MTX_SPIN | MTX_RECURSE); mtx_init(&sched_lock, "sched lock", MTX_SPIN | MTX_RECURSE);
mtx_init(&proc0.p_mtx, "process lock", MTX_DEF);
mtx_lock(&Giant); mtx_lock(&Giant);
/* /*

View File

@ -1910,6 +1910,7 @@ init386(first)
* Giant is used early for at least debugger traps and unexpected traps. * Giant is used early for at least debugger traps and unexpected traps.
*/ */
mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE); mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE);
mtx_init(&proc0.p_mtx, "process lock", MTX_DEF);
mtx_lock(&Giant); mtx_lock(&Giant);
/* make ldt memory segments */ /* make ldt memory segments */

View File

@ -1910,6 +1910,7 @@ init386(first)
* Giant is used early for at least debugger traps and unexpected traps. * Giant is used early for at least debugger traps and unexpected traps.
*/ */
mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE); mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE);
mtx_init(&proc0.p_mtx, "process lock", MTX_DEF);
mtx_lock(&Giant); mtx_lock(&Giant);
/* make ldt memory segments */ /* make ldt memory segments */

View File

@ -597,6 +597,7 @@ ia64_init()
*/ */
mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE); mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE);
mtx_init(&sched_lock, "sched lock", MTX_SPIN | MTX_RECURSE); mtx_init(&sched_lock, "sched lock", MTX_SPIN | MTX_RECURSE);
mtx_init(&proc0.p_mtx, "process lock", MTX_DEF);
mtx_lock(&Giant); mtx_lock(&Giant);
/* /*

View File

@ -285,7 +285,6 @@ proc0_init(void *dummy __unused)
/* /*
* Create process 0 (the swapper). * Create process 0 (the swapper).
*/ */
mtx_init(&p->p_mtx, "process lock", MTX_DEF);
LIST_INSERT_HEAD(&allproc, p, p_list); LIST_INSERT_HEAD(&allproc, p, p_list);
p->p_pgrp = &pgrp0; p->p_pgrp = &pgrp0;
LIST_INSERT_HEAD(PGRPHASH(0), &pgrp0, pg_hash); LIST_INSERT_HEAD(PGRPHASH(0), &pgrp0, pg_hash);

View File

@ -2219,6 +2219,7 @@ init386(first)
* Giant is used early for at least debugger traps and unexpected traps. * Giant is used early for at least debugger traps and unexpected traps.
*/ */
mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE); mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE);
mtx_init(&proc0.p_mtx, "process lock", MTX_DEF);
mtx_lock(&Giant); mtx_lock(&Giant);
/* make ldt memory segments */ /* make ldt memory segments */

View File

@ -2219,6 +2219,7 @@ init386(first)
* Giant is used early for at least debugger traps and unexpected traps. * Giant is used early for at least debugger traps and unexpected traps.
*/ */
mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE); mtx_init(&Giant, "Giant", MTX_DEF | MTX_RECURSE);
mtx_init(&proc0.p_mtx, "process lock", MTX_DEF);
mtx_lock(&Giant); mtx_lock(&Giant);
/* make ldt memory segments */ /* make ldt memory segments */