Skip to content

Commit

Permalink
KVM: arm64: Don't zero VTTBR in __tlb_switch_to_host()
Browse files Browse the repository at this point in the history
HCR_EL2.TGE=0 is sufficient to disable stage-2 translation, so there's
no need to explicitly zero VTTBR_EL2.

Link: https://lore.kernel.org/r/20231018233212.2888027-2-oliver.upton@linux.dev
Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
  • Loading branch information
Oliver Upton committed Oct 20, 2023
1 parent 6465e26 commit 38ce26b
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion arch/arm64/kvm/hyp/vhe/tlb.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ static void __tlb_switch_to_host(struct tlb_inv_context *cxt)
* We're done with the TLB operation, let's restore the host's
* view of HCR_EL2.
*/
write_sysreg(0, vttbr_el2);
write_sysreg(HCR_HOST_VHE_FLAGS, hcr_el2);
isb();

Expand Down

0 comments on commit 38ce26b

Please sign in to comment.