From 00bfde3cde4ded225ab27836eb647ead16017846 Mon Sep 17 00:00:00 2001 From: Victor Sun Date: Tue, 31 Jul 2018 13:25:51 +0800 Subject: [PATCH] HV: rename resume_vm to start_vm in hypercall api Currently we don't support resume VM in HC API, the real meaning of the code is to start VM. Signed-off-by: Victor Sun Acked-by: Eddie Dong --- hypervisor/arch/x86/guest/vmcall.c | 2 +- hypervisor/common/hypercall.c | 2 +- hypervisor/include/common/hypercall.h | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/hypervisor/arch/x86/guest/vmcall.c b/hypervisor/arch/x86/guest/vmcall.c index d3deba1af..29594b7c2 100644 --- a/hypervisor/arch/x86/guest/vmcall.c +++ b/hypervisor/arch/x86/guest/vmcall.c @@ -62,7 +62,7 @@ int vmcall_vmexit_handler(struct vcpu *vcpu) case HC_START_VM: /* param1: vmid */ - ret = hcall_resume_vm((uint16_t)param1); + ret = hcall_start_vm((uint16_t)param1); break; case HC_PAUSE_VM: diff --git a/hypervisor/common/hypercall.c b/hypervisor/common/hypercall.c index 6297a2ee1..33d6791e9 100644 --- a/hypervisor/common/hypercall.c +++ b/hypervisor/common/hypercall.c @@ -209,7 +209,7 @@ int32_t hcall_destroy_vm(uint16_t vmid) return ret; } -int32_t hcall_resume_vm(uint16_t vmid) +int32_t hcall_start_vm(uint16_t vmid) { int32_t ret = 0; struct vm *target_vm = get_vm_from_vmid(vmid); diff --git a/hypervisor/include/common/hypercall.h b/hypervisor/include/common/hypercall.h index f7b5ed83d..8a017ae87 100644 --- a/hypervisor/include/common/hypercall.h +++ b/hypervisor/include/common/hypercall.h @@ -77,9 +77,9 @@ int32_t hcall_create_vm(struct vm *vm, uint64_t param); int32_t hcall_destroy_vm(uint16_t vmid); /** - * @brief resume virtual machine + * @brief start virtual machine * - * Resume a virtual machine, it will schedule target VM's vcpu to run. + * Start a virtual machine, it will schedule target VM's vcpu to run. * The function will return -1 if the target VM does not exist or the * IOReq buffer page for the VM is not ready. * @@ -87,7 +87,7 @@ int32_t hcall_destroy_vm(uint16_t vmid); * * @return 0 on success, non-zero on error. */ -int32_t hcall_resume_vm(uint16_t vmid); +int32_t hcall_start_vm(uint16_t vmid); /** * @brief pause virtual machine