vmm: Ensure PIO/MMIO exits complete before pausing only for KVM

MSHV does not require to ensure MMIO/PIO exits complete
before pausing. This patch makes sure the above requirement
by checking the hypervisor type run-time.

Fixes #5037

Signed-off-by: Muminul Islam <muislam@microsoft.com>
(cherry picked from commit 4e3bc20f2c)
This commit is contained in:
Muminul Islam
2023-01-09 13:22:43 -08:00
committed by Bo Chen
parent 3834b43878
commit 8dd4d42053
2 changed files with 10 additions and 6 deletions

View File

@@ -61,7 +61,7 @@ pub use vm::{
Vm, VmOps,
};
#[derive(Debug, Copy, Clone)]
#[derive(Debug, Copy, Clone, Eq, PartialEq)]
pub enum HypervisorType {
Kvm,
Mshv,