pub struct AxVMConfig {
pub cpu_config: AxVCpuConfig,
pub image_config: VMImageConfig,
/* private fields */
}Expand description
A part of AxVMCrateConfig, which represents a VM.
Fields§
§cpu_config: AxVCpuConfigvCPU configuration.
image_config: VMImageConfigVM image configuration.
Implementations§
Source§impl AxVMConfig
impl AxVMConfig
Sourcepub fn image_config(&self) -> &VMImageConfig
pub fn image_config(&self) -> &VMImageConfig
Returns configurations related to VM image load addresses.
Sourcepub fn bsp_entry(&self) -> GuestPhysAddr
pub fn bsp_entry(&self) -> GuestPhysAddr
Returns the entry address in GPA for the Bootstrap Processor (BSP).
Sourcepub fn ap_entry(&self) -> GuestPhysAddr
pub fn ap_entry(&self) -> GuestPhysAddr
Returns the entry address in GPA for the Application Processor (AP).
Sourcepub fn phys_cpu_ls_mut(&mut self) -> &mut PhysCpuList
pub fn phys_cpu_ls_mut(&mut self) -> &mut PhysCpuList
Returns a mutable reference to the physical CPU list.
Sourcepub fn excluded_devices(&self) -> &Vec<Vec<String>>
pub fn excluded_devices(&self) -> &Vec<Vec<String>>
Returns the list of excluded devices.
Sourcepub fn pass_through_addresses(&self) -> &Vec<PassThroughAddressConfig>
pub fn pass_through_addresses(&self) -> &Vec<PassThroughAddressConfig>
Returns the list of passthrough address configurations.
Sourcepub fn emu_devices(&self) -> &Vec<EmulatedDeviceConfig>
pub fn emu_devices(&self) -> &Vec<EmulatedDeviceConfig>
Returns configurations related to VM emulated devices.
Sourcepub fn pass_through_devices(&self) -> &Vec<PassThroughDeviceConfig>
pub fn pass_through_devices(&self) -> &Vec<PassThroughDeviceConfig>
Returns configurations related to VM passthrough devices.
Sourcepub fn add_pass_through_device(&mut self, device: PassThroughDeviceConfig)
pub fn add_pass_through_device(&mut self, device: PassThroughDeviceConfig)
Adds a new passthrough device to the VM configuration.
Sourcepub fn remove_pass_through_device(&mut self, device: PassThroughDeviceConfig)
pub fn remove_pass_through_device(&mut self, device: PassThroughDeviceConfig)
Removes passthrough device from the VM configuration.
Sourcepub fn clear_pass_through_devices(&mut self)
pub fn clear_pass_through_devices(&mut self)
Clears all passthrough devices from the VM configuration.
Sourcepub fn add_pass_through_spi(&mut self, spi: u32)
pub fn add_pass_through_spi(&mut self, spi: u32)
Adds a passthrough SPI to the VM configuration.
Sourcepub fn pass_through_spis(&self) -> &Vec<u32>
pub fn pass_through_spis(&self) -> &Vec<u32>
Returns the list of passthrough SPIs.
Sourcepub fn interrupt_mode(&self) -> VMInterruptMode
pub fn interrupt_mode(&self) -> VMInterruptMode
Returns the interrupt mode of the VM.
Sourcepub fn relocate_kernel_image(&mut self, kernel_load_gpa: GuestPhysAddr)
pub fn relocate_kernel_image(&mut self, kernel_load_gpa: GuestPhysAddr)
Relocate the guest kernel image while preserving the configured entry-point offsets relative to the load address.