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

Re: [Xen-devel] [PATCH v8 09/13] xen/arm: second irq injection while the first irq is still inflight





On 23/05/14 18:24, Stefano Stabellini wrote:
On Fri, 23 May 2014, Julien Grall wrote:
On 05/23/2014 03:50 PM, Stefano Stabellini wrote:
The following change works:

diff --git a/xen/arch/arm/domain.c b/xen/arch/arm/domain.c
index 33141e3..2a8456f 100644
--- a/xen/arch/arm/domain.c
+++ b/xen/arch/arm/domain.c
@@ -644,6 +644,8 @@ int arch_set_info_guest(
      else
          set_bit(_VPF_down, &v->pause_flags);

+    vgic_vcpu_inject_irq(v, v->domain->arch.evtchn_irq);
+

This is racy, we may not clear the _VPF_down bit in this function
(depending if VGCF_online is set or not).

Hopefully for ARM, libxc is setting this flags by default but it's not
always true.

I could change the code to call vgic_vcpu_inject_irq only if VGCF_online
is set, but on second thought, would the code actually be more readable?
Or less error prone?

I think that the original patch is better. At least the hack is present
in a single very obvious place (vgic_enable_irqs).

Hmmm ... right. I know that this code will likely change (with GICv3 support). Can you add a comment in the code explain this issue?

With this change:

Acked-by: Julien Grall <julien.grall@xxxxxxxxxx>

Regards,

--
Julien Grall

_______________________________________________
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®.