diff options
author | peter <peter@FreeBSD.org> | 1999-07-01 18:27:15 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 1999-07-01 18:27:15 +0000 |
commit | 65a02b75eaf2e2268c0d1c8fdf642bfada3f1154 (patch) | |
tree | c66b03cc1cc1ae813ecc193813b8f1e8e63b961b /sys/amd64 | |
parent | 56161029de9497ca5c9fc5ed2c74778324a869b0 (diff) | |
download | FreeBSD-src-65a02b75eaf2e2268c0d1c8fdf642bfada3f1154.zip FreeBSD-src-65a02b75eaf2e2268c0d1c8fdf642bfada3f1154.tar.gz |
Move kern_envp and preload initialization a little earlier so that we
can do a getenv_int() inside the memory sizing routines to override the
memory limit.
Diffstat (limited to 'sys/amd64')
-rw-r--r-- | sys/amd64/amd64/machdep.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/sys/amd64/amd64/machdep.c b/sys/amd64/amd64/machdep.c index 48b82fd..0ff0796 100644 --- a/sys/amd64/amd64/machdep.c +++ b/sys/amd64/amd64/machdep.c @@ -35,7 +35,7 @@ * SUCH DAMAGE. * * from: @(#)machdep.c 7.4 (Berkeley) 6/3/91 - * $Id: machdep.c,v 1.344 1999/06/24 20:53:24 jlemon Exp $ + * $Id: machdep.c,v 1.345 1999/06/28 15:34:54 luoqi Exp $ */ #include "apm.h" @@ -1521,6 +1521,13 @@ init386(first) atdevbase = ISA_HOLE_START + KERNBASE; + if (bootinfo.bi_modulep) { + preload_metadata = (caddr_t)bootinfo.bi_modulep + KERNBASE; + preload_bootstrap_relocate(KERNBASE); + } + if (bootinfo.bi_envp) + kern_envp = (caddr_t)bootinfo.bi_envp + KERNBASE; + /* * make gdt memory segments, the code segment goes up to end of the * page with etext in it, the data segment goes to the end of @@ -1700,14 +1707,6 @@ init386(first) proc0.p_addr->u_pcb.pcb_mpnest = 1; #endif proc0.p_addr->u_pcb.pcb_ext = 0; - - /* Sigh, relocate physical addresses left from bootstrap */ - if (bootinfo.bi_modulep) { - preload_metadata = (caddr_t)bootinfo.bi_modulep + KERNBASE; - preload_bootstrap_relocate(KERNBASE); - } - if (bootinfo.bi_envp) - kern_envp = (caddr_t)bootinfo.bi_envp + KERNBASE; } #if defined(I586_CPU) && !defined(NO_F00F_HACK) |