aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm64/kernel
diff options
context:
space:
mode:
authorMarc Zyngier <marc.zyngier@arm.com>2017-04-03 19:38:05 +0100
committerChristoffer Dall <cdall@linaro.org>2017-04-09 07:49:35 -0700
commitaf42f20480bf13d9dbf099ccca65f3de8c44fcaf (patch)
treefda8f02af6f84242bbbedaa5a99185fdc05055e5 /arch/arm64/kernel
parentarm64: hyp-stub/KVM: Kill __hyp_get_vectors (diff)
downloadlinux-dev-af42f20480bf13d9dbf099ccca65f3de8c44fcaf.tar.xz
linux-dev-af42f20480bf13d9dbf099ccca65f3de8c44fcaf.zip
arm64: hyp-stub: Zero x0 on successful stub handling
We now return HVC_STUB_ERR when a stub hypercall fails, but we leave whatever was in x0 on success. Zeroing it on return seems like a good idea. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <cdall@linaro.org>
Diffstat (limited to 'arch/arm64/kernel')
-rw-r--r--arch/arm64/kernel/hyp-stub.S4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/arm64/kernel/hyp-stub.S b/arch/arm64/kernel/hyp-stub.S
index d55604d91e33..e1261fbaa374 100644
--- a/arch/arm64/kernel/hyp-stub.S
+++ b/arch/arm64/kernel/hyp-stub.S
@@ -73,8 +73,10 @@ el1_sync:
/* Someone called kvm_call_hyp() against the hyp-stub... */
ldr x0, =HVC_STUB_ERR
+ eret
-9: eret
+9: mov x0, xzr
+ eret
ENDPROC(el1_sync)
.macro invalid_vector label