]> git.baikalelectronics.ru Git - kernel.git/commit
selftests: kvm: Clear uc so UCALL_NONE is being properly reported
authorAaron Lewis <aaronlewis@google.com>
Mon, 12 Oct 2020 19:47:14 +0000 (12:47 -0700)
committerPaolo Bonzini <pbonzini@redhat.com>
Sun, 8 Nov 2020 11:02:14 +0000 (06:02 -0500)
commit7c4ee8feea30584698c91449b345e5fa7a94428a
treee0d4b78513754bbc44398e409e3c3f3eae9452e5
parent4873485a5ba95600abfa73b05d420687fa159775
selftests: kvm: Clear uc so UCALL_NONE is being properly reported

Ensure the out value 'uc' in get_ucall() is properly reporting
UCALL_NONE if the call fails.  The return value will be correctly
reported, however, the out parameter 'uc' will not be.  Clear the struct
to ensure the correct value is being reported in the out parameter.

Signed-off-by: Aaron Lewis <aaronlewis@google.com>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Reviewed-by: Alexander Graf <graf@amazon.com>
Message-Id: <20201012194716.3950330-3-aaronlewis@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
tools/testing/selftests/kvm/lib/aarch64/ucall.c
tools/testing/selftests/kvm/lib/s390x/ucall.c
tools/testing/selftests/kvm/lib/x86_64/ucall.c