mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
hypervisor: Add api to set sev control register
This register configures the SEV feature control state on a virtual processor. Signed-off-by: Jinank Jain <jinankjain@microsoft.com> Signed-off-by: Muminul Islam <muislam@microsoft.com>
This commit is contained in:
@@ -272,6 +272,12 @@ pub enum HypervisorCpuError {
|
||||
///
|
||||
#[error("Failed to get CPUID entries: {0}")]
|
||||
GetCpuidVales(#[source] anyhow::Error),
|
||||
///
|
||||
/// Setting SEV control register error
|
||||
///
|
||||
#[cfg(feature = "sev_snp")]
|
||||
#[error("Failed to set sev control register: {0}")]
|
||||
SetSevControlRegister(#[source] anyhow::Error),
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
@@ -495,4 +501,8 @@ pub trait Vcpu: Send + Sync {
|
||||
) -> Result<[u32; 4]> {
|
||||
unimplemented!()
|
||||
}
|
||||
#[cfg(feature = "mshv")]
|
||||
fn set_sev_control_register(&self, _reg: u64) -> Result<()> {
|
||||
unimplemented!()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user