diff options
author | Becky Bruce <becky.bruce@freescale.com> | 2008-10-15 04:25:28 -0400 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2008-10-21 20:00:25 -0400 |
commit | f465df81a80df92dbde0029b277f31b5e787b5df (patch) | |
tree | 67839adda26126b4e95b11e5a79d9dfc57a81014 /arch/powerpc/kernel/setup-common.c | |
parent | 934752d8a4aaae4bee7a1b46944f30a55178ec91 (diff) |
powerpc: Move memory size print into common show_cpuinfo for 32-bit
Most of the platforms were printing the size of the memory
in their show_cpuinfo implementations. This moves that to
the common show_cpuinfo, so that all 32-bit platforms will
now print the size of memory. I also update the code
to deal with the fact that total_memory is now a phys_addr_t.
Signed-off-by: Becky Bruce <becky.bruce@freescale.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/kernel/setup-common.c')
-rw-r--r-- | arch/powerpc/kernel/setup-common.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/setup-common.c b/arch/powerpc/kernel/setup-common.c index 5ec56ff03e86..705fc4bf3800 100644 --- a/arch/powerpc/kernel/setup-common.c +++ b/arch/powerpc/kernel/setup-common.c | |||
@@ -59,6 +59,7 @@ | |||
59 | #include <asm/mmu.h> | 59 | #include <asm/mmu.h> |
60 | #include <asm/xmon.h> | 60 | #include <asm/xmon.h> |
61 | #include <asm/cputhreads.h> | 61 | #include <asm/cputhreads.h> |
62 | #include <mm/mmu_decl.h> | ||
62 | 63 | ||
63 | #include "setup.h" | 64 | #include "setup.h" |
64 | 65 | ||
@@ -190,6 +191,12 @@ static int show_cpuinfo(struct seq_file *m, void *v) | |||
190 | if (ppc_md.show_cpuinfo != NULL) | 191 | if (ppc_md.show_cpuinfo != NULL) |
191 | ppc_md.show_cpuinfo(m); | 192 | ppc_md.show_cpuinfo(m); |
192 | 193 | ||
194 | #ifdef CONFIG_PPC32 | ||
195 | /* Display the amount of memory */ | ||
196 | seq_printf(m, "Memory\t\t: %d MB\n", | ||
197 | (unsigned int)(total_memory / (1024 * 1024))); | ||
198 | #endif | ||
199 | |||
193 | return 0; | 200 | return 0; |
194 | } | 201 | } |
195 | 202 | ||