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

Re: [Xen-devel] [PATCH] gic: drop interrupts enabling on interrupts processing



Hi,

On 21/12/2018 17:41, Andrii Anisov wrote:
From: Andrii Anisov <andrii_anisov@xxxxxxxx>

This reduces the number of context switches in case we have coming guest
interrupts from different sources at a high rate. What is likely for
multimedia use-cases.
Having irqs unlocked here makes us go through trap path again in case we
have a new guest interrupt arrived (even with the same priority, after
`desc->handler->end(desc)` in `do_IRQ()`), what is just a processor
cycles wasting. We will catch them all in the `gic_interrupt() function
loop anyway. And the guest irqs arrival prioritization is meaningless
here, it is only effective at guest's level.

Signed-off-by: Andrii Anisov <andrii_anisov@xxxxxxxx>

---

This is the patch [1] from RFC series, with extended commit message.

[1] https://lists.xenproject.org/archives/html/xen-devel/2018-11/msg03286.html

---
  xen/arch/arm/gic.c | 2 --
  1 file changed, 2 deletions(-)

diff --git a/xen/arch/arm/gic.c b/xen/arch/arm/gic.c
index 6cc7dec..9f5cd95 100644
--- a/xen/arch/arm/gic.c
+++ b/xen/arch/arm/gic.c
@@ -386,10 +386,8 @@ void gic_interrupt(struct cpu_user_regs *regs, int is_fiq)
if ( likely(irq >= 16 && irq < 1020) )
          {
-            local_irq_enable();
              isb();
              do_IRQ(regs, irq, is_fiq);
-            local_irq_disable();
          }
          else if ( is_lpi(irq) )
          {

I think it would make sense to keep the interrupts disabled in is_lpi as well. So we keep the behavior the same accross all interrupts.

Cheers,

--
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

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