Release all advisory locks held for the disk images. This should only be called when the VM is stopped and the VMM supposed to shut down. A new VMM, either after a live migration or a state save/resume cycle, should then acquire all locks before the VM starts to run.
(&self)
| 2610 | /// state save/resume cycle, should then acquire all locks before the VM |
| 2611 | /// starts to run. |
| 2612 | pub fn release_disk_locks(&self) -> DeviceManagerResult<()> { |
| 2613 | for dev in &self.block_devices { |
| 2614 | let mut dev = dev.lock().unwrap(); |
| 2615 | dev.unlock_image() |
| 2616 | .map_err(DeviceManagerError::DiskLockError)?; |
| 2617 | } |
| 2618 | Ok(()) |
| 2619 | } |
| 2620 | |
| 2621 | fn make_virtio_devices(&mut self) -> DeviceManagerResult<()> { |
| 2622 | // Create "standard" virtio devices (net/block/rng) |
nothing calls this directly
no test coverage detected