summaryrefslogtreecommitdiffstats
path: root/arch/arm/kvm/hyp/hyp.h
diff options
context:
space:
mode:
authorMarc Zyngier2016-01-05 19:40:51 +0100
committerMarc Zyngier2016-02-29 19:34:13 +0100
commit89ef2b21ed2173e01995371261a9f9789bc1e47a (patch)
treea082baca9cc3ae93a67e840178757b16b49f1fc7 /arch/arm/kvm/hyp/hyp.h
parentARM: KVM: Add banked registers save/restore (diff)
downloadkernel-qcow2-linux-89ef2b21ed2173e01995371261a9f9789bc1e47a.tar.gz
kernel-qcow2-linux-89ef2b21ed2173e01995371261a9f9789bc1e47a.tar.xz
kernel-qcow2-linux-89ef2b21ed2173e01995371261a9f9789bc1e47a.zip
ARM: KVM: Add guest entry code
Add the very minimal piece of code that is now required to jump into the guest (and return from it). This code is only concerned with save/restoring the USR registers (r0-r12+lr for the guest, r4-r12+lr for the host), as everything else is dealt with in C (VFP is another matter though). Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'arch/arm/kvm/hyp/hyp.h')
-rw-r--r--arch/arm/kvm/hyp/hyp.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/arm/kvm/hyp/hyp.h b/arch/arm/kvm/hyp/hyp.h
index 278eb1fa5231..b3f6ed233564 100644
--- a/arch/arm/kvm/hyp/hyp.h
+++ b/arch/arm/kvm/hyp/hyp.h
@@ -110,4 +110,6 @@ static inline bool __vfp_enabled(void)
void __hyp_text __banked_save_state(struct kvm_cpu_context *ctxt);
void __hyp_text __banked_restore_state(struct kvm_cpu_context *ctxt);
+int asmlinkage __guest_enter(struct kvm_vcpu *vcpu,
+ struct kvm_cpu_context *host);
#endif /* __ARM_KVM_HYP_H__ */