pci, vmm: Move to upstream vfio-ioctls crate

This commit moves both pci and vmm code from the internal vfio-ioctls
crate to the upstream one from the rust-vmm project.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
Sebastien Boeuf
2021-02-23 15:01:31 +01:00
committed by Samuel Ortiz
parent aee1155870
commit a0a89b1346
7 changed files with 42 additions and 24 deletions

View File

@@ -2691,12 +2691,8 @@ impl DeviceManager {
.map_err(DeviceManagerError::VfioCreate)?,
);
let vfio_device = VfioDevice::new(
&device_cfg.path,
Arc::clone(&vfio_container),
device_cfg.iommu,
)
.map_err(DeviceManagerError::VfioCreate)?;
let vfio_device = VfioDevice::new(&device_cfg.path, Arc::clone(&vfio_container))
.map_err(DeviceManagerError::VfioCreate)?;
if device_cfg.iommu {
if let Some(iommu) = &self.iommu_device {
@@ -2731,9 +2727,11 @@ impl DeviceManager {
let mut vfio_pci_device = VfioPciDevice::new(
&self.address_manager.vm,
vfio_device,
vfio_container,
&self.msi_interrupt_manager,
legacy_interrupt_group,
memory,
device_cfg.iommu,
)
.map_err(DeviceManagerError::VfioPciCreate)?;