]> 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)
commit6d749a90f42b716a0550d1dcf7b394c594b025ec
tree1286e1602eb7e55325e92b8cb8565f72587e7064
parent0e50779c45d1198fa77f712726a6805d86c0ca0d
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