[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 3/4] x86/IRQ: relax locking in irq_guest_eoi_timer_fn()
This is a timer handler, so it gets entered with IRQs enabled. Therefore there's no need to save/restore the IRQ masking flag. Additionally the final switch()'es ACKTYPE_EOI case re-acquires the lock just for it to be dropped again right away. Do away with this. Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> --- a/xen/arch/x86/irq.c +++ b/xen/arch/x86/irq.c @@ -1106,9 +1106,8 @@ static void irq_guest_eoi_timer_fn(void unsigned int irq = desc - irq_desc; irq_guest_action_t *action; cpumask_t cpu_eoi_map; - unsigned long flags; - spin_lock_irqsave(&desc->lock, flags); + spin_lock_irq(&desc->lock); if ( !(desc->status & IRQ_GUEST) ) goto out; @@ -1145,12 +1144,11 @@ static void irq_guest_eoi_timer_fn(void cpumask_copy(&cpu_eoi_map, action->cpu_eoi_map); spin_unlock_irq(&desc->lock); on_selected_cpus(&cpu_eoi_map, set_eoi_ready, desc, 0); - spin_lock_irq(&desc->lock); - break; + return; } out: - spin_unlock_irqrestore(&desc->lock, flags); + spin_unlock_irq(&desc->lock); } static void __do_IRQ_guest(int irq) _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |