summaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/genapic_64.c
diff options
context:
space:
mode:
authorYinghai Lu <yhlu.kernel@gmail.com>2008-07-25 19:39:03 -0700
committerIngo Molnar <mingo@elte.hu>2008-07-27 06:28:16 +0200
commitd25ae38b7e005af03843833bbd811ffe8c5f8cb4 (patch)
treebc4016cd14572affa04e3fed6f0dd095ce134fc3 /arch/x86/kernel/genapic_64.c
parentedb181ac4b0c7c1240503da46349a3fb69af9ef6 (diff)
x86: add apic probe for genapic 64bit - fix
intr_remapping_enabled get assigned later, so need to check that in setup_apic_routing Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com> Cc: Jack Steiner <steiner@sgi.com> Cc: Suresh Siddha <suresh.b.siddha@intel.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/genapic_64.c')
-rw-r--r--arch/x86/kernel/genapic_64.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/x86/kernel/genapic_64.c b/arch/x86/kernel/genapic_64.c
index b3ba969c50d..6c9bfc9e1e9 100644
--- a/arch/x86/kernel/genapic_64.c
+++ b/arch/x86/kernel/genapic_64.c
@@ -16,6 +16,7 @@
#include <linux/ctype.h>
#include <linux/init.h>
#include <linux/hardirq.h>
+#include <linux/dmar.h>
#include <asm/smp.h>
#include <asm/ipi.h>
@@ -42,6 +43,11 @@ static struct genapic *apic_probe[] __initdata = {
*/
void __init setup_apic_routing(void)
{
+ if (genapic == &apic_x2apic_phys || genapic == &apic_x2apic_cluster) {
+ if (!intr_remapping_enabled)
+ genapic = &apic_flat;
+ }
+
if (genapic == &apic_flat) {
if (max_physical_apicid >= 8)
genapic = &apic_physflat;