KVM: selftests: Add a helper to check EPT/VPID capabilities
authorDavid Matlack <dmatlack@google.com>
Fri, 20 May 2022 23:32:44 +0000 (23:32 +0000)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 9 Jun 2022 14:52:24 +0000 (10:52 -0400)
commitc363d95986b1b930947305e2372665141721d15f
treeb5a48b35f49f5b1b49edd1a3034e20f0f22f1e9a
parentb6c086d04c0a1ba356145cdba5b46bd6cea2b9bd
KVM: selftests: Add a helper to check EPT/VPID capabilities

Create a small helper function to check if a given EPT/VPID capability
is supported. This will be re-used in a follow-up commit to check for 1G
page support.

No functional change intended.

Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: David Matlack <dmatlack@google.com>
Message-Id: <20220520233249.3776001-7-dmatlack@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
tools/testing/selftests/kvm/lib/x86_64/vmx.c