From: Ingo Molnar Date: Mon, 7 May 2012 17:19:56 +0000 (+0200) Subject: x86/apic: Fix UP boot crash X-Git-Tag: v2.6.39-400.9.0~543^2~9^2 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=56262b29ee04572a264ed5faf3e1068a8abbdca8;p=users%2Fjedix%2Flinux-maple.git x86/apic: Fix UP boot crash Commit 31b3c9d72340 ("xen/x86: Implement x86_apic_ops") implemented this: ... without considering that on UP the function pointer might be NULL. Cc: Suresh Siddha Cc: Konrad Rzeszutek Wilk Link: http://lkml.kernel.org/n/tip-3pfty0ml4yp62phbkchichh0@git.kernel.org Signed-off-by: Ingo Molnar --- diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c index 45ac94480260..0cc341d34d93 100644 --- a/arch/x86/kernel/setup.c +++ b/arch/x86/kernel/setup.c @@ -1022,7 +1022,8 @@ void __init setup_arch(char **cmdline_p) init_cpu_to_node(); init_apic_mappings(); - x86_io_apic_ops.init(); + if (x86_io_apic_ops.init) + x86_io_apic_ops.init(); kvm_guest_init();