qemu/hw/intc
Ben Dooks 70726a15bc hw/intc/arm_gicv3: ICC_PMR_EL1 high bits should be RAZ
The ICC_PMR_ELx and ICV_PMR_ELx bit masks returned from
ic{c,v}_fullprio_mask should technically also remove any
bit above 7 as these are marked reserved (read 0) and should
therefore should not be written as anything other than 0.

This was noted during a run of a proprietary test system and
discused on the mailing list [1] and initially thought not to
be an issue due to RES0 being technically allowed to be
written to and read back as long as the implementation does
not use the RES0 bits. It is very possible that the values
are used in comparison without masking, as pointed out by
Peter in [2], if (cs->hppi.prio >= cs->icc_pmr_el1) may well
do the wrong thing.

Masking these values in ic{c,v}_fullprio_mask() should fix
this and prevent any future problems with playing with the
values.

[1]: https://lists.nongnu.org/archive/html/qemu-arm/2023-11/msg00607.html
[2]: https://lists.nongnu.org/archive/html/qemu-arm/2023-11/msg00737.html

Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
Message-id: 20231116172818.792364-1-ben.dooks@codethink.co.uk
Suggested-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2023-11-20 15:11:35 +00:00
..
allwinner-a10-pic.c hw/intc/allwinner-a10-pic: Handle IRQ levels other than 0 or 1 2023-06-19 11:24:21 +01:00
apic_common.c hw/intc/apic: Use ERRP_GUARD() in apic_common_realize() 2023-10-19 23:13:28 +02:00
apic.c apic: disable reentrancy detection for apic-msi 2023-04-28 11:31:54 +02:00
arm_gic_common.c hw/intc/arm_gic: Rename 'first_cpu' argument 2023-06-28 14:27:59 +02:00
arm_gic_kvm.c migration: simplify blockers 2023-10-20 08:51:41 +02:00
arm_gic.c arm: spelling fixes 2023-07-25 17:13:53 +03:00
arm_gicv2m.c
arm_gicv3_common.c hw/intc/arm_gic: Un-inline GIC*/ITS class_name() helpers 2023-06-28 14:27:59 +02:00
arm_gicv3_cpuif_common.c hw/intc/arm_gicv3: Extract gicv3_set_gicv3state from arm_gicv3_cpuif.c 2021-12-15 10:11:34 +00:00
arm_gicv3_cpuif.c hw/intc/arm_gicv3: ICC_PMR_EL1 high bits should be RAZ 2023-11-20 15:11:35 +00:00
arm_gicv3_dist.c bulk: Rename TARGET_FMT_plx -> HWADDR_FMT_plx 2023-01-18 11:14:34 +01:00
arm_gicv3_its_common.c kvm: require KVM_CAP_SIGNAL_MSI 2023-10-25 17:35:14 +02:00
arm_gicv3_its_kvm.c kvm: require KVM_IRQFD for kernel irqchip 2023-10-25 17:35:15 +02:00
arm_gicv3_its.c hw/intc/arm_gicv3_its: Avoid shadowing variable in do_process_its_cmd() 2023-09-29 10:07:18 +02:00
arm_gicv3_kvm.c migration: simplify blockers 2023-10-20 08:51:41 +02:00
arm_gicv3_redist.c arm: spelling fixes 2023-07-25 17:13:53 +03:00
arm_gicv3.c hw/intc/arm_gicv3: Specify valid and impl in MemoryRegionOps 2022-03-07 13:16:50 +00:00
armv7m_nvic.c target/arm: Move feature test functions to their own header 2023-10-27 11:44:32 +01:00
aspeed_vic.c
bcm2835_ic.c Mark remaining global TypeInfo instances as const 2022-02-21 13:30:20 +00:00
bcm2836_control.c Mark remaining global TypeInfo instances as const 2022-02-21 13:30:20 +00:00
etraxfs_pic.c
exynos4210_combiner.c bulk: Rename TARGET_FMT_plx -> HWADDR_FMT_plx 2023-01-18 11:14:34 +01:00
exynos4210_gic.c Misc cleanups 2022-04-21 09:27:54 -07:00
gic_internal.h
gicv3_internal.h hw/intc/arm_gicv3: Update ID and feature registers for GICv4 2022-04-22 14:44:53 +01:00
goldfish_pic.c hw/m68k: Fix typo in SPDX tag 2021-11-09 10:11:27 +01:00
grlib_irqmp.c
heathrow_pic.c hw/ppc/mac.h: Rename to include/hw/nvram/mac_nvram.h 2022-10-31 18:48:23 +00:00
i8259_common.c hw/intc/i8259: Implement legacy LTIM Edge/Level Bank Select 2023-03-08 00:37:48 +01:00
i8259.c hw/intc/i8259: Implement legacy LTIM Edge/Level Bank Select 2023-03-08 00:37:48 +01:00
imx_avic.c
imx_gpcv2.c
intc.c
ioapic_common.c hw: Move ioapic*.h to intc/ 2023-02-27 22:29:01 +01:00
ioapic_internal.h hw: Move ioapic*.h to intc/ 2023-02-27 22:29:01 +01:00
ioapic.c hw/intc/ioapic: Update KVM routes before redelivering IRQ, on RTE update 2023-03-15 11:52:25 +01:00
Kconfig s390x: Fix QEMU abort by selecting S390_FLIC_KVM 2023-07-18 09:36:27 +02:00
kvm_irqcount.c hw/intc: Extract the IRQ counting functions into a separate file 2023-01-13 16:22:57 +01:00
loongarch_extioi.c hw/other: spelling fixes 2023-09-21 11:31:16 +03:00
loongarch_ipi.c hw/intc: Set physical cpuid route for LoongArch ipi device 2023-06-16 17:58:46 +08:00
loongarch_pch_msi.c hw/intc/loongarch_pch_msi: add irq number property 2023-01-06 10:54:20 +08:00
loongarch_pch_pic.c hw/intc/loongarch_pch: fix edge triggered irq handling 2023-08-24 11:17:59 +08:00
loongson_liointc.c hw/other: spelling fixes 2023-09-21 11:31:16 +03:00
m68k_irqc.c hw/m68k/irqc: Pass CPU using QOM link property 2023-11-01 07:20:34 +01:00
meson.build meson: Replace softmmu_ss -> system_ss 2023-06-20 10:01:30 +02:00
mips_gic.c accel/tcg: Replace CPUState.env_ptr with cpu_env() 2023-10-04 11:03:54 -07:00
nios2_vic.c hw/intc: Vectored Interrupt Controller (VIC) 2022-04-26 08:17:05 -07:00
omap_intc.c hw/other: spelling fixes 2023-09-21 11:31:16 +03:00
ompic.c
openpic_kvm.c memory: Name all the memory listeners 2021-09-30 15:30:24 +02:00
openpic.c hw/intc/openpic: Clean up local variable shadowing 2023-09-29 10:07:17 +02:00
pl190.c
pnv_xive2_regs.h pnv/xive2: Add definition for the ESB cache configuration register 2023-06-10 10:19:24 -03:00
pnv_xive2.c ppc/xive: Use address_space routines to access the machine RAM 2023-09-06 11:19:33 +02:00
pnv_xive_regs.h ppc/xive: Handle END triggers between chips with MMIOs 2023-09-06 11:19:33 +02:00
pnv_xive.c hw/other: spelling fixes 2023-09-21 11:31:16 +03:00
ppc-uic.c hw/intc/ppc-uic: Convert ppc-uic to a PPC4xx DCR device 2022-08-31 14:08:06 -03:00
realview_gic.c
riscv_aclint.c accel/tcg: Replace CPUState.env_ptr with cpu_env() 2023-10-04 11:03:54 -07:00
riscv_aplic.c target/riscv: move KVM only files to kvm subdir 2023-10-12 12:20:24 +10:00
riscv_imsic.c accel/tcg: Replace CPUState.env_ptr with cpu_env() 2023-10-04 11:03:54 -07:00
rx_icu.c
s390_flic_kvm.c s390x: spelling fixes 2023-07-25 17:13:45 +03:00
s390_flic.c
sh_intc.c hw/intc/sh_intc: Remove unneeded local variable initialisers 2021-10-30 18:39:37 +02:00
sifive_plic.c hw/intc: sifive_plic: Fix the pending register range check 2023-01-06 10:42:55 +10:00
slavio_intctl.c
spapr_xive_kvm.c hw/other: spelling fixes 2023-09-21 11:31:16 +03:00
spapr_xive.c hw/intc/spapr_xive: Do not use SysBus API to map local MMIO region 2023-10-19 23:13:28 +02:00
trace-events pnv/xive: Print CPU target in all TIMA traces 2023-07-07 04:46:12 -03:00
trace.h
vgic_common.h
xics_kvm.c Remove qemu-common.h include from most units 2022-04-06 14:31:55 +02:00
xics_pnv.c
xics_spapr.c
xics.c migration: Hack to maintain backwards compatibility for ppc 2023-11-01 16:13:58 +01:00
xilinx_intc.c hw/intc/xilinx_intc: Use 'XpsIntc' typedef instead of 'struct xlx_pic' 2023-01-12 17:15:09 +00:00
xive2.c hw/other: spelling fixes 2023-09-21 11:31:16 +03:00
xive.c hw/other: spelling fixes 2023-09-21 11:31:16 +03:00
xlnx-pmu-iomod-intc.c
xlnx-zynqmp-ipi.c