xref: /cloud-hypervisor/hypervisor/src/mshv/aarch64/mod.rs (revision eb0b14f70ed5ed44b76579145fd2a741c0100ae4)
1 // SPDX-License-Identifier: Apache-2.0 OR BSD-3-Clause
2 //
3 // Copyright © 2025, Microsoft Corporation
4 //
5 pub mod emulator;
6 pub mod gic;
7 use std::fmt;
8 
9 ///
10 /// Export generically-named wrappers of mshv_bindings for Unix-based platforms
11 ///
12 pub use mshv_bindings::StandardRegisters as MshvStandardRegisters;
13 use serde::{Deserialize, Serialize};
14 
15 #[derive(Clone, Serialize, Deserialize)]
16 pub struct VcpuMshvState {
17     pub regs: MshvStandardRegisters,
18 }
19 
20 impl fmt::Display for VcpuMshvState {
21     fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
22         write!(f, "Standard registers: {:?}", self.regs)
23     }
24 }
25