target/arm: Fix PAuth keys access checks for disabled SEL2
PATCH 1/1 target/arm: Fix PAuth keys access checks for disabled SEL2
As per the description of the HCR_EL2.APK field in the ARMv8 ARM, Pointer Authentication keys accesses should only be trapped to Secure EL2 if it is enabled.
Signed-off-by Florian Lugou <[email protected]>
--- target/arm/helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
target/arm/helper.c +1 -1
@@ -6758,7 +6758,7 @@ static CPAccessResult access_pauth(CPUARMState *env, const ARMCPRegInfo *ri,int el =arm_current_el (env);if (el <2 && -arm_feature (env,ARM_FEATURE_EL2 ) && +arm_is_el2_enabled (env) && !(arm_hcr_el2_eff (env) &HCR_APK )) {return CP_ACCESS_TRAP_EL2 ; }
Signature · 1 line
2.25.1
Quoted 8 lines · Florian Lugou
As per the description of the HCR_EL2.APK field in the ARMv8 ARM, Pointer Authentication keys accesses should only be trapped to Secure EL2 if it is enabled.
Signed-off-by Florian Lugou <[email protected]>--- target/arm/helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Reviewed-by Richard Henderson <[email protected]>
r~
Quoted 10 lines · Florian Lugou
As per the description of the HCR_EL2.APK field in the ARMv8 ARM, Pointer Authentication keys accesses should only be trapped to Secure EL2 if it is enabled.
Signed-off-by Florian Lugou <[email protected]>--- target/arm/helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Reviewed-by Peter Maydell <[email protected]>
thanks
-- PMM