diff options
author | Andrew Scull <ascull@google.com> | 2020-09-15 13:46:30 +0300 |
---|---|---|
committer | Marc Zyngier <maz@kernel.org> | 2020-09-15 20:39:02 +0300 |
commit | 6e3bfbb22c51bd1f121ca5c4bce6b51dc6cdceae (patch) | |
tree | 6495478f83b99802268e556ba94edca89f3decde /arch/arm64/include/asm/kvm_asm.h | |
parent | a0e479523e3fb4fa52c351cc4906f38097de789a (diff) | |
download | linux-6e3bfbb22c51bd1f121ca5c4bce6b51dc6cdceae.tar.xz |
KVM: arm64: nVHE: Use separate vector for the host
The host is treated differently from the guests when an exception is
taken so introduce a separate vector that is specialized for the host.
This also allows the nVHE specific code to move out of hyp-entry.S and
into nvhe/host.S.
The host is only expected to make HVC calls and anything else is
considered invalid and results in a panic.
Hyp initialization is now passed the vector that is used for the host
and it is swapped for the guest vector during the context switch.
Signed-off-by: Andrew Scull <ascull@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20200915104643.2543892-7-ascull@google.com
Diffstat (limited to 'arch/arm64/include/asm/kvm_asm.h')
-rw-r--r-- | arch/arm64/include/asm/kvm_asm.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/arm64/include/asm/kvm_asm.h b/arch/arm64/include/asm/kvm_asm.h index a952859117b2..fe51c06d480d 100644 --- a/arch/arm64/include/asm/kvm_asm.h +++ b/arch/arm64/include/asm/kvm_asm.h @@ -111,8 +111,10 @@ struct kvm_vcpu; struct kvm_s2_mmu; DECLARE_KVM_NVHE_SYM(__kvm_hyp_init); +DECLARE_KVM_NVHE_SYM(__kvm_hyp_host_vector); DECLARE_KVM_HYP_SYM(__kvm_hyp_vector); #define __kvm_hyp_init CHOOSE_NVHE_SYM(__kvm_hyp_init) +#define __kvm_hyp_host_vector CHOOSE_NVHE_SYM(__kvm_hyp_host_vector) #define __kvm_hyp_vector CHOOSE_HYP_SYM(__kvm_hyp_vector) #ifdef CONFIG_KVM_INDIRECT_VECTORS |