diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-08-29 01:32:32 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-08-29 01:32:32 -0400 |
commit | 4ed86af67e04cb5eb93faba589d102726207865a (patch) | |
tree | e3f3d6ed4c2465087d23050c770d236861920d2f /arch | |
parent | 326ba5010a5429a5a528b268b36a5900d4ab0eba (diff) | |
parent | 295594e9cf6ae2efd73371777aa8feba0f87f42f (diff) |
Merge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
x86: Fix vSMP boot crash
x86, xen: Initialize cx to suppress warning
x86, xen: Suppress WP test on Xen
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/kernel/apic/probe_64.c | 10 | ||||
-rw-r--r-- | arch/x86/xen/enlighten.c | 2 |
2 files changed, 12 insertions, 0 deletions
diff --git a/arch/x86/kernel/apic/probe_64.c b/arch/x86/kernel/apic/probe_64.c index bc3e880f9b82..fcec2f1d34a1 100644 --- a/arch/x86/kernel/apic/probe_64.c +++ b/arch/x86/kernel/apic/probe_64.c | |||
@@ -44,6 +44,11 @@ static struct apic *apic_probe[] __initdata = { | |||
44 | NULL, | 44 | NULL, |
45 | }; | 45 | }; |
46 | 46 | ||
47 | static int apicid_phys_pkg_id(int initial_apic_id, int index_msb) | ||
48 | { | ||
49 | return hard_smp_processor_id() >> index_msb; | ||
50 | } | ||
51 | |||
47 | /* | 52 | /* |
48 | * Check the APIC IDs in bios_cpu_apicid and choose the APIC mode. | 53 | * Check the APIC IDs in bios_cpu_apicid and choose the APIC mode. |
49 | */ | 54 | */ |
@@ -69,6 +74,11 @@ void __init default_setup_apic_routing(void) | |||
69 | printk(KERN_INFO "Setting APIC routing to %s\n", apic->name); | 74 | printk(KERN_INFO "Setting APIC routing to %s\n", apic->name); |
70 | } | 75 | } |
71 | 76 | ||
77 | if (is_vsmp_box()) { | ||
78 | /* need to update phys_pkg_id */ | ||
79 | apic->phys_pkg_id = apicid_phys_pkg_id; | ||
80 | } | ||
81 | |||
72 | /* | 82 | /* |
73 | * Now that apic routing model is selected, configure the | 83 | * Now that apic routing model is selected, configure the |
74 | * fault handling for intr remapping. | 84 | * fault handling for intr remapping. |
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index e90540a46a0b..eb33aaa8415d 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c | |||
@@ -215,6 +215,7 @@ static __init void xen_init_cpuid_mask(void) | |||
215 | (1 << X86_FEATURE_ACPI)); /* disable ACPI */ | 215 | (1 << X86_FEATURE_ACPI)); /* disable ACPI */ |
216 | 216 | ||
217 | ax = 1; | 217 | ax = 1; |
218 | cx = 0; | ||
218 | xen_cpuid(&ax, &bx, &cx, &dx); | 219 | xen_cpuid(&ax, &bx, &cx, &dx); |
219 | 220 | ||
220 | /* cpuid claims we support xsave; try enabling it to see what happens */ | 221 | /* cpuid claims we support xsave; try enabling it to see what happens */ |
@@ -1059,6 +1060,7 @@ asmlinkage void __init xen_start_kernel(void) | |||
1059 | /* set up basic CPUID stuff */ | 1060 | /* set up basic CPUID stuff */ |
1060 | cpu_detect(&new_cpu_data); | 1061 | cpu_detect(&new_cpu_data); |
1061 | new_cpu_data.hard_math = 1; | 1062 | new_cpu_data.hard_math = 1; |
1063 | new_cpu_data.wp_works_ok = 1; | ||
1062 | new_cpu_data.x86_capability[0] = cpuid_edx(1); | 1064 | new_cpu_data.x86_capability[0] = cpuid_edx(1); |
1063 | #endif | 1065 | #endif |
1064 | 1066 | ||