mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
tests: make VFIO memory hotplug more robust
After memory hotplug, it may happen that it takes a few seconds until a VFIO device is available again (IOMMU/DMA mappings need update). On-behalf-of: SAP philipp.schuster@sap.com Signed-off-by: Philipp Schuster <philipp.schuster@cyberus-technology.de>
This commit is contained in:
committed by
Rob Bradford
parent
e6c8b5e816
commit
98aa9d9c12
@@ -8391,8 +8391,10 @@ mod vfio {
|
||||
}));
|
||||
assert!(guest.get_total_memory().unwrap_or_default() > 5_760_000);
|
||||
|
||||
// Check the VFIO device works when RAM is increased to 6GiB
|
||||
assert!(guest.check_nvidia_gpu());
|
||||
// Check the VFIO device works when RAM is increased to 6GiB.
|
||||
// After guest memory hotplug, the VMM must refresh VFIO/iommufd DMA
|
||||
// mappings for the passthrough GPU.
|
||||
assert!(wait_until(Duration::from_secs(10), || guest.check_nvidia_gpu()));
|
||||
});
|
||||
|
||||
let _ = child.kill();
|
||||
|
||||
Reference in New Issue
Block a user