Skip to content

KVM: selftests: Detect if KVM bugged the VM

Sean Christopherson kvm lkml 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest2 patches 7 repliesIn review
  2. v14 patches 8 repliesSuperseded

Changes in v2 from the cover letter

- Drop the ARM patch (not worth the churn).
- Drop macros for ioctls() that return file descriptors. Looking at this with fresh eyes, I agree they do more harm than good. [Oliver]

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2KVM: selftests: Drop the single-underscore ioctl() helperstools/testing/selftests/kvm/include/kvm_util_base.h+19 -230 replies
2/2KVM: selftests: Add logic to detect if ioctl() failed because VM was killedtools/testing/selftests/kvm/include/kvm_util_base.h tools/testing/selftests/kvm/lib/kvm_util.c+35 -66 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/2] KVM: selftests: Detect if KVM bugged the VM

Teach selftests' ioctl() macros to detect and report when an ioctl() unexpectedly fails because KVM has killed and/or bugged the VM. Because selftests does the right thing and tries to gracefully clean up VMs, a bugged VM can generate confusing errors, e.g. when deleting memslots.

v2:
- Drop the ARM patch (not worth the churn).
- Drop macros for ioctls() that return file descriptors. Looking at this with fresh eyes, I agree they do more harm than good. [Oliver]

v1: https://lore.kernel.org/all/[email protected]

Sean Christopherson (2):
KVM: selftests: Drop the single-underscore ioctl() helpers
KVM: selftests: Add logic to detect if ioctl() failed because VM was
killed

 .../selftests/kvm/include/kvm_util_base.h     | 75 ++++++++++++-------
 tools/testing/selftests/kvm/lib/kvm_util.c    |  2 +-
 2 files changed, 51 insertions(+), 26 deletions(-)

base-commit: 45b890f7689eb0aba454fc5831d2d79763781677

Signature · 1 line
2.42.0.869.gea05f2083d-goog