[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 2/8] target/arm: Timer _EL02 registers UNDEF for E2H == 0
From: |
Peter Maydell |
Subject: |
[PATCH 2/8] target/arm: Timer _EL02 registers UNDEF for E2H == 0 |
Date: |
Fri, 1 Mar 2024 18:32:13 +0000 |
The timer _EL02 registers should UNDEF for invalid accesses from EL2
or EL3 when HCR_EL2.E2H == 0, not take a cp access trap. We were
delivering the exception to EL2 with the wrong syndrome.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
target/arm/helper.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/arm/helper.c b/target/arm/helper.c
index 90c4fb72ce4..978df6f2823 100644
--- a/target/arm/helper.c
+++ b/target/arm/helper.c
@@ -6551,7 +6551,7 @@ static CPAccessResult e2h_access(CPUARMState *env, const
ARMCPRegInfo *ri,
return CP_ACCESS_OK;
}
if (!(arm_hcr_el2_eff(env) & HCR_E2H)) {
- return CP_ACCESS_TRAP;
+ return CP_ACCESS_TRAP_UNCATEGORIZED;
}
return CP_ACCESS_OK;
}
--
2.34.1
- Re: [PATCH 3/8] target/arm: use FIELD macro for CNTHCTL bit definitions, (continued)
[PATCH 1/8] target/arm: Move some register related defines to internals.h, Peter Maydell, 2024/03/01
[PATCH 4/8] target/arm: Don't allow RES0 CNTHCTL_EL2 bits to be written, Peter Maydell, 2024/03/01
[PATCH 6/8] target/arm: Define CNTPCTSS_EL0 and CNTVCTSS_EL0, Peter Maydell, 2024/03/01
[PATCH 2/8] target/arm: Timer _EL02 registers UNDEF for E2H == 0,
Peter Maydell <=
[PATCH 5/8] target/arm: Implement new FEAT_ECV trap bits, Peter Maydell, 2024/03/01
[PATCH 7/8] target/arm: Implement FEAT_ECV CNTPOFF_EL2 handling, Peter Maydell, 2024/03/01