summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/arch/i386/i386/autoconf.c7
-rw-r--r--sys/arch/i386/i386/gdt.c7
-rw-r--r--sys/arch/i386/i386/machdep.c3
3 files changed, 10 insertions, 7 deletions
diff --git a/sys/arch/i386/i386/autoconf.c b/sys/arch/i386/i386/autoconf.c
index 3ba2e618dad..5f51e92398f 100644
--- a/sys/arch/i386/i386/autoconf.c
+++ b/sys/arch/i386/i386/autoconf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: autoconf.c,v 1.41 2001/12/10 00:58:04 miod Exp $ */
+/* $OpenBSD: autoconf.c,v 1.42 2002/01/09 23:08:34 nordin Exp $ */
/* $NetBSD: autoconf.c,v 1.20 1996/05/03 19:41:56 christos Exp $ */
/*-
@@ -56,8 +56,11 @@
#include <sys/reboot.h>
#include <sys/device.h>
+#include <uvm/uvm_extern.h>
+
#include <machine/pte.h>
#include <machine/cpu.h>
+#include <machine/gdt.h>
#include <machine/biosvar.h>
#include <dev/cons.h>
@@ -86,6 +89,8 @@ cpu_configure()
startrtclock();
+ gdt_init(); /* XXX - pcibios uses gdt stuff */
+
if (config_rootfound("mainbus", NULL) == NULL)
panic("cpu_configure: mainbus not configured");
diff --git a/sys/arch/i386/i386/gdt.c b/sys/arch/i386/i386/gdt.c
index 2950959304f..e40401e4e6b 100644
--- a/sys/arch/i386/i386/gdt.c
+++ b/sys/arch/i386/i386/gdt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: gdt.c,v 1.17 2001/11/06 19:53:14 miod Exp $ */
+/* $OpenBSD: gdt.c,v 1.18 2002/01/09 23:08:34 nordin Exp $ */
/* $NetBSD: gdt.c,v 1.8 1996/05/03 19:42:06 christos Exp $ */
/*-
@@ -222,9 +222,8 @@ gdt_get_slot()
if (gdt_size >= MAXGDTSIZ)
panic("gdt_get_slot botch 2");
if (dynamic_gdt == gdt)
- gdt_init();
- else
- gdt_grow();
+ panic("gdt_get_slot called before gdt_init");
+ gdt_grow();
}
slot = gdt_next++;
}
diff --git a/sys/arch/i386/i386/machdep.c b/sys/arch/i386/i386/machdep.c
index 5686edeb4b4..33a9d7af2f9 100644
--- a/sys/arch/i386/i386/machdep.c
+++ b/sys/arch/i386/i386/machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: machdep.c,v 1.190 2001/12/14 08:35:12 niklas Exp $ */
+/* $OpenBSD: machdep.c,v 1.191 2002/01/09 23:08:34 nordin Exp $ */
/* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */
/*-
@@ -432,7 +432,6 @@ i386_proc0_tss_ldt_init()
struct pcb *pcb;
int x;
- gdt_init();
curpcb = pcb = &proc0.p_addr->u_pcb;
pcb->pcb_flags = 0;
pcb->pcb_tss.tss_ioopt =