diff options
author | Michael Ellerman <michael@ellerman.id.au> | 2006-02-21 17:22:55 +1100 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2006-02-24 11:36:18 +1100 |
commit | 337a7128dbe68ebe7627b6f954cb32d30d7b11c6 (patch) | |
tree | 6189f61386f3be72cffab14ed1b42a508ef1793c /arch/powerpc/mm | |
parent | bd6ef57e08d6cce32e93f9fc7b93d361b6a7884f (diff) | |
download | kernel_samsung_aries-337a7128dbe68ebe7627b6f954cb32d30d7b11c6.zip kernel_samsung_aries-337a7128dbe68ebe7627b6f954cb32d30d7b11c6.tar.gz kernel_samsung_aries-337a7128dbe68ebe7627b6f954cb32d30d7b11c6.tar.bz2 |
[PATCH] powerpc: Only calculate htab_size in one place for kexec
For kexec we need to know the size of the MMU hash table.
Currently we calculate the size once in the htab code, and then twice more in
the kexec code, once using htab_hash_mask and once using ppc64_pft_size.
On some machines the ppc64_pft_size calculation is broken because
ppc64_pft_size is not set.
So we need to fix the second calculation, but better still we should just
calculate the size once and use it everywhere else.
Tested on Power5 LPAR, Power4 non-LPAR and Power3.
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/mm')
-rw-r--r-- | arch/powerpc/mm/hash_utils_64.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/powerpc/mm/hash_utils_64.c b/arch/powerpc/mm/hash_utils_64.c index 149351a..b1f614c 100644 --- a/arch/powerpc/mm/hash_utils_64.c +++ b/arch/powerpc/mm/hash_utils_64.c @@ -88,6 +88,7 @@ static unsigned long _SDR1; struct mmu_psize_def mmu_psize_defs[MMU_PAGE_COUNT]; hpte_t *htab_address; +unsigned long htab_size_bytes; unsigned long htab_hash_mask; int mmu_linear_psize = MMU_PAGE_4K; int mmu_virtual_psize = MMU_PAGE_4K; @@ -399,7 +400,7 @@ void create_section_mapping(unsigned long start, unsigned long end) void __init htab_initialize(void) { - unsigned long table, htab_size_bytes; + unsigned long table; unsigned long pteg_count; unsigned long mode_rw; unsigned long base = 0, size = 0; |