mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-06-21 13:08:42 +00:00
hv: enable MSI remapping on vm0
When enabled, hypervisor will handle MSI/MSI-X remapping for SOS. Tracked-On: #1568 Signed-off-by: dongshen <dongsheng.x.zhang@intel.com> Signed-off-by: Zide Chen <zide.chen@intel.com> Reviewed-by: Li, Fei1 <fei1.li@intel.com> Acked-by: Anthony Xu <anthony.xu@intel.com>
This commit is contained in:
parent
8c398f7d7e
commit
c1d2499e5c
@ -176,15 +176,19 @@ endif
|
|||||||
|
|
||||||
C_SRCS += dm/vpic.c
|
C_SRCS += dm/vpic.c
|
||||||
C_SRCS += dm/vioapic.c
|
C_SRCS += dm/vioapic.c
|
||||||
ifeq ($(CONFIG_PARTITION_MODE),y)
|
|
||||||
C_SRCS += $(wildcard partition/*.c)
|
|
||||||
C_SRCS += dm/hw/pci.c
|
C_SRCS += dm/hw/pci.c
|
||||||
C_SRCS += dm/vpci/core.c
|
C_SRCS += dm/vpci/core.c
|
||||||
C_SRCS += dm/vpci/vpci.c
|
C_SRCS += dm/vpci/vpci.c
|
||||||
|
ifeq ($(CONFIG_PARTITION_MODE),y)
|
||||||
|
C_SRCS += $(wildcard partition/*.c)
|
||||||
C_SRCS += dm/vpci/partition_mode.c
|
C_SRCS += dm/vpci/partition_mode.c
|
||||||
C_SRCS += dm/vpci/hostbridge.c
|
C_SRCS += dm/vpci/hostbridge.c
|
||||||
C_SRCS += dm/vpci/pci_pt.c
|
C_SRCS += dm/vpci/pci_pt.c
|
||||||
C_SRCS += dm/vrtc.c
|
C_SRCS += dm/vrtc.c
|
||||||
|
else
|
||||||
|
C_SRCS += dm/vpci/sharing_mode.c
|
||||||
|
C_SRCS += dm/vpci/msi.c
|
||||||
|
C_SRCS += dm/vpci/msix.c
|
||||||
endif
|
endif
|
||||||
|
|
||||||
C_SRCS += bsp/$(CONFIG_PLATFORM)/$(CONFIG_PLATFORM).c
|
C_SRCS += bsp/$(CONFIG_PLATFORM)/$(CONFIG_PLATFORM).c
|
||||||
|
@ -152,9 +152,10 @@ int create_vm(struct vm_description *vm_desc, struct vm **rtn_vm)
|
|||||||
vuart_init(vm);
|
vuart_init(vm);
|
||||||
}
|
}
|
||||||
vrtc_init(vm);
|
vrtc_init(vm);
|
||||||
vpci_init(vm);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
vpci_init(vm);
|
||||||
|
|
||||||
/* vpic wire_mode default is INTR */
|
/* vpic wire_mode default is INTR */
|
||||||
vm->wire_mode = VPIC_WIRE_INTR;
|
vm->wire_mode = VPIC_WIRE_INTR;
|
||||||
|
|
||||||
@ -231,10 +232,7 @@ int shutdown_vm(struct vm *vm)
|
|||||||
free_vm_id(vm);
|
free_vm_id(vm);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#ifdef CONFIG_PARTITION_MODE
|
|
||||||
vpci_cleanup(vm);
|
vpci_cleanup(vm);
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Return status to caller */
|
/* Return status to caller */
|
||||||
return status;
|
return status;
|
||||||
|
@ -7,10 +7,10 @@
|
|||||||
#ifndef VM_H_
|
#ifndef VM_H_
|
||||||
#define VM_H_
|
#define VM_H_
|
||||||
#include <bsp_extern.h>
|
#include <bsp_extern.h>
|
||||||
|
#include <vpci.h>
|
||||||
|
|
||||||
#ifdef CONFIG_PARTITION_MODE
|
#ifdef CONFIG_PARTITION_MODE
|
||||||
#include <mptable.h>
|
#include <mptable.h>
|
||||||
#include <vpci.h>
|
|
||||||
#endif
|
#endif
|
||||||
enum vm_privilege_level {
|
enum vm_privilege_level {
|
||||||
VM_PRIVILEGE_LEVEL_HIGH = 0,
|
VM_PRIVILEGE_LEVEL_HIGH = 0,
|
||||||
@ -155,9 +155,9 @@ struct vm {
|
|||||||
|
|
||||||
uint32_t vcpuid_entry_nr, vcpuid_level, vcpuid_xlevel;
|
uint32_t vcpuid_entry_nr, vcpuid_level, vcpuid_xlevel;
|
||||||
struct vcpuid_entry vcpuid_entries[MAX_VM_VCPUID_ENTRIES];
|
struct vcpuid_entry vcpuid_entries[MAX_VM_VCPUID_ENTRIES];
|
||||||
|
struct vpci vpci;
|
||||||
#ifdef CONFIG_PARTITION_MODE
|
#ifdef CONFIG_PARTITION_MODE
|
||||||
struct vm_description *vm_desc;
|
struct vm_description *vm_desc;
|
||||||
struct vpci vpci;
|
|
||||||
uint8_t vrtc_offset;
|
uint8_t vrtc_offset;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user