Skip to content

tools/vmtb: Sync VM Test Bench core with current xe SR-IOV

Adam Miszczak igt-dev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest7 patches 7 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7tools/vmtb: Introduce asynchronous VM state save/load functionstools/vmtb/bench/exceptions.py tools/vmtb/bench/machines/virtual/backends/qmp_monitor.py tools/vmtb/bench/machines/virtual/vm.py+86 -451 reply
2/7tools/vmtb: Rework VF scheduler provisioningtools/vmtb/bench/configurators/vgpu_profile_config.py tools/vmtb/bench/exceptions.py tools/vmtb/bench/machines/physical/device.py +2 more+52 -291 reply
3/7tools/vmtb: Align driver/device layer with current xe SR-IOV interfacestools/vmtb/bench/drivers/driver_interface.py tools/vmtb/bench/drivers/xe.py tools/vmtb/bench/machines/device_interface.py +2 more+44 -261 reply
4/7tools/vmtb: Fix guest timeout handling and PCI BDF matchingtools/vmtb/bench/machines/virtual/vm.py+38 -101 reply
5/7tools/vmtb: Add pre-test environment cleanuptools/vmtb/bench/drivers/driver_interface.py tools/vmtb/bench/drivers/xe.py tools/vmtb/bench/helpers/cleanup.py +2 more+126 -401 reply
6/7tools/vmtb: Add VM dmesg wait supporttools/vmtb/bench/machines/virtual/vm.py+47 -11 reply
7/7tools/vmtb: Extend IGT and WSIM executorstools/vmtb/bench/executors/gem_wsim.py tools/vmtb/bench/executors/igt.py tools/vmtb/vmm_flows/test_migration.py+54 -161 reply

Reviews trailers per patch

All 7 patches have a Reviewed-by or Acked-by.

PatchMarcin Bernatowicz
1/7R-b
2/7R-b
3/7R-b
4/7R-b
5/7R-b
6/7R-b
7/7R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH i-g-t 0/7] tools/vmtb: Sync VM Test Bench core with current xe SR-IOV

This series brings the VM Test Bench (VMTB) core in line with the current xe SR-IOV driver interfaces and fixes a number of robustness issues found while running the vmm_flows test suite on recent kernels. It also adds a few framework features required by upcoming tests.

New framework features:
- asynchronous VM snapshot save/load, enabling parallel migration of multiple VMs (patch 1)
- VirtualMachine.wait_for_dmesg() to block on a guest serial console pattern (patch 6)
- IgtExecutor 'env_vars' support, cached GemWsim results and a common clear_results() for both executors (patch 7)

Driver/device alignment:
- move VF VRAM quota provisioning from the obsolete debugfs lmem_quota to the sysfs sriov_admin profile tree and add DeviceInterface.reset() for PF/VF FLR (patch 3)
- align default VF scheduling with the xe KMD (16ms EQ/PT), rename VfSchedulingMode.INFINITE to AUTO and fix scheduler-only manual provisioning (patch 2)

Robustness fixes:
- consume QMP command acknowledgments and tighten query_status()/ query_jobs() handling so the bench never acts on partial QMP responses (patch 1)
- fix guest timeout resolution, PCI BDF matching and physical Device bind()/unbind() calls (patches 3, 4)
- add EnvironmentCleaner to remove leftovers (orphaned QEMU processes, stale sockets, dirty SR-IOV state) from crashed or timed-out runs before each test setup (patch 5)

Existing vmm_flows tests (test_basic, test_migration) are updated to follow the API changes.

Cc Marcin Bernatowicz <[email protected]>
Cc Kamil Konieczny <[email protected]>

Adam Miszczak (7):
tools/vmtb: Introduce asynchronous VM state save/load functions tools/vmtb: Rework VF scheduler provisioning tools/vmtb: Align driver/device layer with current xe SR-IOV
interfaces
tools/vmtb: Fix guest timeout handling and PCI BDF matching tools/vmtb: Add pre-test environment cleanup tools/vmtb: Add VM dmesg wait support
tools/vmtb: Extend IGT and WSIM executors

 .../configurators/vgpu_profile_config.py      |  20 ++-
 tools/vmtb/bench/drivers/driver_interface.py  |   9 +-
 tools/vmtb/bench/drivers/xe.py                |  40 +++--
 tools/vmtb/bench/exceptions.py                |  14 +-
 tools/vmtb/bench/executors/gem_wsim.py        |  38 ++++-
 tools/vmtb/bench/executors/igt.py             |  10 +-
 tools/vmtb/bench/helpers/cleanup.py           |  91 ++++++++++
 tools/vmtb/bench/machines/device_interface.py |   7 +
 tools/vmtb/bench/machines/physical/device.py  |  58 +++----
 .../machines/virtual/backends/qmp_monitor.py  |  55 +++---
 tools/vmtb/bench/machines/virtual/device.py   |   4 +
 tools/vmtb/bench/machines/virtual/vm.py       | 160 ++++++++++++++----
 tools/vmtb/vmm_flows/conftest.py              |  80 ++++++---
 tools/vmtb/vmm_flows/test_basic.py            |   2 +-
 tools/vmtb/vmm_flows/test_migration.py        |  22 ++-
 15 files changed, 445 insertions(+), 165 deletions(-)
 create mode 100644 tools/vmtb/bench/helpers/cleanup.py
Signature · 1 line
2.39.1