summary refs log tree commit diff stats
path: root/include/hw/intc/arm_gicv3_common.h
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2021-09-30 16:08:40 +0100
committerPeter Maydell <peter.maydell@linaro.org>2021-11-15 16:12:59 +0000
commit01b5ab8cc08ab0afb6574f46a4d966725a00a1de (patch)
treebf988313be837f325eeb73942df4334fc4646354 /include/hw/intc/arm_gicv3_common.h
parent42f6c9179be4401974dd3a75ee72defd16b5092d (diff)
downloadfocaccia-qemu-01b5ab8cc08ab0afb6574f46a4d966725a00a1de.tar.gz
focaccia-qemu-01b5ab8cc08ab0afb6574f46a4d966725a00a1de.zip
hw/intc/arm_gicv3: Move checking of redist-region-count to arm_gicv3_common_realize
The GICv3 devices have an array property redist-region-count.
Currently we check this for errors (bad values) in
gicv3_init_irqs_and_mmio(), just before we use it.  Move this error
checking to the arm_gicv3_common_realize() function, where we
sanity-check all of the other base-class properties. (This will
always be before gicv3_init_irqs_and_mmio() is called, because
that function is called in the subclass realize methods, after
they have called the parent-class realize.)

The motivation for this refactor is:
 * we would like to use the redist_region_count[] values in
   arm_gicv3_common_realize() in a subsequent patch, so we need
   to have already done the sanity-checking first
 * this removes the only use of the Error** argument to
   gicv3_init_irqs_and_mmio(), so we can remove some error-handling
   boilerplate

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'include/hw/intc/arm_gicv3_common.h')
-rw-r--r--include/hw/intc/arm_gicv3_common.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/hw/intc/arm_gicv3_common.h b/include/hw/intc/arm_gicv3_common.h
index aa4f0d6770..cb2b0d0ad4 100644
--- a/include/hw/intc/arm_gicv3_common.h
+++ b/include/hw/intc/arm_gicv3_common.h
@@ -306,6 +306,6 @@ struct ARMGICv3CommonClass {
 };
 
 void gicv3_init_irqs_and_mmio(GICv3State *s, qemu_irq_handler handler,
-                              const MemoryRegionOps *ops, Error **errp);
+                              const MemoryRegionOps *ops);
 
 #endif