mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2025-01-22 20:45:21 +00:00
vmm: device_manager: Add support for hotplugging virtio-vsock devices
Create a new VirtioVsock device and add it to the PCI bus upon hotplug. Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
parent
f8501a3bd3
commit
1d61c476a1
@ -2335,6 +2335,12 @@ impl DeviceManager {
|
||||
let (device, iommu_attached, id) = self.make_virtio_net_device(net_cfg)?;
|
||||
self.hotplug_virtio_pci_device(device, iommu_attached, id)
|
||||
}
|
||||
|
||||
#[cfg(feature = "pci_support")]
|
||||
pub fn add_vsock(&mut self, vsock_cfg: &mut VsockConfig) -> DeviceManagerResult<()> {
|
||||
let (device, iommu_attached, id) = self.make_virtio_vsock_device(vsock_cfg)?;
|
||||
self.hotplug_virtio_pci_device(device, iommu_attached, id)
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "acpi")]
|
||||
|
Loading…
x
Reference in New Issue
Block a user