From f1f7e4bf76ad8e88a55f3ae8fd01629669d4317b Mon Sep 17 00:00:00 2001 From: Jean-Christophe Dubois Date: Thu, 17 Dec 2015 13:37:13 +0000 Subject: i.MX: add support for lower and upper interrupt in GPIO. The i.MX6 GPIO device supports 2 interrupts instead of one. * 1 for the lower 16 GPIOs. * 1 for the upper 16 GPIOs. i.MX31 and i.MX25 only support 1 interrupt for the 32 GPIOs. So we add a property to turn the behavior on when required. Signed-off-by: Jean-Christophe Dubois Reviewed-by: Peter Crosthwaite Message-id: 1447497668-1603-1-git-send-email-jcd@tribudubois.net Signed-off-by: Peter Maydell --- include/hw/gpio/imx_gpio.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include/hw/gpio/imx_gpio.h') diff --git a/include/hw/gpio/imx_gpio.h b/include/hw/gpio/imx_gpio.h index 517b2618cb..b15a09fbca 100644 --- a/include/hw/gpio/imx_gpio.h +++ b/include/hw/gpio/imx_gpio.h @@ -54,8 +54,9 @@ typedef struct IMXGPIOState { uint32_t isr; bool has_edge_sel; uint32_t edge_sel; + bool has_upper_pin_irq; - qemu_irq irq; + qemu_irq irq[2]; qemu_irq output[IMX_GPIO_PIN_COUNT]; } IMXGPIOState; -- cgit v1.2.3-55-g7522