mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-03 09:55:01 +00:00
dm: add S3 support for UOS
We do: - pause target vm - suspend all virtual devices - wait for resume notification - resume all virtual devices - reset target vm Signed-off-by: Yin Fengwei <fengwei.yin@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -256,6 +256,11 @@ pm1_control_handler(struct vmctx *ctx, int vcpu, int in, int port, int bytes,
|
||||
error = vm_suspend(ctx, VM_SUSPEND_POWEROFF);
|
||||
assert(error == 0 || errno == EALREADY);
|
||||
}
|
||||
|
||||
if ((pm1_control & PM1_SLP_TYP) >> 10 == 3) {
|
||||
error = vm_suspend(ctx, VM_SUSPEND_SUSPEND);
|
||||
assert(error == 0 || errno == EALREADY);
|
||||
}
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
|
Reference in New Issue
Block a user