aboutsummaryrefslogtreecommitdiff
path: root/target/arm/helper.h
diff options
context:
space:
mode:
authorAlex Bennée <alex.bennee@linaro.org>2019-12-12 11:47:34 +0000
committerPeter Maydell <peter.maydell@linaro.org>2019-12-16 10:52:58 +0000
commitf80741d107673f162e3b097fc76a1590036cc9d1 (patch)
tree3df13acac91a2fd4aa12312fc3216f55a21102f0 /target/arm/helper.h
parentb8b69f4c45894ea05a9c334e76178679ec084565 (diff)
target/arm: ensure we use current exception state after SCR update
A write to the SCR can change the effective EL by droppping the system from secure to non-secure mode. However if we use a cached current_el from before the change we'll rebuild the flags incorrectly. To fix this we introduce the ARM_CP_NEWEL CP flag to indicate the new EL should be used when recomputing the flags. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20191212114734.6962-1-alex.bennee@linaro.org Cc: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20191209143723.6368-1-alex.bennee@linaro.org> Cc: qemu-stable@nongnu.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target/arm/helper.h')
-rw-r--r--target/arm/helper.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/target/arm/helper.h b/target/arm/helper.h
index 7ce5169afb..aa3d8cd08f 100644
--- a/target/arm/helper.h
+++ b/target/arm/helper.h
@@ -91,6 +91,7 @@ DEF_HELPER_2(get_user_reg, i32, env, i32)
DEF_HELPER_3(set_user_reg, void, env, i32, i32)
DEF_HELPER_FLAGS_2(rebuild_hflags_m32, TCG_CALL_NO_RWG, void, env, int)
+DEF_HELPER_FLAGS_1(rebuild_hflags_a32_newel, TCG_CALL_NO_RWG, void, env)
DEF_HELPER_FLAGS_2(rebuild_hflags_a32, TCG_CALL_NO_RWG, void, env, int)
DEF_HELPER_FLAGS_2(rebuild_hflags_a64, TCG_CALL_NO_RWG, void, env, int)