HV: io: obsolete the valid field in vhm requests

As SOS has already adapted to the new state transition of VHM requests for a
month, the old `valid` field can now be safely obsoleted.

This patch changes the `valid` field as reserved and drops all the code that
reads or modifies this field for backward compatibility. The embedded comments
are updated accordingly, following the doxygen style.

Tracked-On: #875
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-11-29 00:06:14 +08:00
committed by Xie, Nanlin
parent db3c5746f3
commit 10afa9bbbf
3 changed files with 16 additions and 21 deletions

View File

@@ -10,7 +10,6 @@
static void complete_ioreq(struct vhm_request *vhm_req)
{
vhm_req->valid = 0;
atomic_store32(&vhm_req->processed, REQ_STATE_FREE);
}
@@ -140,8 +139,7 @@ void emulate_io_post(struct acrn_vcpu *vcpu)
req_buf = (union vhm_request_buffer *)vcpu->vm->sw.io_shared_page;
vhm_req = &req_buf->req_queue[vcpu->vcpu_id];
if ((vhm_req->valid == 0) ||
(atomic_load32(&vhm_req->processed) != REQ_STATE_COMPLETE)) {
if (atomic_load32(&vhm_req->processed) != REQ_STATE_COMPLETE) {
return;
}