]> git.baikalelectronics.ru Git - kernel.git/commit
selftests: kvm: do not set guest mode flag
authorPaolo Bonzini <pbonzini@redhat.com>
Mon, 27 Jul 2020 12:45:00 +0000 (08:45 -0400)
committerPaolo Bonzini <pbonzini@redhat.com>
Mon, 27 Jul 2020 13:04:48 +0000 (09:04 -0400)
commitfaea2d99eecb2e91b0a0ee2f7e3975efcef84f5d
tree66df90221f0ff32b681b3840698947e0c1c4757a
parente7d314ad74bfba937c02987d10ad7c34357381da
selftests: kvm: do not set guest mode flag

Setting KVM_STATE_NESTED_GUEST_MODE enables various consistency checks
on VMCS12 and therefore causes KVM_SET_NESTED_STATE to fail spuriously
with -EINVAL.  Do not set the flag so that we're sure to cover the
conditions included by the test, and cover the case where VMCS12 is
set and KVM_SET_NESTED_STATE is called with invalid VMCS12 contents.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
tools/testing/selftests/kvm/x86_64/vmx_set_nested_state_test.c