]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: x86/mmu: Use atomic ops to set SPTEs in TDP MMU map
authorBen Gardon <bgardon@google.com>
Tue, 2 Feb 2021 18:57:26 +0000 (10:57 -0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 4 Feb 2021 10:27:44 +0000 (05:27 -0500)
commit15abec89fe7c455065d4623828c95116b66dfd77
tree1286e1602eb7e55325e92b8cb8565f72587e7064
parent535b97fe8e78e16b566bce0688e621aef67935fe
KVM: x86/mmu: Use atomic ops to set SPTEs in TDP MMU map

To prepare for handling page faults in parallel, change the TDP MMU
page fault handler to use atomic operations to set SPTEs so that changes
are not lost if multiple threads attempt to modify the same SPTE.

Reviewed-by: Peter Feiner <pfeiner@google.com>
Signed-off-by: Ben Gardon <bgardon@google.com>
Message-Id: <20210202185734.1680553-21-bgardon@google.com>
[Document new locking rules. - Paolo]
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Documentation/virt/kvm/locking.rst
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/mmu/tdp_mmu.c