diff options
author | Peter Valchev <pvalchev@cvs.openbsd.org> | 2007-05-23 20:33:48 +0000 |
---|---|---|
committer | Peter Valchev <pvalchev@cvs.openbsd.org> | 2007-05-23 20:33:48 +0000 |
commit | a1c89e25c5c346f99dc51b78682349788f845846 (patch) | |
tree | 2dc182bdfb2d42eb1fa7ff2e40c8f70b24e5e63d /sys/arch/sparc64 | |
parent | 25f0a82c2a3f761cc8804e53e0deb876ba827cc5 (diff) |
Print real/available memory in MB as well as bytes in dmesg, and unify
architectures to print it the same way.
ok henning, miod; i386 part from tom
Diffstat (limited to 'sys/arch/sparc64')
-rw-r--r-- | sys/arch/sparc64/sparc64/machdep.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/arch/sparc64/sparc64/machdep.c b/sys/arch/sparc64/sparc64/machdep.c index faf51063204..229efbf7b1d 100644 --- a/sys/arch/sparc64/sparc64/machdep.c +++ b/sys/arch/sparc64/sparc64/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.87 2007/03/31 22:16:48 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.88 2007/05/23 20:33:47 pvalchev Exp $ */ /* $NetBSD: machdep.c,v 1.108 2001/07/24 19:30:14 eeh Exp $ */ /*- @@ -255,7 +255,8 @@ cpu_startup() */ printf(version); /*identifycpu();*/ - printf("total memory = %ld\n", (long)physmem * PAGE_SIZE); + printf("real mem = %lu (%luMB)\n", ctob(physmem), + ctob(physmem)/1024/1024); /* * Find out how much space we need, allocate it, * and then give everything true virtual addresses. @@ -324,7 +325,8 @@ cpu_startup() #ifdef DEBUG pmapdebug = opmapdebug; #endif - printf("avail memory = %ld\n", (long)uvmexp.free * PAGE_SIZE); + printf("avail mem = %lu (%luMB)\n", ptoa(uvmexp.free), + ptoa(uvmexp.free)/1024/1024); printf("using %d buffers containing %ld bytes of memory\n", nbuf, (long)bufpages * PAGE_SIZE); |