aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaron Lindsay <aaron@os.amperecomputing.com>2020-08-25 10:48:10 -0400
committerPeter Maydell <peter.maydell@linaro.org>2020-09-14 14:24:15 +0100
commitdb1f3afb17269cf2bd86c222e1bced748487ef71 (patch)
tree3149a1b751d1d77c6ad49b1f5a0a8851c8f78874
parentd84980051229fa43c96b363f52b3ba9357e6815a (diff)
downloadqemu-arm-db1f3afb17269cf2bd86c222e1bced748487ef71.tar.gz
target/arm: Count PMU events when MDCR.SPME is set
This check was backwards when introduced in commit 033614c47de78409ad3fb39bb7bd1483b71c6789: target/arm: Filter cycle counter based on PMCCFILTR_EL0 Cc: qemu-stable@nongnu.org Signed-off-by: Aaron Lindsay <aaron@os.amperecomputing.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-rw-r--r--target/arm/helper.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/target/arm/helper.c b/target/arm/helper.c
index 44d666627a..88bd9dd35d 100644
--- a/target/arm/helper.c
+++ b/target/arm/helper.c
@@ -1452,7 +1452,7 @@ static bool pmu_counter_enabled(CPUARMState *env, uint8_t counter)
}
} else {
prohibited = arm_feature(env, ARM_FEATURE_EL3) &&
- (env->cp15.mdcr_el3 & MDCR_SPME);
+ !(env->cp15.mdcr_el3 & MDCR_SPME);
}
if (prohibited && counter == 31) {