acrn-hypervisor/hypervisor/arch/x86
Conghui Chen ac6c5dce81 HV: Clean vpic and vioapic logic when lapic is pt
When the lapic is passthru, vpic and vioapic cannot be used anymore. In
current code, user can still inject vpic interrupt to Guest OS, this is
not allowed.
This patch remove the vpic and vioapic initiate functions during
creating VM with lapic passthru. But the APIs in vpic and vioapic are
called in many places, for these APIs, follow the below principles:

1. For the APIs which will access uninitiated variables, and may case
hypervisor hang, add @pre to make sure user should call them after vpic or
vioapic is initiated.

2. For the APIs which only return some static value, do noting with them.

3. For the APIs which user will called to inject interrupt, such as
vioapic_set_irqline_lock or vpic_set_irqline, add condition in these
APIs to make sure it only inject interrupt when vpic or vioapic is
initiated. This change is to make sure the vuart or hypercall need not
to care whether lapic is passthru or the vpic and vioapic is initiated
or not.

Tracked-On: #3227
Signed-off-by: Conghui Chen <conghui.chen@intel.com>
2019-06-12 14:29:50 +08:00
..
boot hv:remove some unnecessary includes 2019-05-07 09:10:13 +08:00
configs ACRN/HV: Add one new board configuration for ACRN-hypervisor 2019-06-10 11:23:18 +08:00
guest HV: Clean vpic and vioapic logic when lapic is pt 2019-06-12 14:29:50 +08:00
lib hv:move several files related X86 for lib 2019-05-13 10:12:20 +08:00
seed hv: delay enabling SMEP/SMAP until the end of PCPU initialization 2019-06-10 11:35:15 +08:00
cat.c hv:remove some unnecessary includes 2019-05-07 09:10:13 +08:00
cpu_caps.c HV: remove vcpu arch lock, not needed. 2019-05-22 16:35:26 +08:00
cpu_state_tbl.c HV: enforce Cx of apl nuc with SPACE_SYSTEM_IO 2019-05-24 11:36:54 +08:00
cpu.c hv: delay enabling SMEP/SMAP until the end of PCPU initialization 2019-06-10 11:35:15 +08:00
e820.c hv: cleanup some hva/hpa conversion code 2019-03-15 09:03:14 +08:00
gdt.c hv:cleanup header files for arch folder 2019-02-22 13:14:36 +08:00
idt.S move idt.S and idt.h out of boot component 2018-12-12 09:07:43 +08:00
init.c hv: delay enabling SMEP/SMAP until the end of PCPU initialization 2019-06-10 11:35:15 +08:00
ioapic.c hv:cleanup header files for arch folder 2019-02-22 13:14:36 +08:00
irq.c rename function & definition from firmware to guest boot 2019-05-09 16:33:44 +08:00
Kconfig HV: add hybrid scenario 2019-06-06 15:22:10 +08:00
lapic.c HV: Add prefix 'p' before 'cpu' to physical cpu related functions 2019-04-24 10:50:28 +08:00
mmu.c hv: delay enabling SMEP/SMAP until the end of PCPU initialization 2019-06-10 11:35:15 +08:00
notify.c HV: Add prefix 'p' before 'cpu' to physical cpu related functions 2019-04-24 10:50:28 +08:00
page.c hv:cleanup header files for arch folder 2019-02-22 13:14:36 +08:00
pagetable.c hv:cleanup header files for arch folder 2019-02-22 13:14:36 +08:00
pm.c HV: remove some redundant includes 2019-05-08 16:57:46 +08:00
retpoline-thunk.S license: Replace license text with SPDX tag 2018-06-01 10:43:06 +08:00
sched.S replace arch_switch_to with pure asm code instead of inline asm 2019-01-25 11:39:47 +08:00
security.c HV: remove vcpu arch lock, not needed. 2019-05-22 16:35:26 +08:00
sgx.c hv: sgx: add basic support to init sgx resource for vm 2019-05-29 11:24:13 +08:00
timer.c HV: Add prefix 'p' before 'cpu' to physical cpu related functions 2019-04-24 10:50:28 +08:00
trampoline.c hv: delay enabling SMEP/SMAP until the end of PCPU initialization 2019-06-10 11:35:15 +08:00
vmx.c hv:move instr_emul_ctxt instance to struct vcpu 2019-03-13 14:04:20 +08:00
vtd.c hv: fix possible null pointer dereference 2019-06-11 16:03:04 +08:00
wakeup.S hv:remove some unnecessary includes 2019-05-07 09:10:13 +08:00