Skip to content

Commit

Permalink
powerpc: Handle simultaneous interrupts at once
Browse files Browse the repository at this point in the history
It often happens to have simultaneous interrupts, for instance
when having double Ethernet attachment. With the current
implementation, we suffer the cost of kernel entry/exit for each
interrupt.

This patch introduces a loop in __do_irq() to handle all interrupts
at once before returning.

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
  • Loading branch information
Christophe Leroy authored and Michael Ellerman committed Jun 2, 2017
1 parent 3c29b60 commit 45cb08f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion arch/powerpc/kernel/irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -481,7 +481,11 @@ void __do_irq(struct pt_regs *regs)
if (unlikely(!irq))
__this_cpu_inc(irq_stat.spurious_irqs);
else
generic_handle_irq(irq);
do {
generic_handle_irq(irq);

irq = ppc_md.get_irq();
} while (irq);

trace_irq_exit(regs);

Expand Down

0 comments on commit 45cb08f

Please sign in to comment.