Trait virt::aarch64::vp::AccessVpState

source ·
pub trait AccessVpState {
    type Error: 'static + Error + Send + Sync;

    // Required methods
    fn caps(&self) -> &Aarch64PartitionCapabilities;
    fn commit(&mut self) -> Result<(), Self::Error>;
    fn registers(&mut self) -> Result<Registers, Self::Error>;
    fn set_registers(&mut self, value: &Registers) -> Result<(), Self::Error>;
    fn system_registers(&mut self) -> Result<SystemRegisters, Self::Error>;
    fn set_system_registers(
        &mut self,
        value: &SystemRegisters,
    ) -> Result<(), Self::Error>;

    // Provided methods
    fn save_all(&mut self) -> Result<VpSavedState, StateError<Self::Error>> { ... }
    fn restore_all(
        &mut self,
        state: &VpSavedState,
    ) -> Result<(), StateError<Self::Error>> { ... }
    fn reset_all(
        &mut self,
        vp_info: &Aarch64VpInfo,
    ) -> Result<(), StateError<Self::Error>> { ... }
    fn check_reset_all(&mut self, vp_info: &Aarch64VpInfo) { ... }
    fn inspect_all(&mut self, req: Request<'_>) { ... }
}
Expand description

Per-VP state

Required Associated Types§

source

type Error: 'static + Error + Send + Sync

Required Methods§

source

fn caps(&self) -> &Aarch64PartitionCapabilities

Gets the partition’s capabilities.

source

fn commit(&mut self) -> Result<(), Self::Error>

Commits any state changes made with the set_* methods.

source

fn registers(&mut self) -> Result<Registers, Self::Error>

Gets the specified state.

source

fn set_registers(&mut self, value: &Registers) -> Result<(), Self::Error>

Sets the specified state.

source

fn system_registers(&mut self) -> Result<SystemRegisters, Self::Error>

Gets the specified state.

source

fn set_system_registers( &mut self, value: &SystemRegisters, ) -> Result<(), Self::Error>

Sets the specified state.

Provided Methods§

source

fn save_all(&mut self) -> Result<VpSavedState, StateError<Self::Error>>

Save all state that can be restored by a call to restore.

source

fn restore_all( &mut self, state: &VpSavedState, ) -> Result<(), StateError<Self::Error>>

Restore state elements saved in save state.

source

fn reset_all( &mut self, vp_info: &Aarch64VpInfo, ) -> Result<(), StateError<Self::Error>>

Resets all the state elements to their initial state (after machine reset).

source

fn check_reset_all(&mut self, vp_info: &Aarch64VpInfo)

Validates that all state elements are in their initial state (after machine reset).

source

fn inspect_all(&mut self, req: Request<'_>)

Implementors§