diff options
-rw-r--r-- | arch/arm/kvm/init.S | 4 | ||||
-rw-r--r-- | arch/arm64/kvm/hyp-init.S | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/arch/arm/kvm/init.S b/arch/arm/kvm/init.S index 991415d978b6..3988e72d16ff 100644 --- a/arch/arm/kvm/init.S +++ b/arch/arm/kvm/init.S | |||
@@ -99,6 +99,10 @@ __do_hyp_init: | |||
99 | mrc p15, 0, r0, c10, c2, 1 | 99 | mrc p15, 0, r0, c10, c2, 1 |
100 | mcr p15, 4, r0, c10, c2, 1 | 100 | mcr p15, 4, r0, c10, c2, 1 |
101 | 101 | ||
102 | @ Invalidate the stale TLBs from Bootloader | ||
103 | mcr p15, 4, r0, c8, c7, 0 @ TLBIALLH | ||
104 | dsb ish | ||
105 | |||
102 | @ Set the HSCTLR to: | 106 | @ Set the HSCTLR to: |
103 | @ - ARM/THUMB exceptions: Kernel config (Thumb-2 kernel) | 107 | @ - ARM/THUMB exceptions: Kernel config (Thumb-2 kernel) |
104 | @ - Endianness: Kernel config | 108 | @ - Endianness: Kernel config |
diff --git a/arch/arm64/kvm/hyp-init.S b/arch/arm64/kvm/hyp-init.S index d968796f4b2d..c3191168a994 100644 --- a/arch/arm64/kvm/hyp-init.S +++ b/arch/arm64/kvm/hyp-init.S | |||
@@ -80,6 +80,10 @@ __do_hyp_init: | |||
80 | msr mair_el2, x4 | 80 | msr mair_el2, x4 |
81 | isb | 81 | isb |
82 | 82 | ||
83 | /* Invalidate the stale TLBs from Bootloader */ | ||
84 | tlbi alle2 | ||
85 | dsb sy | ||
86 | |||
83 | mrs x4, sctlr_el2 | 87 | mrs x4, sctlr_el2 |
84 | and x4, x4, #SCTLR_EL2_EE // preserve endianness of EL2 | 88 | and x4, x4, #SCTLR_EL2_EE // preserve endianness of EL2 |
85 | ldr x5, =SCTLR_EL2_FLAGS | 89 | ldr x5, =SCTLR_EL2_FLAGS |