diff options
author | Marc Zyngier <marc.zyngier@arm.com> | 2018-02-12 19:50:19 +0300 |
---|---|---|
committer | Marc Zyngier <marc.zyngier@arm.com> | 2018-03-19 16:05:37 +0300 |
commit | 3c5e81232ea489845359f7a03a4fb52b29072db8 (patch) | |
tree | dc2731c2e91fcf23933927efee06e1eea8189751 /arch/arm64/include/asm/kvm_mmu.h | |
parent | 6bb934af1f737eba51e2f3f73760715788a7e283 (diff) | |
download | linux-3c5e81232ea489845359f7a03a4fb52b29072db8.tar.xz |
arm64: KVM: Move vector offsetting from hyp-init.S to kvm_get_hyp_vector
We currently provide the hyp-init code with a kernel VA, and expect
it to turn it into a HYP va by itself. As we're about to provide
the hypervisor with mappings that are not necessarily in the memory
range, let's move the kern_hyp_va macro to kvm_get_hyp_vector.
No functionnal change.
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'arch/arm64/include/asm/kvm_mmu.h')
-rw-r--r-- | arch/arm64/include/asm/kvm_mmu.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/arm64/include/asm/kvm_mmu.h b/arch/arm64/include/asm/kvm_mmu.h index a84e2dd14ebe..8cd37eac6292 100644 --- a/arch/arm64/include/asm/kvm_mmu.h +++ b/arch/arm64/include/asm/kvm_mmu.h @@ -374,6 +374,7 @@ static inline void *kvm_get_hyp_vector(void) vect = lm_alias(vect); } + vect = kern_hyp_va(vect); return vect; } @@ -387,7 +388,7 @@ static inline int kvm_map_vectors(void) #else static inline void *kvm_get_hyp_vector(void) { - return kvm_ksym_ref(__kvm_hyp_vector); + return kern_hyp_va(kvm_ksym_ref(__kvm_hyp_vector)); } static inline int kvm_map_vectors(void) |