summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/hp300/hp300/pmap_bootstrap.c5
-rw-r--r--sys/arch/mac68k/mac68k/pmap_bootstrap.c27
-rw-r--r--sys/arch/mvme68k/mvme68k/pmap_bootstrap.c4
3 files changed, 11 insertions, 25 deletions
diff --git a/sys/arch/hp300/hp300/pmap_bootstrap.c b/sys/arch/hp300/hp300/pmap_bootstrap.c
index b0a63a57af1..6d2b1477b49 100644
--- a/sys/arch/hp300/hp300/pmap_bootstrap.c
+++ b/sys/arch/hp300/hp300/pmap_bootstrap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap_bootstrap.c,v 1.24 2006/05/19 22:51:07 miod Exp $ */
+/* $OpenBSD: pmap_bootstrap.c,v 1.25 2008/01/04 19:05:30 miod Exp $ */
/* $NetBSD: pmap_bootstrap.c,v 1.13 1997/06/10 18:56:50 veego Exp $ */
/*
@@ -88,8 +88,7 @@ do { \
#define PMAP_MD_MEMSIZE() \
do { \
- RELOC(avail_end, paddr_t) = MAXADDR - \
- (round_page(MSGBUFSIZE) + ptoa(1)); \
+ RELOC(avail_end, paddr_t) = MAXADDR - round_page(MSGBUFSIZE); \
} while (0)
/*
diff --git a/sys/arch/mac68k/mac68k/pmap_bootstrap.c b/sys/arch/mac68k/mac68k/pmap_bootstrap.c
index 2a8e4a8dc48..b1c0ecb3352 100644
--- a/sys/arch/mac68k/mac68k/pmap_bootstrap.c
+++ b/sys/arch/mac68k/mac68k/pmap_bootstrap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap_bootstrap.c,v 1.39 2007/11/02 19:18:54 martin Exp $ */
+/* $OpenBSD: pmap_bootstrap.c,v 1.40 2008/01/04 19:05:32 miod Exp $ */
/* $NetBSD: pmap_bootstrap.c,v 1.50 1999/04/07 06:14:33 scottr Exp $ */
/*
@@ -109,8 +109,6 @@ void bootstrap_mac68k(int);
#define PMAP_MD_LOCALS \
paddr_t vidpa; \
paddr_t avail_next; \
- int avail_remaining; \
- int avail_range; \
int i; \
\
vidlen = round_page(((videosize >> 16) & 0xffff) * videorowbytes + \
@@ -153,27 +151,16 @@ do { \
} while (0)
/*
- * If the MMU was disabled, compute available memory size from the memory
- * segment information.
+ * Compute memory size from the memory segment information.
*/
#define PMAP_MD_MEMSIZE() \
do { \
avail_next = avail_start; \
- avail_remaining = 0; \
- avail_range = -1; \
- for (i = 0; i < numranges; i++) { \
- if (low[i] <= avail_next && avail_next < high[i]) { \
- avail_range = i; \
- avail_remaining = high[i] - avail_next; \
- } else if (avail_range != -1) { \
- avail_remaining += (high[i] - low[i]); \
- } \
- } \
- physmem = atop(avail_remaining + nextpa - firstpa); \
- \
- maxaddr = high[numranges - 1] - ptoa(1); \
- high[numranges - 1] -= \
- (round_page(MSGBUFSIZE) + ptoa(1)); \
+ physmem = 0; \
+ for (i = 0; i < numranges; i++) \
+ physmem += atop(high[i] - low[i]); \
+ maxaddr = high[numranges - 1] - PAGE_SIZE; \
+ high[numranges - 1] -= round_page(MSGBUFSIZE); \
avail_end = high[numranges - 1]; \
} while (0)
diff --git a/sys/arch/mvme68k/mvme68k/pmap_bootstrap.c b/sys/arch/mvme68k/mvme68k/pmap_bootstrap.c
index 1f6c1d3e6fb..319f0a79bfb 100644
--- a/sys/arch/mvme68k/mvme68k/pmap_bootstrap.c
+++ b/sys/arch/mvme68k/mvme68k/pmap_bootstrap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap_bootstrap.c,v 1.22 2006/05/19 22:51:09 miod Exp $ */
+/* $OpenBSD: pmap_bootstrap.c,v 1.23 2008/01/04 19:05:32 miod Exp $ */
/*
* Copyright (c) 1995 Theo de Raadt
@@ -121,7 +121,7 @@ do { \
#define PMAP_MD_MEMSIZE() \
do { \
RELOC(avail_end, paddr_t) = ptoa(RELOC(physmem, int)) - \
- (round_page(MSGBUFSIZE) + ptoa(1)); \
+ round_page(MSGBUFSIZE); \
} while (0)
#define PMAP_MD_RELOC3() /* nothing */