mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-10 05:09:01 +00:00
hv: add hypercall to set vcpu init state
DM will use this hypercall to initialize the UOS BSP state. Tracked-On: #1231 Signed-off-by: Yin Fengwei <fengwei.yin@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -310,6 +310,22 @@ struct acrn_vcpu_regs {
|
||||
uint16_t reserved_16[4];
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Info to set vcpu state
|
||||
*
|
||||
* the pamameter for HC_SET_VCPU_STATE
|
||||
*/
|
||||
struct acrn_set_vcpu_regs {
|
||||
/** the virtual CPU ID for the VCPU to set state */
|
||||
uint16_t vcpu_id;
|
||||
|
||||
/** reserved space to make cpu_state aligned to 8 bytes */
|
||||
uint16_t reserved0[3];
|
||||
|
||||
/** the structure to hold vcpu state */
|
||||
struct acrn_vcpu_regs vcpu_regs;
|
||||
} __attribute__((aligned(8)));
|
||||
|
||||
/**
|
||||
* @brief Info to set ioreq buffer for a created VM
|
||||
*
|
||||
|
@@ -37,6 +37,7 @@
|
||||
#define HC_PAUSE_VM BASE_HC_ID(HC_ID, HC_ID_VM_BASE + 0x03UL)
|
||||
#define HC_CREATE_VCPU BASE_HC_ID(HC_ID, HC_ID_VM_BASE + 0x04UL)
|
||||
#define HC_RESET_VM BASE_HC_ID(HC_ID, HC_ID_VM_BASE + 0x05UL)
|
||||
#define HC_SET_VCPU_REGS BASE_HC_ID(HC_ID, HC_ID_VM_BASE + 0x06UL)
|
||||
|
||||
/* IRQ and Interrupts */
|
||||
#define HC_ID_IRQ_BASE 0x20UL
|
||||
|
Reference in New Issue
Block a user