• Sean Christopherson's avatar
    KVM: x86/mmu: Let guest use GBPAGES if supported in hardware and TDP is on · 27de9250
    Sean Christopherson authored
    Let the guest use 1g hugepages if TDP is enabled and the host supports
    GBPAGES, KVM can't actively prevent the guest from using 1g pages in this
    case since they can't be disabled in the hardware page walker.  While
    injecting a page fault if a bogus 1g page is encountered during a
    software page walk is perfectly reasonable since KVM is simply honoring
    userspace's vCPU model, doing so arguably doesn't provide any meaningful
    value, and at worst will be horribly confusing as the guest will see
    inconsistent behavior and seemingly spurious page faults.
    Signed-off-by: default avatarSean Christopherson <seanjc@google.com>
    Message-Id: <20210622175739.3610207-55-seanjc@google.com>
    Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
    27de9250
mmu.c 162 KB