#[non_exhaustive]pub enum VmExit {
Mmio {
addr: u64,
write: bool,
data: ExitData,
},
Pio {
port: u16,
write: bool,
data: ExitData,
},
Hypercall {
func: u64,
args: [u64; 6],
},
Wfi,
Wfe,
Hlt,
Reset,
Shutdown,
Debug(DebugInfo),
InternalError(String),
}Expand description
The reason a vCPU returned from its run loop.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Mmio
Memory-mapped I/O access. The MMIO bus router in squib-vmm dispatches to the
appropriate device emulation.
Fields
Pio
Port-mapped I/O access. x86-only; on other architectures this variant never appears.
Fields
Hypercall
The guest issued a hypercall (HVC on aarch64, VMCALL on x86).
Fields
Wfi
The guest executed WFI (wait-for-interrupt). The vCPU should sleep until an
interrupt is injected.
Wfe
The guest executed WFE (wait-for-event). x86’s HLT maps to VmExit::Hlt instead.
Hlt
The guest executed HLT (x86). Equivalent to WFI in practice.
Reset
The guest issued a system reset.
Shutdown
The guest powered down.
Debug(DebugInfo)
A debug exception (single-step, breakpoint). Surfaced when the optional gdb feature
is wired up; otherwise the backend treats this as an internal error.
InternalError(String)
The hypervisor reported an internal failure that does not fit any of the above variants. The string is for human consumption only; programmatic consumers should treat this as fatal.