mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-12 12:30:08 +00:00
hv:Replace vuart pointer with instance in structure vm
-- update 'vuart' field in 'struct vm' from pointer to instance -- replace MACRO with inline function for vm_vuart, and move it to vm.h -- change vuart_init to void type -- rename struct vuart -->struct acrn_vuart Signed-off-by: Mingqiang Chi <mingqiang.chi@intel.com> Reviewed-by: Anthony Xu <anthony.xu@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -46,8 +46,7 @@ is_entry_active(struct ptdev_remapping_info *entry)
|
||||
static bool ptdev_hv_owned_intx(struct vm *vm, union source_id *virt_sid)
|
||||
{
|
||||
/* vm0 pin 4 (uart) is owned by hypervisor under debug version */
|
||||
if (is_vm0(vm) && (vm->vuart != NULL) &&
|
||||
(virt_sid->intx_id.pin == 4U)) {
|
||||
if (is_vm0(vm) && (virt_sid->intx_id.pin == 4U)) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
|
@@ -199,14 +199,14 @@ int create_vm(struct vm_description *vm_desc, struct vm **rtn_vm)
|
||||
}
|
||||
|
||||
/* Create virtual uart */
|
||||
vm->vuart = vuart_init(vm);
|
||||
vuart_init(vm);
|
||||
}
|
||||
vpic_init(vm);
|
||||
|
||||
#ifdef CONFIG_PARTITION_MODE
|
||||
/* Create virtual uart */
|
||||
if (vm_desc->vm_vuart) {
|
||||
vm->vuart = vuart_init(vm);
|
||||
vuart_init(vm);
|
||||
}
|
||||
vrtc_init(vm);
|
||||
vpci_init(vm);
|
||||
|
Reference in New Issue
Block a user