OSDN Git Service

selftests: kvm/x86: add test for pmu msr MSR_IA32_PERF_CAPABILITIES
authorLike Xu <like.xu@linux.intel.com>
Mon, 1 Feb 2021 05:10:39 +0000 (13:10 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 4 Feb 2021 10:27:27 +0000 (05:27 -0500)
commitf88d4f2f287ec062e985b60cbe60f04bd5a8e659
treeb8923cd43a2ac0b814610426af919247d4c2f0ec
parentbe635e34c284d08b1da7f93ddd6a2110617d15e7
selftests: kvm/x86: add test for pmu msr MSR_IA32_PERF_CAPABILITIES

This test will check the effect of various CPUID settings on the
MSR_IA32_PERF_CAPABILITIES MSR, check that whatever user space writes
with KVM_SET_MSR is _not_ modified from the guest and can be retrieved
with KVM_GET_MSR, and check that invalid LBR formats are rejected.

Signed-off-by: Like Xu <like.xu@linux.intel.com>
Message-Id: <20210201051039.255478-12-like.xu@linux.intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
tools/testing/selftests/kvm/.gitignore
tools/testing/selftests/kvm/Makefile
tools/testing/selftests/kvm/include/x86_64/processor.h
tools/testing/selftests/kvm/lib/x86_64/processor.c
tools/testing/selftests/kvm/x86_64/vmx_pmu_msrs_test.c [new file with mode: 0644]