diff options
author | Edgar E. Iglesias <edgar.iglesias@xilinx.com> | 2014-08-04 14:41:54 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2014-08-04 14:41:54 +0100 |
commit | 9208b9617f18b56ba4eb32928ae8f6439ba38a24 (patch) | |
tree | ce1ddd6748cdb2761a558a5099347f5d243dcf81 /target-arm/op_helper.c | |
parent | 9db11cef8c557ccc6e0a3e7eca786b197eed5f59 (diff) |
target-arm: A64: Break out aarch64_save/restore_sp
Break out code to save/restore AArch64 SP into functions.
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
Reviewed-by: Greg Bellows <greg.bellows@linaro.org>
Message-id: 1402994746-8328-2-git-send-email-edgar.iglesias@gmail.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target-arm/op_helper.c')
-rw-r--r-- | target-arm/op_helper.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/target-arm/op_helper.c b/target-arm/op_helper.c index 9c1ef525a3..90a946a0fd 100644 --- a/target-arm/op_helper.c +++ b/target-arm/op_helper.c @@ -376,11 +376,7 @@ void HELPER(exception_return)(CPUARMState *env) uint32_t spsr = env->banked_spsr[spsr_idx]; int new_el, i; - if (env->pstate & PSTATE_SP) { - env->sp_el[cur_el] = env->xregs[31]; - } else { - env->sp_el[0] = env->xregs[31]; - } + aarch64_save_sp(env, cur_el); env->exclusive_addr = -1; |