]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blob - src/patches/suse-2.6.27.25/patches.arch/x2APIC_PATCH_35_of_41_d25ae38b7e005af03843833bbd811ffe8c5f8cb4
Reenabled linux-xen and xen-image build
[people/pmueller/ipfire-2.x.git] / src / patches / suse-2.6.27.25 / patches.arch / x2APIC_PATCH_35_of_41_d25ae38b7e005af03843833bbd811ffe8c5f8cb4
1 From: Yinghai Lu <yhlu.kernel@gmail.com>
2 Subject: x86: add apic probe for genapic 64bit - fix
3 References: fate #303948 and fate #303984
4 Patch-Mainline: queued for .28
5 Commit-ID: d25ae38b7e005af03843833bbd811ffe8c5f8cb4
6
7 Signed-off-by: Thomas Renninger <trenn@suse.de>
8
9 intr_remapping_enabled get assigned later, so need to check that
10 in setup_apic_routing
11
12 Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
13 Cc: Jack Steiner <steiner@sgi.com>
14 Cc: Suresh Siddha <suresh.b.siddha@intel.com>
15 Signed-off-by: Ingo Molnar <mingo@elte.hu>
16
17 ---
18 arch/x86/kernel/genapic_64.c | 6 ++++++
19 arch/x86/kernel/genx2apic_cluster.c | 2 +-
20 arch/x86/kernel/genx2apic_phys.c | 2 +-
21 3 files changed, 8 insertions(+), 2 deletions(-)
22
23 Index: linux-2.6.26/arch/x86/kernel/genapic_64.c
24 ===================================================================
25 --- linux-2.6.26.orig/arch/x86/kernel/genapic_64.c
26 +++ linux-2.6.26/arch/x86/kernel/genapic_64.c
27 @@ -16,6 +16,7 @@
28 #include <linux/ctype.h>
29 #include <linux/init.h>
30 #include <linux/hardirq.h>
31 +#include <linux/dmar.h>
32
33 #include <asm/smp.h>
34 #include <asm/ipi.h>
35 @@ -42,6 +43,11 @@ static struct genapic *apic_probe[] __in
36 */
37 void __init setup_apic_routing(void)
38 {
39 + if (genapic == &apic_x2apic_phys || genapic == &apic_x2apic_cluster) {
40 + if (!intr_remapping_enabled)
41 + genapic = &apic_flat;
42 + }
43 +
44 if (genapic == &apic_flat) {
45 if (max_physical_apicid >= 8)
46 genapic = &apic_physflat;
47 Index: linux-2.6.26/arch/x86/kernel/genx2apic_cluster.c
48 ===================================================================
49 --- linux-2.6.26.orig/arch/x86/kernel/genx2apic_cluster.c
50 +++ linux-2.6.26/arch/x86/kernel/genx2apic_cluster.c
51 @@ -14,7 +14,7 @@ DEFINE_PER_CPU(u32, x86_cpu_to_logical_a
52
53 static int __init x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id)
54 {
55 - if (cpu_has_x2apic && intr_remapping_enabled)
56 + if (cpu_has_x2apic)
57 return 1;
58
59 return 0;
60 Index: linux-2.6.26/arch/x86/kernel/genx2apic_phys.c
61 ===================================================================
62 --- linux-2.6.26.orig/arch/x86/kernel/genx2apic_phys.c
63 +++ linux-2.6.26/arch/x86/kernel/genx2apic_phys.c
64 @@ -23,7 +23,7 @@ early_param("x2apic_phys", set_x2apic_ph
65
66 static int __init x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id)
67 {
68 - if (cpu_has_x2apic && intr_remapping_enabled && x2apic_phys)
69 + if (cpu_has_x2apic && x2apic_phys)
70 return 1;
71
72 return 0;