KVM: x86: compile out TDP MMU on 32-bit systems
mainline inclusion from mainline-v5.12-rc1 commit 897218ff 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=897218ff7cf19290ec2d69652ce673d8ed6fedeb ---------------------------------------------------------------------- The TDP MMU assumes that it can do atomic accesses to 64-bit PTEs. Rather than just disabling it, compile it out completely so that it is possible to use for example 64-bit xchg. To limit the number of stubs, wrap all accesses to tdp_mmu_enabled or tdp_mmu_page with a function. Calls to all other functions in tdp_mmu.c are eliminated and do not even reach the linker. Reviewed-by:Sean Christopherson <seanjc@google.com> Tested-by:
Sean Christopherson <seanjc@google.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com> conflict: arch/x86/include/asm/kvm_host.h arch/x86/kvm/mmu/mmu.c Signed-off-by:
Yu Zhang <yu.c.zhang@linux.intel.com>
Loading
Please sign in to comment