mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-05 18:20:34 +00:00
vfio: Don't exit at get_region_info failure
At vfio device initialization, it will probe all the defined regions, most device don't have vga region, then when crosvm probe vga region info, kernel vfio will return -EINVAL. So when error happens, it should continue getting the next region info, instead of exit. BUG=None TEST=passthrough non graphic device into guest Change-Id: If4d2f723df45f58ccd733e03c854cdcef3530bdb Signed-off-by: Xiong Zhang <xiong.y.zhang@intel.corp-partner.google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/1918486 Reviewed-by: Daniel Verkamp <dverkamp@chromium.org> Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
parent
1de388ae02
commit
40a721b434
1 changed files with 1 additions and 1 deletions
|
@ -485,7 +485,7 @@ impl VfioDevice {
|
|||
// and we verify the return value.
|
||||
ret = unsafe { ioctl_with_mut_ref(dev, VFIO_DEVICE_GET_REGION_INFO(), &mut reg_info) };
|
||||
if ret < 0 {
|
||||
return Err(VfioError::VfioDeviceGetRegionInfo(get_error()));
|
||||
continue;
|
||||
}
|
||||
|
||||
let region = VfioRegion {
|
||||
|
|
Loading…
Reference in a new issue