mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
vmm: Add support for enabling SVE in vm guests
This change enables SVE automatically if the host support SVE/SVE2. Signed-off-by: Wenyu Huang <huangwenyuu@outlook.com>
This commit is contained in:
committed by
Rob Bradford
parent
2049b2c377
commit
d2a364c5c0
@@ -1881,6 +1881,15 @@ impl cpu::Vcpu for KvmVcpu {
|
||||
.map_err(|e| cpu::HypervisorCpuError::VcpuInit(e.into()))
|
||||
}
|
||||
|
||||
#[cfg(target_arch = "aarch64")]
|
||||
fn vcpu_finalize(&self, feature: i32) -> cpu::Result<()> {
|
||||
self.fd
|
||||
.lock()
|
||||
.unwrap()
|
||||
.vcpu_finalize(&feature)
|
||||
.map_err(|e| cpu::HypervisorCpuError::VcpuFinalize(e.into()))
|
||||
}
|
||||
|
||||
///
|
||||
/// Gets a list of the guest registers that are supported for the
|
||||
/// KVM_GET_ONE_REG/KVM_SET_ONE_REG calls.
|
||||
|
||||
Reference in New Issue
Block a user