mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-24 02:08:04 +00:00
hv: add vm restart API
And export the API to DM. DM will do system reboot/S3 resume based on this API. Also add the pre-assumption description for some vm APIs. Signed-off-by: Yin Fengwei <fengwei.yin@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -266,6 +266,17 @@ int32_t hcall_create_vcpu(struct vm *vm, uint16_t vmid, uint64_t param)
|
||||
return ret;
|
||||
}
|
||||
|
||||
int32_t hcall_reset_vm(uint16_t vmid)
|
||||
{
|
||||
struct vm *target_vm = get_vm_from_vmid(vmid);
|
||||
|
||||
if ((target_vm == NULL) || is_vm0(target_vm))
|
||||
return -1;
|
||||
|
||||
reset_vm(target_vm);
|
||||
return 0;
|
||||
}
|
||||
|
||||
int32_t hcall_assert_irqline(struct vm *vm, uint16_t vmid, uint64_t param)
|
||||
{
|
||||
int32_t ret = 0;
|
||||
|
Reference in New Issue
Block a user