Re: [PATCH] target/arm/helper: Propagate MDCR_EL2.HPMN into PMCR_EL0.N

2023-12-18 Thread Peter Maydell
On Fri, 15 Dec 2023 at 15:16, Jean-Philippe Brucker wrote: > > MDCR_EL2.HPMN allows an hypervisor to limit the number of PMU counters > available to EL1 and EL0 (to keep the others to itself). QEMU already > implements this split correctly, except for PMCR_EL0.N reads: the number > of counters rea

[PATCH] target/arm/helper: Propagate MDCR_EL2.HPMN into PMCR_EL0.N

2023-12-15 Thread Jean-Philippe Brucker
MDCR_EL2.HPMN allows an hypervisor to limit the number of PMU counters available to EL1 and EL0 (to keep the others to itself). QEMU already implements this split correctly, except for PMCR_EL0.N reads: the number of counters read by EL1 or EL0 should be the one configured in MDCR_EL2.HPMN. Signed