hypercall: Fix compile error caused by missing memcpy function

Assignment of structures are implemented using memcpy which is not
available in the hypervisor. This patch convert such assignment to an
explicit memcpy_s() call.

Signed-off-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
Junjie Mao 2018-04-03 16:40:23 +08:00 committed by Jack Ren
parent de4d793389
commit 4542d3775d

View File

@ -727,7 +727,8 @@ int acrn_insert_request_wait(struct vcpu *vcpu, struct vhm_request *req)
/* ACRN insert request to VHM and inject upcall */
cur = vcpu->vcpu_id;
req_buf->req_queue[cur] = *req;
memcpy_s(&req_buf->req_queue[cur], sizeof(struct vhm_request),
req, sizeof(struct vhm_request));
/* Must clear the signal before we mark req valid
* Once we mark to valid, VHM may process req and signal us