This patchset is a compilation of minor fixes and cleanups to the GICv5 code that I found in the course of implementing virtualization support:
* Various in-memory data structures are defined to be aligned to their size, even if the guest provides a base address that is less aligned * We had some extra blank lines that didn't match the style in the rest of the file * We were unnecessarily extracting a bit from a raw register value when we already had it cached as a boolean in a struct * We weren't tidying up our allocated memory on finalize * We can re-use arm_cpu_set_irq() rather than implementing the set/clear IRQ/FIQ/NMI locally. (This doesn't matter much for these, but VIRQ/VFIQ/VINMI have more complex logic in arm_cpu_set_irq() that we don't want to have to duplicate.) * Now we have a 'max-v9' we can clean up how we deal with the GICv5 needing a v9 CPU * having the cpuif identify itself by IAFFID and the IRS do an IAFFID->cpu index lookup is unnecessarily clunky Changes v1->v2: * fixed the lack of ~ in masking calcs in patches 1 and 2 * patches 7-10 are new Only patch 3 here has been reviewed. thanks -- PMM Peter Maydell (9): hw/intc/arm_gicv5: Ignore low bits in IRS_IST_BASER.ADDR hw/intc/arm_gicv5: Ignore low bits in L1_ISTE.L2_ADDR hw/intc/arm_gicv5: Regularize spacing in config_readl() switch hw/intc/arm_gicv5: Use cached IRS_IST_BASER.VALID state hw/intc/arm_gicv5: Free memory in finalize target/arm: GICv5 cpuif: Use arm_cpu_set_irq() to set IRQ/FIQ status target/arm: Only allow GICv5 on CPUs without AArch32 at EL1..3 hw/intc/arm_gicv5: Pass CPU index to CPU interface hw/intc/arm_gicv5: Pass cpuidx rather than iaffid in gicv5_get_hppi() hw/intc/arm_gicv5.c | 72 +++++++++++++++++++++--------- hw/intc/arm_gicv5_common.c | 5 ++- include/hw/intc/arm_gicv5.h | 1 + include/hw/intc/arm_gicv5_stream.h | 10 +++-- target/arm/cpu-features.h | 8 ++++ target/arm/cpu.c | 61 ++++++++++--------------- target/arm/cpu.h | 10 +++-- target/arm/internals.h | 14 ++++++ target/arm/tcg/gicv5-cpuif.c | 41 +++-------------- 9 files changed, 120 insertions(+), 102 deletions(-) -- 2.43.0
