diff options
author | Kumar Gala <galak@kernel.crashing.org> | 2008-04-15 15:52:21 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2008-04-16 17:46:12 -0400 |
commit | 99c62dd773797b68f3b1ca6bb3274725d1852fa2 (patch) | |
tree | 7641433c9a3358c5dc108f2d3d4894f5f96f0b19 /arch/powerpc/mm/init_32.c | |
parent | 1993cbf4ae7d30f9a417e143c1344466f2e2ae2e (diff) |
[POWERPC] Remove and replace uses of PPC_MEMSTART with memstart_addr
A number of users of PPC_MEMSTART (40x, ppc_mmu_32) can just always
use 0 as we don't support booting these kernels at non-zero physical
addresses since their exception vectors must be at 0 (or 0xfffx_xxxx).
For the sub-arches that support relocatable interrupt vectors
(book-e), it's reasonable to have memory start at a non-zero physical
address. For those cases use the variable memstart_addr instead of
the #define PPC_MEMSTART since the only uses of PPC_MEMSTART are for
initialization and in the future we can set memstart_addr at runtime
to have a relocatable kernel.
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/mm/init_32.c')
-rw-r--r-- | arch/powerpc/mm/init_32.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/arch/powerpc/mm/init_32.c b/arch/powerpc/mm/init_32.c index 0c66a9fe63f5..1d7e5b8ade6a 100644 --- a/arch/powerpc/mm/init_32.c +++ b/arch/powerpc/mm/init_32.c | |||
@@ -59,8 +59,8 @@ DEFINE_PER_CPU(struct mmu_gather, mmu_gathers); | |||
59 | unsigned long total_memory; | 59 | unsigned long total_memory; |
60 | unsigned long total_lowmem; | 60 | unsigned long total_lowmem; |
61 | 61 | ||
62 | unsigned long ppc_memstart; | 62 | phys_addr_t memstart_addr; |
63 | unsigned long ppc_memoffset = PAGE_OFFSET; | 63 | phys_addr_t lowmem_end_addr; |
64 | 64 | ||
65 | int boot_mapsize; | 65 | int boot_mapsize; |
66 | #ifdef CONFIG_PPC_PMAC | 66 | #ifdef CONFIG_PPC_PMAC |
@@ -145,8 +145,7 @@ void __init MMU_init(void) | |||
145 | printk(KERN_WARNING "Only using first contiguous memory region"); | 145 | printk(KERN_WARNING "Only using first contiguous memory region"); |
146 | } | 146 | } |
147 | 147 | ||
148 | total_memory = lmb_end_of_DRAM(); | 148 | total_lowmem = total_memory = lmb_end_of_DRAM() - memstart_addr; |
149 | total_lowmem = total_memory; | ||
150 | 149 | ||
151 | #ifdef CONFIG_FSL_BOOKE | 150 | #ifdef CONFIG_FSL_BOOKE |
152 | /* Freescale Book-E parts expect lowmem to be mapped by fixed TLB | 151 | /* Freescale Book-E parts expect lowmem to be mapped by fixed TLB |