diff options
author | Suresh Siddha <suresh.b.siddha@intel.com> | 2009-03-17 00:05:00 (GMT) |
---|---|---|
committer | H. Peter Anvin <hpa@linux.intel.com> | 2009-03-17 22:43:51 (GMT) |
commit | cf6567fe40c55e9cffca7355cd34e50fb2871e4e (patch) | |
tree | c05d4bdfa91a5c9ad35e9b6b1a06d9188ed7800f /arch/x86/kernel | |
parent | 7c6d9f9785d156d0438401ef270322da3d5247db (diff) | |
download | linux-fsl-qoriq-cf6567fe40c55e9cffca7355cd34e50fb2871e4e.tar.xz |
x86, x2apic: fix clear_local_APIC() in the presence of x2apic
Impact: cleanup, paranoia
We were not clearing the local APIC in clear_local_APIC() in the
presence of x2apic. Fix it.
Signed-off-by: Suresh Siddha <suresh.b.siddha@intel.com>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Diffstat (limited to 'arch/x86/kernel')
-rw-r--r-- | arch/x86/kernel/apic/apic.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c index 30909a2..699f8cf 100644 --- a/arch/x86/kernel/apic/apic.c +++ b/arch/x86/kernel/apic/apic.c @@ -809,7 +809,7 @@ void clear_local_APIC(void) u32 v; /* APIC hasn't been mapped yet */ - if (!apic_phys) + if (!x2apic && !apic_phys) return; maxlvt = lapic_get_maxlvt(); @@ -1523,12 +1523,10 @@ void __init early_init_lapic_mapping(void) */ void __init init_apic_mappings(void) { -#ifdef CONFIG_X86_X2APIC if (x2apic) { boot_cpu_physical_apicid = read_apic_id(); return; } -#endif /* * If no local APIC can be found then set up a fake all @@ -1972,12 +1970,9 @@ static int lapic_resume(struct sys_device *dev) local_irq_save(flags); -#ifdef CONFIG_X86_X2APIC if (x2apic) enable_x2apic(); - else -#endif - { + else { /* * Make sure the APICBASE points to the right address * |