]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
KVM: X86: Fix missing local pCPU when executing wbinvd on all dirty pCPUs
authorWanpeng Li <wanpengli@tencent.com>
Fri, 12 Mar 2021 02:45:51 +0000 (10:45 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 18 Mar 2021 17:55:34 +0000 (13:55 -0400)
commitc2162e13d6e2f43e5001a356196871642de070ba
tree02e4a1d84b6df817d1b5c91f69d2178e5da9980e
parentb318e8decf6b9ef1bcf4ca06fae6d6a2cb5d5c5c
KVM: X86: Fix missing local pCPU when executing wbinvd on all dirty pCPUs

In order to deal with noncoherent DMA, we should execute wbinvd on
all dirty pCPUs when guest wbinvd exits to maintain data consistency.
smp_call_function_many() does not execute the provided function on the
local core, therefore replace it by on_each_cpu_mask().

Reported-by: Nadav Amit <namit@vmware.com>
Cc: Nadav Amit <namit@vmware.com>
Signed-off-by: Wanpeng Li <wanpengli@tencent.com>
Message-Id: <1615517151-7465-1-git-send-email-wanpengli@tencent.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/x86.c