path: root/arch/arm64/kvm/hyp/hyp-entry.S
diff options
authorMarc Zyngier <marc.zyngier@arm.com>2017-04-03 19:37:35 +0100
committerChristoffer Dall <cdall@linaro.org>2017-04-09 07:49:18 -0700
commit6c9ae25dfcaea32512fc27308c64e78159c46aeb (patch)
treed23f2e163b98dcb6468545cc7a6ab84c1002aafe /arch/arm64/kvm/hyp/hyp-entry.S
parentarm64: hyp-stub: Stop pointlessly clobbering lr (diff)
arm64: KVM: Move lr save/restore to do_el2_call
At the moment, we only save/restore lr if on VHE, as we rely only the EL1 code to have preserved it in the non-VHE case. As we're about to get rid of the latter, let's move the save/restore code to the do_el2_call macro, unifying both code paths. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <cdall@linaro.org>
Diffstat (limited to '')
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm64/kvm/hyp/hyp-entry.S b/arch/arm64/kvm/hyp/hyp-entry.S
index 5e9052f087f2..d8ef788646c6 100644
--- a/arch/arm64/kvm/hyp/hyp-entry.S
+++ b/arch/arm64/kvm/hyp/hyp-entry.S
@@ -32,17 +32,17 @@
* Shuffle the parameters before calling the function
* pointed to in x0. Assumes parameters in x[1,2,3].
+ str lr, [sp, #-16]!
mov lr, x0
mov x0, x1
mov x1, x2
mov x2, x3
blr lr
+ ldr lr, [sp], #16
- str lr, [sp, #-16]!
- ldr lr, [sp], #16
* We used to rely on having an exception return to get
* an implicit isb. In the E2H case, we don't have it anymore.