diff options
author | Jason Downs <downsj@cvs.openbsd.org> | 1999-09-30 06:29:58 +0000 |
---|---|---|
committer | Jason Downs <downsj@cvs.openbsd.org> | 1999-09-30 06:29:58 +0000 |
commit | 5e968c689b0e8819ee0e4bc8958b0963fdb18439 (patch) | |
tree | b88ab6fb6f6d65a28e5802effba065e9f298ef31 /sys/arch | |
parent | 4cde217be94edc713cb2d8bafc8916ec38dd9c86 (diff) |
Change extmem counter to include *all* extended memory segments.
Obviously, the kernel does not (and can not) know where the ACPI and such
pages are, since the boot -> kernel API does not support passing the
information.
This will stomp on them, once again, but we can NOT limit half the PCs
in existance to only 64MB of RAM.
Approved by deraadt.
Diffstat (limited to 'sys/arch')
-rw-r--r-- | sys/arch/i386/stand/libsa/memprobe.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/arch/i386/stand/libsa/memprobe.c b/sys/arch/i386/stand/libsa/memprobe.c index 287ebba51a8..6c00ef0f519 100644 --- a/sys/arch/i386/stand/libsa/memprobe.c +++ b/sys/arch/i386/stand/libsa/memprobe.c @@ -1,4 +1,4 @@ -/* $OpenBSD: memprobe.c,v 1.32 1999/08/25 00:54:19 mickey Exp $ */ +/* $OpenBSD: memprobe.c,v 1.33 1999/09/30 06:29:57 downsj Exp $ */ /* * Copyright (c) 1997-1999 Michael Shalayeff @@ -291,6 +291,7 @@ memprobe() #else printf(" mem["); #endif + if(!(pm = bios_E820(bios_memmap))) { im = bios_int12(bios_memmap); #if 0 @@ -322,7 +323,7 @@ memprobe() /* XXX - Compatibility, remove later (smpprobe() relies on it) */ extmem = cnvmem = 0; for(im = bios_memmap; im->type != BIOS_MAP_END; im++) { - /* Count only "good" memory chunks 4K and up in size */ + /* Count only "good" memory chunks 12K and up in size */ if ((im->type == BIOS_MAP_FREE) && (im->size >= 12*1024)) { if (im->size > 1024 * 1024) printf("%uM ", (u_int)im->size / (1024 * 1024)); @@ -341,8 +342,8 @@ memprobe() */ if(im->addr < IOM_BEGIN) cnvmem = max(cnvmem, im->addr + im->size); - if(im->addr == IOM_END) - extmem = im->size; + if(im->addr >= IOM_END) + extmem += im->size; } } cnvmem /= 1024; |