KVM: x86/mmu: Tear down roots before kvm_mmu_zap_all_fast returns
mainline inclusion from mainline-v5.13-rc1 commit 4c6654bd category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I7S3VQ CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=4c6654bd160dbf4503b360ef8eed80b99eb1b8d9 ---------------------------------------------------------------------- To avoid saddling a vCPU thread with the work of tearing down an entire paging structure, take a reference on each root before they become obsolete, so that the thread initiating the fast invalidation can tear down the paging structure and (most likely) release the last reference. As a bonus, this teardown can happen under the MMU lock in read mode so as not to block the progress of vCPU threads. Signed-off-by:Ben Gardon <bgardon@google.com> Message-Id: <20210401233736.638171-14-bgardon@google.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com> Signed-off-by:
Yu Zhang <yu.c.zhang@linux.intel.com>
Loading
Please sign in to comment