diff --git a/mshv-ioctls/src/ioctls/system.rs b/mshv-ioctls/src/ioctls/system.rs index 2ef70717..09efc7cb 100644 --- a/mshv-ioctls/src/ioctls/system.rs +++ b/mshv-ioctls/src/ioctls/system.rs @@ -267,6 +267,7 @@ impl Mshv { pub fn create_vm_with_type(&self, vm_type: VmType) -> Result { let mut mshv_builder = MshvPartitionBuilder::new() .set_partition_creation_flag(HV_PARTITION_CREATION_FLAG_LAPIC_ENABLED as u64) + .set_partition_creation_flag(HV_PARTITION_CREATION_FLAG_X2APIC_CAPABLE as u64) .set_synthetic_processor_feature(SyntheticProcessorFeature::HypervisorPresent) .set_synthetic_processor_feature(SyntheticProcessorFeature::Hv1) .set_synthetic_processor_feature( @@ -285,7 +286,6 @@ impl Mshv { if vm_type == VmType::Snp { mshv_builder = mshv_builder - .set_partition_creation_flag(HV_PARTITION_CREATION_FLAG_X2APIC_CAPABLE as u64) .set_isolation_type(HV_PARTITION_ISOLATION_TYPE_SNP as u64) .set_shared_gpa_boundary_page_number(0_u64); }