diff options
author | Marc Zyngier <maz@kernel.org> | 2024-08-27 18:26:47 +0100 |
---|---|---|
committer | Marc Zyngier <maz@kernel.org> | 2024-08-27 18:26:47 +0100 |
commit | 0d56099ed557ce7f76c0ede97272fe58dbf0b7f2 (patch) | |
tree | 212799bed0e6318cde5c9663bc7cd39b52f47172 /arch/arm64/kvm/hyp | |
parent | 5be63fc19fcaa4c236b307420483578a56986a37 (diff) | |
parent | ed49fe5a6fb9c1a1bbbf4b5b648c7d34a756cb6d (diff) | |
download | linux-stable-0d56099ed557ce7f76c0ede97272fe58dbf0b7f2.tar.gz linux-stable-0d56099ed557ce7f76c0ede97272fe58dbf0b7f2.tar.bz2 linux-stable-0d56099ed557ce7f76c0ede97272fe58dbf0b7f2.zip |
Merge branch kvm-arm64/tlbi-fixes-6.12 into kvmarm-master/next
* kvm-arm64/tlbi-fixes-6.12:
: .
: A couple of TLB invalidation fixes, only affecting pKVM
: out of tree, courtesy of Will Deacon.
: .
KVM: arm64: Ensure TLBI uses correct VMID after changing context
KVM: arm64: Invalidate EL1&0 TLB entries for all VMIDs in nvhe hyp init
Signed-off-by: Marc Zyngier <maz@kernel.org>
Diffstat (limited to 'arch/arm64/kvm/hyp')
-rw-r--r-- | arch/arm64/kvm/hyp/nvhe/hyp-init.S | 2 | ||||
-rw-r--r-- | arch/arm64/kvm/hyp/nvhe/tlb.c | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/arch/arm64/kvm/hyp/nvhe/hyp-init.S b/arch/arm64/kvm/hyp/nvhe/hyp-init.S index 07120b37da35..401af1835be6 100644 --- a/arch/arm64/kvm/hyp/nvhe/hyp-init.S +++ b/arch/arm64/kvm/hyp/nvhe/hyp-init.S @@ -130,7 +130,7 @@ alternative_else_nop_endif /* Invalidate the stale TLBs from Bootloader */ tlbi alle2 - tlbi vmalls12e1 + tlbi alle1 dsb sy mov_q x0, INIT_SCTLR_EL2_MMU_ON diff --git a/arch/arm64/kvm/hyp/nvhe/tlb.c b/arch/arm64/kvm/hyp/nvhe/tlb.c index ca3c09df8d7c..48da9ca9763f 100644 --- a/arch/arm64/kvm/hyp/nvhe/tlb.c +++ b/arch/arm64/kvm/hyp/nvhe/tlb.c @@ -132,10 +132,10 @@ static void exit_vmid_context(struct tlb_inv_context *cxt) else __load_host_stage2(); - if (cpus_have_final_cap(ARM64_WORKAROUND_SPECULATIVE_AT)) { - /* Ensure write of the old VMID */ - isb(); + /* Ensure write of the old VMID */ + isb(); + if (cpus_have_final_cap(ARM64_WORKAROUND_SPECULATIVE_AT)) { if (!(cxt->sctlr & SCTLR_ELx_M)) { write_sysreg_el1(cxt->sctlr, SYS_SCTLR); isb(); |