From: Jan Beulich Date: Mon, 16 Nov 2015 12:11:59 +0000 (+0100) Subject: x86/IO-APIC: adjust setting of destinations X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~2249^2~1 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=a85da715cfffbc294589ad4edc4c7564ae6fcc25;p=xen.git x86/IO-APIC: adjust setting of destinations setup_IO_APIC_irqs() runs before APs get brought up, so using desc->arch.cpu_mask as best risks it being either empty or having bits for CPUs other than the BP set. Just use the APIC ID of the only online CPU directly. Signed-off-by: Jan Beulich Reviewed-by: Andrew Cooper --- diff --git a/xen/arch/x86/io_apic.c b/xen/arch/x86/io_apic.c index 511cd4014c..6a71cef7f8 100644 --- a/xen/arch/x86/io_apic.c +++ b/xen/arch/x86/io_apic.c @@ -1039,7 +1039,7 @@ static void __init setup_IO_APIC_irqs(void) disable_8259A_irq(irq_to_desc(irq)); desc = irq_to_desc(irq); - SET_DEST(entry, logical, cpu_mask_to_apicid(desc->arch.cpu_mask)); + SET_DEST(entry, logical, get_apic_id()); spin_lock_irqsave(&ioapic_lock, flags); __ioapic_write_entry(apic, pin, 0, entry); set_native_irq_info(irq, TARGET_CPUS);