diff --git a/arch/src/x86_64/mod.rs b/arch/src/x86_64/mod.rs index c209eb889..aacacd06e 100644 --- a/arch/src/x86_64/mod.rs +++ b/arch/src/x86_64/mod.rs @@ -609,7 +609,9 @@ pub fn generate_common_cpuid( ]; // Supported CPUID - let mut cpuid = hypervisor.get_cpuid().map_err(Error::CpuidGetSupported)?; + let mut cpuid = hypervisor + .get_supported_cpuid() + .map_err(Error::CpuidGetSupported)?; CpuidPatch::patch_cpuid(&mut cpuid, cpuid_patches); diff --git a/hypervisor/src/hypervisor.rs b/hypervisor/src/hypervisor.rs index 08daee461..fb93a622e 100644 --- a/hypervisor/src/hypervisor.rs +++ b/hypervisor/src/hypervisor.rs @@ -108,7 +108,7 @@ pub trait Hypervisor: Send + Sync { /// /// Get the supported CpuID /// - fn get_cpuid(&self) -> Result>; + fn get_supported_cpuid(&self) -> Result>; /// /// Check particular extensions if any /// diff --git a/hypervisor/src/kvm/mod.rs b/hypervisor/src/kvm/mod.rs index 5b4c65679..62fe5bf03 100644 --- a/hypervisor/src/kvm/mod.rs +++ b/hypervisor/src/kvm/mod.rs @@ -1023,7 +1023,7 @@ impl hypervisor::Hypervisor for KvmHypervisor { /// /// X86 specific call to get the system supported CPUID values. /// - fn get_cpuid(&self) -> hypervisor::Result> { + fn get_supported_cpuid(&self) -> hypervisor::Result> { let kvm_cpuid = self .kvm .get_supported_cpuid(kvm_bindings::KVM_MAX_CPUID_ENTRIES) diff --git a/hypervisor/src/mshv/mod.rs b/hypervisor/src/mshv/mod.rs index b2d046edc..d66231a89 100644 --- a/hypervisor/src/mshv/mod.rs +++ b/hypervisor/src/mshv/mod.rs @@ -270,7 +270,7 @@ impl hypervisor::Hypervisor for MshvHypervisor { /// /// Get the supported CpuID /// - fn get_cpuid(&self) -> hypervisor::Result> { + fn get_supported_cpuid(&self) -> hypervisor::Result> { Ok(Vec::new()) } }