summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCyrill Gorcunov <gorcunov@gmail.com>2009-05-11 17:41:40 +0400
committerIngo Molnar <mingo@elte.hu>2009-05-11 15:50:58 +0200
commitcec6be6d1069d697beb490bbb40a290d5ff554a2 (patch)
tree43ef99d950545909d8dbc87cddb14e29789aa060
parent97a52714658cd959a3cfa35c5b6f489859f0204b (diff)
downloadlinux-stable-cec6be6d1069d697beb490bbb40a290d5ff554a2.tar.gz
linux-stable-cec6be6d1069d697beb490bbb40a290d5ff554a2.tar.bz2
linux-stable-cec6be6d1069d697beb490bbb40a290d5ff554a2.zip
x86: apic: Fixmap apic address even if apic disabled
In case if apic were disabled by boot option we still need read_apic operation. So fixmap a fake apic area if needed. [ Impact: fix boot crash ] Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org> Cc: yinghai@kernel.org Cc: eswierk@aristanetworks.com LKML-Reference: <20090511134140.GH4624@lenovo> Signed-off-by: Ingo Molnar <mingo@elte.hu>
-rw-r--r--arch/x86/kernel/apic/apic.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c
index 0e6543fafb50..07cffc1214cb 100644
--- a/arch/x86/kernel/apic/apic.c
+++ b/arch/x86/kernel/apic/apic.c
@@ -1587,13 +1587,6 @@ void __init init_apic_mappings(void)
} else
apic_phys = mp_lapic_addr;
- /* lets check if we may NOP'ify apic operations */
- if (!cpu_has_apic) {
- pr_info("APIC: disable apic facility\n");
- apic_disable();
- return;
- }
-
/*
* acpi lapic path already maps that address in
* acpi_register_lapic_address()
@@ -1602,7 +1595,15 @@ void __init init_apic_mappings(void)
set_fixmap_nocache(FIX_APIC_BASE, apic_phys);
apic_printk(APIC_VERBOSE, "mapped APIC to %08lx (%08lx)\n",
- APIC_BASE, apic_phys);
+ APIC_BASE, apic_phys);
+
+ /* lets check if we may NOP'ify apic operations */
+ if (!cpu_has_apic) {
+ pr_info("APIC: disable apic facility\n");
+ apic_disable();
+ return;
+ }
+
/*
* Fetch the APIC ID of the BSP in case we have a
* default configuration (or the MP table is broken).