[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 7/7] hw/arm/bcm2835_peripherals: Correctly wire the SYS_timer IRQ
From: |
Philippe Mathieu-Daudé |
Subject: |
[PATCH 7/7] hw/arm/bcm2835_peripherals: Correctly wire the SYS_timer IRQs |
Date: |
Sun, 20 Sep 2020 19:58:25 +0200 |
The SYS_timer is not directly wired to the ARM core, but to the
SoC interrupt controller.
Fixes: 0e5bbd74064 ("hw/arm/bcm2835_peripherals: Use the SYS_timer")
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
hw/arm/bcm2835_peripherals.c | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/hw/arm/bcm2835_peripherals.c b/hw/arm/bcm2835_peripherals.c
index 4e6c678aa99..d1a1ff0676e 100644
--- a/hw/arm/bcm2835_peripherals.c
+++ b/hw/arm/bcm2835_peripherals.c
@@ -171,8 +171,17 @@ static void bcm2835_peripherals_realize(DeviceState *dev,
Error **errp)
memory_region_add_subregion(&s->peri_mr, ST_OFFSET,
sysbus_mmio_get_region(SYS_BUS_DEVICE(&s->systmr), 0));
sysbus_connect_irq(SYS_BUS_DEVICE(&s->systmr), 0,
- qdev_get_gpio_in_named(DEVICE(&s->ic), BCM2835_IC_ARM_IRQ,
- INTERRUPT_ARM_TIMER));
+ qdev_get_gpio_in_named(DEVICE(&s->ic), BCM2835_IC_GPU_IRQ,
+ INTERRUPT_TIMER0));
+ sysbus_connect_irq(SYS_BUS_DEVICE(&s->systmr), 1,
+ qdev_get_gpio_in_named(DEVICE(&s->ic), BCM2835_IC_GPU_IRQ,
+ INTERRUPT_TIMER1));
+ sysbus_connect_irq(SYS_BUS_DEVICE(&s->systmr), 2,
+ qdev_get_gpio_in_named(DEVICE(&s->ic), BCM2835_IC_GPU_IRQ,
+ INTERRUPT_TIMER2));
+ sysbus_connect_irq(SYS_BUS_DEVICE(&s->systmr), 3,
+ qdev_get_gpio_in_named(DEVICE(&s->ic), BCM2835_IC_GPU_IRQ,
+ INTERRUPT_TIMER3));
/* UART0 */
qdev_prop_set_chr(DEVICE(&s->uart0), "chardev", serial_hd(0));
--
2.26.2
- [PATCH 0/7] hw/arm/raspi: Fix SYS_timer on Linux + misc changes, Philippe Mathieu-Daudé, 2020/09/20
- [PATCH 1/7] hw/arm/raspi: Define various blocks base addresses, Philippe Mathieu-Daudé, 2020/09/20
- [PATCH 2/7] hw/arm/bcm2835: Add more unimplemented peripherals, Philippe Mathieu-Daudé, 2020/09/20
- [PATCH 4/7] hw/timer/bcm2835: Introduce BCM2835_SYSTIMER_COUNT definition, Philippe Mathieu-Daudé, 2020/09/20
- [PATCH 6/7] hw/timer/bcm2835: Support the timer COMPARE registers, Philippe Mathieu-Daudé, 2020/09/20
- [PATCH 7/7] hw/arm/bcm2835_peripherals: Correctly wire the SYS_timer IRQs,
Philippe Mathieu-Daudé <=
- [PATCH 5/7] hw/timer/bcm2835: Rename variable holding CTRL_STATUS register, Philippe Mathieu-Daudé, 2020/09/20
- [PATCH 3/7] hw/intc/bcm2835_ic: Trace GPU/CPU IRQ handlers, Philippe Mathieu-Daudé, 2020/09/20
- Re: [PATCH 0/7] hw/arm/raspi: Fix SYS_timer on Linux + misc changes, no-reply, 2020/09/20
- Re: [PATCH 0/7] hw/arm/raspi: Fix SYS_timer on Linux + misc changes, no-reply, 2020/09/20