[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] x86/IO-APIC: adjust setting of destinations



On 13/11/15 15:44, Jan Beulich wrote:
> 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. Replace a stray hard_smp_processor_id() at once.
>
> Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>

Surely this stray hard_smp_processor_id() needs to be merged into your
previous patch to remove hard_smp_processor_id() ?

As for the setup_IO_APIC_irqs() change, Reviewed-by: Andrew Cooper
<andrew.cooper3@xxxxxxxxxx>

>
> --- 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(vo
>                  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);
> @@ -1843,7 +1843,7 @@ static void __init unlock_ExtINT_logic(v
>  
>      entry1.dest_mode = 0;                    /* physical delivery */
>      entry1.mask = 0;                 /* unmask IRQ now */
> -    SET_DEST(entry1, physical, hard_smp_processor_id());
> +    SET_DEST(entry1, physical, get_apic_id());
>      entry1.delivery_mode = dest_ExtINT;
>      entry1.polarity = entry0.polarity;
>      entry1.trigger = 0;
>
>
>


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.