]> xenbits.xensource.com Git - xen.git/commitdiff
ARM: vPL011: Use the VGIC's level triggered IRQs handling if available
authorAndre Przywara <andre.przywara@linaro.org>
Mon, 18 Dec 2017 17:34:24 +0000 (17:34 +0000)
committerStefano Stabellini <sstabellini@kernel.org>
Tue, 27 Mar 2018 19:44:32 +0000 (12:44 -0700)
The emulated ARM SBSA UART is using level triggered IRQ semantics,
however the current VGIC can only handle edge triggered IRQs, really.
Disable the existing workaround for this problem in case we have the
new VGIC in place, which can properly handle level triggered IRQs.

Signed-off-by: Andre Przywara <andre.przywara@linaro.org>
Reviewed-by: Julien Grall <julien.grall@arm.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
xen/arch/arm/vpl011.c

index 5dcf4bec18dc0596d0480b0e663370b31b810627..a281eabd7e3cbe96fe02000fdd983b4d3a38c28d 100644 (file)
@@ -54,6 +54,7 @@ static void vpl011_update_interrupt_status(struct domain *d)
      */
     ASSERT(spin_is_locked(&vpl011->lock));
 
+#ifndef CONFIG_NEW_VGIC
     /*
      * TODO: PL011 interrupts are level triggered which means
      * that interrupt needs to be set/clear instead of being
@@ -71,6 +72,9 @@ static void vpl011_update_interrupt_status(struct domain *d)
         vgic_inject_irq(d, NULL, GUEST_VPL011_SPI, true);
 
     vpl011->shadow_uartmis = uartmis;
+#else
+    vgic_inject_irq(d, NULL, GUEST_VPL011_SPI, uartmis);
+#endif
 }
 
 static uint8_t vpl011_read_data(struct domain *d)