From: Willy Tarreau Date: Thu, 2 Nov 2017 22:22:31 +0000 (+0100) Subject: x86/apic: fix build breakage caused by incomplete backport to 3.10 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=68cbe93962196f08a1a52e81dc6d5bedaca09b06;p=GitHub%2Fmt8127%2Fandroid_kernel_alcatel_ttab.git x86/apic: fix build breakage caused by incomplete backport to 3.10 Commit 928a277 ("x86/apic: Do not init irq remapping if ioapic is disabled") introduced in 3.10.105 introduced an implicit dependency of CONFIG_X86_LOCAL_APIC to CONFIG_X86_IO_APIC which was later solved as part of simplifications on the config dependencies in more recent kernels. This dependency results in build failure when CONFIG_X86_LOCAL_APIC is set without CONFIG_X86_IO_APIC (this setup requires CONFIG_SMP=n). The reason is that skip_ioapic_setup is declared in apic.c and that the backported code was picked from a context where the #ifdef surrounding the function used to cover this condition. Let's just add the appropriate #ifdef to fix the 3.10 backport. Thanks to Christoph Biedl for reporting and diagnosing this one. Reported-by: Christoph Biedl Cc: Christoph Biedl Cc: Jan Beulich Cc: Wanpeng Li Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Signed-off-by: Willy Tarreau --- diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c index 3cd8bfc3c4b6..bc37ddeaa627 100644 --- a/arch/x86/kernel/apic/apic.c +++ b/arch/x86/kernel/apic/apic.c @@ -1581,8 +1581,10 @@ void __init enable_IR_x2apic(void) int ret, x2apic_enabled = 0; int hardware_init_ret; +#ifdef CONFIG_X86_IO_APIC if (skip_ioapic_setup) return; +#endif /* Make sure irq_remap_ops are initialized */ setup_irq_remapping_ops();