mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-22 17:27:53 +00:00
HV: add get_sos_vm api
This patch creates a new get_sos_vm() api to replace get_vm_from_vmid(0U) because VM 0 might not be SOS VM now; Tracked-On: #2291 Signed-off-by: Victor Sun <victor.sun@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -73,6 +73,12 @@ struct acrn_vm *get_vm_from_vmid(uint16_t vm_id)
|
||||
return &vm_array[vm_id];
|
||||
}
|
||||
|
||||
/* return a pointer to the virtual machine structure of SOS VM */
|
||||
struct acrn_vm *get_sos_vm(void)
|
||||
{
|
||||
return sos_vm_ptr;
|
||||
}
|
||||
|
||||
/**
|
||||
* @pre vm_config != NULL
|
||||
*/
|
||||
|
Reference in New Issue
Block a user