mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
vmm: fix warnings when KVM is not enabled
Some imports are only used by KVM. Some variables and code become dead or unused when KVM is not enabled. Signed-off-by: Wei Liu <liuwe@microsoft.com>
This commit is contained in:
@@ -251,6 +251,7 @@ pub struct Vm {
|
||||
cpu_manager: Arc<Mutex<cpu::CpuManager>>,
|
||||
memory_manager: Arc<Mutex<MemoryManager>>,
|
||||
#[cfg(target_arch = "x86_64")]
|
||||
#[cfg_attr(not(feature = "kvm"), allow(dead_code))]
|
||||
// The hypervisor abstracted virtual machine.
|
||||
vm: Arc<dyn hypervisor::Vm>,
|
||||
#[cfg(target_arch = "x86_64")]
|
||||
|
||||
Reference in New Issue
Block a user