summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordrahn <drahn@openbsd.org>2001-01-18 23:00:42 +0000
committerdrahn <drahn@openbsd.org>2001-01-18 23:00:42 +0000
commit5fce6f270ea7b68af825bbce164e51d617c80dc1 (patch)
treecf8d56a5dbb14e94e391d101999d5ebdee3d1511
parentFix RADIUS ports, per RFCs 2865/2866 (linuxfreak@partition.com) (diff)
downloadwireguard-openbsd-5fce6f270ea7b68af825bbce164e51d617c80dc1.tar.xz
wireguard-openbsd-5fce6f270ea7b68af825bbce164e51d617c80dc1.zip
Support more than 256MB of physical memory.
Other pieces of the kernel need to be reviewed that 256+MB does not cause other problems with the kernel accessing memory via user sr registers, instead of via the BAT registers. when in kernel context, segment registers 0-7 should _NOT_ have user mappings in them.
-rw-r--r--sys/arch/powerpc/powerpc/machdep.c28
1 files changed, 17 insertions, 11 deletions
diff --git a/sys/arch/powerpc/powerpc/machdep.c b/sys/arch/powerpc/powerpc/machdep.c
index 3e80964a191..d15f6d09c3e 100644
--- a/sys/arch/powerpc/powerpc/machdep.c
+++ b/sys/arch/powerpc/powerpc/machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: machdep.c,v 1.50 2000/10/27 00:16:17 mickey Exp $ */
+/* $OpenBSD: machdep.c,v 1.51 2001/01/18 23:00:42 drahn Exp $ */
/* $NetBSD: machdep.c,v 1.4 1996/10/16 19:33:11 ws Exp $ */
/*
@@ -198,7 +198,22 @@ where = 3;
battable[0].batl = BATL(0x00000000, BAT_M);
battable[0].batu = BATU(0x00000000);
-#if 1
+ /* map all of possible physical memory, ick */
+ battable[0x1].batl = BATL(0x10000000, BAT_M);
+ battable[0x1].batu = BATU(0x10000000);
+ battable[0x2].batl = BATL(0x20000000, BAT_M);
+ battable[0x2].batu = BATU(0x20000000);
+ battable[0x3].batl = BATL(0x30000000, BAT_M);
+ battable[0x3].batu = BATU(0x30000000);
+ battable[0x4].batl = BATL(0x40000000, BAT_M);
+ battable[0x4].batu = BATU(0x40000000);
+ battable[0x5].batl = BATL(0x50000000, BAT_M);
+ battable[0x5].batu = BATU(0x50000000);
+ battable[0x6].batl = BATL(0x60000000, BAT_M);
+ battable[0x6].batu = BATU(0x60000000);
+ battable[0x7].batl = BATL(0x70000000, BAT_M);
+ battable[0x7].batu = BATU(0x70000000);
+
battable[0x8].batl = BATL(0x80000000, BAT_I);
battable[0x8].batu = BATU(0x80000000);
battable[0x9].batl = BATL(0x90000000, BAT_I);
@@ -206,15 +221,6 @@ where = 3;
battable[0xa].batl = BATL(0xa0000000, BAT_I);
battable[0xa].batu = BATU(0xa0000000);
segment8_a_mapped = 1;
-#if 0
- if(system_type == POWER4e) {
- /* Map ISA I/O */
- addbatmap(MPC106_V_ISA_IO_SPACE, MPC106_P_ISA_IO_SPACE, BAT_I);
- battable[1].batl = BATL(0xbfffe000, BAT_I);
- battable[1].batu = BATU(0xbfffe000);
- }
-#endif
-#endif
/*
* Now setup fixed bat registers