Skip to content

Commit ad9b4e9

Browse files
vittyvkgregkh
authored andcommitted
selftests: kvm: vmx_set_nested_state_test: don't check for VMX support twice
[ Upstream commit 700c17d ] vmx_set_nested_state_test() checks if VMX is supported twice: in the very beginning (and skips the whole test if it's not) and before doing test_vmx_nested_state(). One should be enough. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent 4fc9ded commit ad9b4e9

1 file changed

Lines changed: 1 addition & 6 deletions

File tree

‎tools/testing/selftests/kvm/x86_64/vmx_set_nested_state_test.c‎

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -271,12 +271,7 @@ int main(int argc, char *argv[])
271271
state.flags = KVM_STATE_NESTED_RUN_PENDING;
272272
test_nested_state_expect_einval(vm, &state);
273273

274-
/*
275-
* TODO: When SVM support is added for KVM_SET_NESTED_STATE
276-
* add tests here to support it like VMX.
277-
*/
278-
if (entry->ecx & CPUID_VMX)
279-
test_vmx_nested_state(vm);
274+
test_vmx_nested_state(vm);
280275

281276
kvm_vm_free(vm);
282277
return 0;

0 commit comments

Comments
 (0)