mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-24 02:08:04 +00:00
HV: io: refine state transitions of VHM requests
Instead of using two members for maintaining the state of a VHM request, this patch replaces the transitions with a single state. Basically the lifecycle of a VHM request shall be: FREE -> PENDING -> PROCESSING -> COMPLETE -> FREE -> ... The structure header of vhm_request has more details of the transitions access limitations under different states. Also drop the set but unused member vcpu.ioreq_pending. For backward-compatibility, the obsolete 'valid' member is still kept and maintained before SOS and DM adapts to the new state transitions. v2 -> v3: * Use complete_ioreq to mark an I/O request finished in dm_emulate_(pio|mmio)_post. Signed-off-by: Junjie Mao <junjie.mao@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -248,7 +248,6 @@ struct vcpu {
|
||||
bool launched; /* Whether the vcpu is launched on target pcpu */
|
||||
uint32_t paused_cnt; /* how many times vcpu is paused */
|
||||
uint32_t running; /* vcpu is picked up and run? */
|
||||
uint32_t ioreq_pending; /* ioreq is ongoing or not? */
|
||||
|
||||
struct io_request req; /* used by io/ept emulation */
|
||||
|
||||
|
Reference in New Issue
Block a user