提交 e3ab547f 编写于 作者: W Will Deacon

ARM: kvm: use inner-shareable barriers after TLB flushing

When flushing the TLB at PL2 in response to remapping at stage-2 or VMID
rollover, we have a dsb instruction to ensure completion of the command
before continuing.

Since we only care about other processors for TLB invalidation, use the
inner-shareable variant of the dsb instruction instead.
Acked-by: NMarc Zyngier <marc.zyngier@arm.com>
Reviewed-by: NCatalin Marinas <catalin.marinas@arm.com>
Signed-off-by: NWill Deacon <will.deacon@arm.com>
上级 73a6fdc4
...@@ -142,7 +142,7 @@ target: @ We're now in the trampoline code, switch page tables ...@@ -142,7 +142,7 @@ target: @ We're now in the trampoline code, switch page tables
@ Invalidate the old TLBs @ Invalidate the old TLBs
mcr p15, 4, r0, c8, c7, 0 @ TLBIALLH mcr p15, 4, r0, c8, c7, 0 @ TLBIALLH
dsb dsb ish
eret eret
......
...@@ -55,7 +55,7 @@ ENTRY(__kvm_tlb_flush_vmid_ipa) ...@@ -55,7 +55,7 @@ ENTRY(__kvm_tlb_flush_vmid_ipa)
mcrr p15, 6, r2, r3, c2 @ Write VTTBR mcrr p15, 6, r2, r3, c2 @ Write VTTBR
isb isb
mcr p15, 0, r0, c8, c3, 0 @ TLBIALLIS (rt ignored) mcr p15, 0, r0, c8, c3, 0 @ TLBIALLIS (rt ignored)
dsb dsb ish
isb isb
mov r2, #0 mov r2, #0
mov r3, #0 mov r3, #0
...@@ -79,7 +79,7 @@ ENTRY(__kvm_flush_vm_context) ...@@ -79,7 +79,7 @@ ENTRY(__kvm_flush_vm_context)
mcr p15, 4, r0, c8, c3, 4 mcr p15, 4, r0, c8, c3, 4
/* Invalidate instruction caches Inner Shareable (ICIALLUIS) */ /* Invalidate instruction caches Inner Shareable (ICIALLUIS) */
mcr p15, 0, r0, c7, c1, 0 mcr p15, 0, r0, c7, c1, 0
dsb dsb ish
isb @ Not necessary if followed by eret isb @ Not necessary if followed by eret
bx lr bx lr
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册