Skip to main content

World

Struct World 

Source
struct World {
Show 20 fields record: WorldRecord, memory: Option<WorldMemory>, vcpus: Vec<VcpuSlot>, exits: ExitQueue, closing: bool, paused: bool, machine: Machine, stats: WorldStats, timing: WorldTiming, handler_timing: ExitLatencyHistogram, pending_console_input: Vec<u8>, console_output: Vec<u8>, pending_frames: Vec<Vec<u8>>, network_output: Vec<Vec<u8>>, network_output_bytes: usize, modules: Vec<GuestModule>, cmdline: [u8; 256], cmdline_len: usize, iommu: IommuModel, iommu_domain: Option<DomainId>,
}
Expand description

Registered world: public record + lazy guest memory + logical vCPUs.

Fields§

§record: WorldRecord§memory: Option<WorldMemory>§vcpus: Vec<VcpuSlot>§exits: ExitQueue§closing: bool

Destruction in progress: any new operation is refused and the vCPU tasks are stopped before the memory is freed.

§paused: bool

Paused world: RUNs are refused (Paused) until resumed.

§machine: Machine

Guest chipset devices (8259A pair, I/O APIC) and the kernel bridge that replays their accesses without leaving the kernel.

§stats: WorldStats

Cumulative execution counters (diagnostics).

§timing: WorldTiming

Cumulative exit-latency aggregates, per exit class (diagnostics).

Taken out of the registry while a vCPU of the world runs, with the same take/put pattern as stats, so that the running guest never takes the registry lock and the exit path never allocates.

§handler_timing: ExitLatencyHistogram

Cumulative latency of the in-kernel device-model replay (fast-path exits), in time-stamp counter cycles. Same lifetime and take/put rules as timing.

§pending_console_input: Vec<u8>

Console input queued by the user side, delivered at the next RUN.

§console_output: Vec<u8>

Console output produced by the guest, drained by the user side.

§pending_frames: Vec<Vec<u8>>

Frames queued for the guest network device, delivered at the next RUN.

§network_output: Vec<Vec<u8>>

Frames transmitted by the guest, waiting for the network front-end.

§network_output_bytes: usize

Octets currently queued in network_output (bounded).

§modules: Vec<GuestModule>

Guest modules/initrd ranges (bounded, insertion order).

§cmdline: [u8; 256]

Guest command line (NUL padded; cmdline_len is authoritative).

§cmdline_len: usize

Number of valid bytes in cmdline.

§iommu: IommuModel

Device translation model of this world (IOMMU).

The model is pure and owns no frame: it maps device-visible addresses to host frames already owned by memory. It is empty until the first SYS_VMM_MAP_IOMMU call, which lazily allocates the domain.

§iommu_domain: Option<DomainId>

Address space allocated in iommu, if any.

Auto Trait Implementations§

§

impl !RefUnwindSafe for World

§

impl !UnwindSafe for World

§

impl Forget for World

§

impl Freeze for World

§

impl Move for World

§

impl Send for World

§

impl Sync for World

§

impl Unpin for World

§

impl UnsafeUnpin for World

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.