KVM: x86/mmu: Refactor is_tdp_mmu_root into is_tdp_mmu
authorDavid Matlack <dmatlack@google.com>
Thu, 17 Jun 2021 23:19:47 +0000 (23:19 +0000)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 18 Jun 2021 10:45:46 +0000 (06:45 -0400)
commit63c0cac938edfa5d72bfbe8f1eeb9d47b397829c
treebe51c631aceac5c3a996be1ebe4de5de73a6a563
parent0b873fd7fb53ed7343ee7ee166e1373aec02a9cb
KVM: x86/mmu: Refactor is_tdp_mmu_root into is_tdp_mmu

This change simplifies the call sites slightly and also abstracts away
the implementation detail of looking at root_hpa as the mechanism for
determining if the mmu is the TDP MMU.

Suggested-by: Sean Christopherson <seanjc@google.com>
Signed-off-by: David Matlack <dmatlack@google.com>
Message-Id: <20210617231948.2591431-4-dmatlack@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/mmu/mmu.c
arch/x86/kvm/mmu/tdp_mmu.h