Skip to main content

Crate axdevice

Crate axdevice 

Source
Expand description

This module is designed for an environment where the standard library is not available (no_std).

The alloc crate is used to enable dynamic memory allocation in the absence of the standard library.

The log crate is included for logging purposes, with macros being imported globally.

The module is structured into two main parts: config and device, which manage the configuration and handling of AxVm devices respectively.

Structs§

DeviceBuildContext
VM-owned services available while a device factory is building a device.
DeviceBundle
A set of device capabilities that must be registered atomically.
DeviceFactoryRegistry
A registry containing at most one factory for each emulated device type.
DeviceRuntime
Per-VM runtime that owns the static emulated-device topology.
DeviceServices
VM-local registry of typed services.
FwCfg
Minimal QEMU-compatible fw_cfg MMIO device.
FwCfgAcpiBlobs
Prebuilt platform firmware blobs exposed through fw_cfg file entries.
FwCfgBuildConfig
Runtime image payload used to build one fw_cfg device contribution.
FwCfgDeviceFactory
Builds fw_cfg as a normal capability-declaring device contribution.
FwCfgDmaDevice
Runtime adapter that gives fw_cfg DMA access only to the current bus access.
FwCfgPayloadConfig
VM-local factory input supplied by the boot-image loader.
FwCfgPayloadFactory
Factory that joins boot-image payloads to the configured fw_cfg device.
FwCfgPlatformConfig
FwCfgRamRegion
GuestPhysAddr
Guest physical address.
GuestRangeAllocatorKey
Type key for the VM’s IVC guest-range allocator service.
IoApicInterrupt
A routed interrupt from the virtual IO APIC.
Port
The port number of an x86 I/O operation.
RuntimeAccessPorts
VM runtime capabilities injected into one sealed DeviceRuntime.
SysRegAddr
A system register address.
X86InterruptDomainKey
Typed service key for the VM’s x86 interrupt-domain adapter.
X86IoApicDevice
Unified-device adapter for EmulatedIoApic.
X86IoApicServiceKey
Typed service key for the VM’s x86 virtual I/O APIC.
X86PitDevice
Unified-device adapter for EmulatedPit.
X86PitServiceKey
Typed service key for the VM’s x86 virtual PIT.
X86SerialPortDevice
Unified-device adapter for EmulatedSerialPort.
X86SerialServiceKey
Typed service key for the VM’s COM1 serial input capability.

Enums§

AccessWidth
The width of a guest bus access.
DeviceManagerError
Errors reported while configuring, registering, or accessing VM devices.
DeviceRegistration
One strongly typed capability contributed by a device.
ServiceCardinality
Declares whether a service key may have one or several providers.

Traits§

Device
The unified device trait.
DeviceFactory
Builds all capabilities contributed by one emulated device type.
DeviceLifecycle
Optional lifecycle operations contributed by a device.
GuestRangeAllocator
Allocates guest-physical ranges from one statically reserved window.
IrqResolver
Resolves a VM-local interrupt line for a device under construction.
PollableDeviceOps
A device capability that can be polled by the VM runtime.
ServiceKey
Names and types one service made available by a device contribution.
StopAccessPort
Runtime backend for access-scoped VM stop requests.
TimerAccessPort
Runtime backend for access-scoped virtual timer requests.
WakeAccessPort
Runtime backend for access-scoped vCPU wake requests.
X86InterruptDomainOps
x86 interrupt-controller operations needed by the VM interrupt runtime.
X86IoApicDeviceOps
Type-specific IOAPIC capability used by the x86 interrupt runtime.
X86PitDeviceOps
Type-specific PIT capability used by the x86 interrupt runtime.
X86SerialDeviceOps
Type-specific COM1 capability used by the x86 interrupt runtime.

Functions§

register_builtin_factories
Registers device factories that do not depend on an architecture backend.

Type Aliases§

DeviceManagerResult
Result type returned by device manager operations.