diff options
author | Tom Cosgrove <tom@cvs.openbsd.org> | 2007-04-24 12:58:51 +0000 |
---|---|---|
committer | Tom Cosgrove <tom@cvs.openbsd.org> | 2007-04-24 12:58:51 +0000 |
commit | 02ffd327f2c6cbba4ffd7a6d715da17afab62d8e (patch) | |
tree | a65cc12c92574e0c8cae8181fecfb0a60fd3b61d /sys | |
parent | a79d1a8ec5e50be34bb29365a2d3de3e368d5643 (diff) |
Use the physical address we have stored for the page directory rather
than calculating it with vtophys().
From mickey's original PAE work of a year ago
Tested by myself and nick@; ok art@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/i386/i386/cpu.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/arch/i386/i386/cpu.c b/sys/arch/i386/i386/cpu.c index aab0c99c860..fe768b73eae 100644 --- a/sys/arch/i386/i386/cpu.c +++ b/sys/arch/i386/i386/cpu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.c,v 1.21 2007/02/20 21:15:01 tom Exp $ */ +/* $OpenBSD: cpu.c,v 1.22 2007/04/24 12:58:50 tom Exp $ */ /* $NetBSD: cpu.c,v 1.1.2.7 2000/06/26 02:04:05 sommerfeld Exp $ */ /*- @@ -248,7 +248,7 @@ cpu_attach(struct device *parent, struct device *self, void *aux) pcb->pcb_tss.tss_esp = kstack + USPACE - 16 - sizeof (struct trapframe); pcb->pcb_pmap = pmap_kernel(); - pcb->pcb_cr3 = vtophys((vaddr_t)pcb->pcb_pmap->pm_pdir); + pcb->pcb_cr3 = pcb->pcb_pmap->pm_pdirpa; /* pcb->pcb_cr3 = pcb->pcb_pmap->pm_pdir - KERNBASE; XXX ??? */ cpu_default_ldt(ci); /* Use the `global' ldt until one alloc'd */ @@ -410,7 +410,7 @@ cpu_boot_secondary(struct cpu_info *ci) printf("%s: starting", ci->ci_dev.dv_xname); /* XXX move elsewhere, not per CPU. */ - mp_pdirpa = vtophys((vaddr_t)kpm->pm_pdir); + mp_pdirpa = kpm->pm_pdirpa; pcb = ci->ci_idle_pcb; |