ia64, kexec: make use of ia64_disable_vhpt()
PATCH 1/1 ia64, kexec: make use of ia64_disable_vhpt()
Quoted 3 lines · Ian Wienand
Kexec wants a way to enable and disable the VHPT, and it seems quite straight forward to abstract it. I think the reduced
ia64_mmu_initis an improvement.
Here is a patch that makes use of that. Thanks.
Signature · 21 lines
Horms http://www.vergenet.net/~horms/ ia64, kexec: make use of ia64_disable_vhpt() Have kexec make use of ia64_disable_vhpt() which Ian Wienand recently proposed and posted a patch for. http://permalink.gmane.org/gmane.linux.ports.ia64/14425 This removes some duplicated macros in include/asm-ia64/kexec.h, and avoids arch/ia64/kernel/smp.c needing to know anything about vhpt. It replaces a cleanup patches that I posted the other day. http://permalink.gmane.org/gmane.linux.ports.ia64/14406 http://permalink.gmane.org/gmane.linux.ports.ia64/14407 Signed-off-by: Horms <[email protected]> --- arch/ia64/kernel/smp.c | 7 ++----- include/asm-ia64/kexec.h | 4 ---- 2 files changed, 2 insertions(+), 9 deletions(-)
arch/ia64/kernel/smp.c +2 -5
@@ -93,7 +93,7 @@ #ifdef CONFIG_KEXECvoid kexec_stop_this_cpu (void *func) { -unsigned long pta, impl_va_bits, pal_base; +unsigned long pal_base;/* * Remove this CPU by putting it into fake SAL rendezvous
@@ -102,10 +102,7 @@ kexec_stop_this_cpu (void *func)max_xtp ();ia64_eoi (); -/* Disable VHPT */ - impl_va_bits =ffz (~(local_cpu_data->unimpl_va_mask | (7UL <<61 ))); - pta =POW2 (61 ) -POW2 (vmlpt_bits); -ia64_set_pta (pta | (0 <<8 ) | (vmlpt_bits <<2 ) |0 ); +ia64_disable_vhpt ();local_irq_disable (); pal_base =__get_cpu_var (ia64_mca_pal_base);
include/asm-ia64/kexec.h +0 -4
@@ -16,10 +16,6 @@ #define KEXEC_ARCH KEXEC_ARCH_IA_64#define MAX_NOTE_BYTES 1024 -#define pte_bits 3 -#define vmlpt_bits (impl_va_bits - PAGE_SHIFT + pte_bits) -#define POW2 (n) (1ULL << (n)) -DECLARE_PER_CPU (u64, ia64_mca_pal_base);const extern unsigned int relocate_new_kernel_size;volatile extern long kexec_rendez;
Signature · 1 line
1.4.0.gd281