acrn-hypervisor/hypervisor/arch/x86
Binbin Wu 2fd6e119ca hv: vmcall: hv should not change guest RAX vmcall is undefined
HV passes the return value of vmcall by register RAX unconditionally.
However, if the vmcall is undefined for a guest, RAX value of guest vcpu
should not be changed.

According to SDM Vol. 3C 30-9, VMCALL is allowed from any CPL in guest.
VMCALL is NOT allowed from  CPL > 0 in vmx root mode.
ACRN hypervisor doesn't call VMCALL in vmx root mode, though.

In current code, ACRN also deny VMCALL from CPL > 0 in guest.
So for this case, #GP will not be injected, instead, modify the RAX to
notify the return value.

Tracked-On: #2405
Signed-off-by: Binbin Wu <binbin.wu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2019-02-18 11:56:42 +08:00
..
boot function name change in init.c 2018-12-19 09:07:14 +08:00
configs HV: repace vpci_vdev_array with pci_ptdev config 2019-02-03 08:18:54 +08:00
guest hv: vmcall: hv should not change guest RAX vmcall is undefined 2019-02-18 11:56:42 +08:00
cpu_caps.c hv:Change structure boot_cpu_data to static 2019-01-07 11:23:22 +08:00
cpu_state_tbl.c hv:Change structure boot_cpu_data to static 2019-01-07 11:23:22 +08:00
cpu.c HV: scan all physical PCI devices and store all needed info in array 2019-02-02 15:24:43 +08:00
e820.c hv:remove several redundancy variables related memory 2019-02-02 22:59:34 +08:00
gdt.c fix "Procedure is not pure assembler" 2018-11-13 16:28:58 +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: Modularize vtd.c to remove acrn_vm usage 2019-02-06 08:53:46 +08:00
ioapic.c hv: Use Interrupt Remapping format for programming interrupt sources 2019-02-01 15:54:55 +08:00
irq.c HV: modularization improve UEFI macro control code 2019-01-30 16:11:39 +08:00
Kconfig hv: Add support to add IR tables 2019-02-01 15:54:55 +08:00
lapic.c hv: send IPI instead of irq injection to notify vcpu with lapic pt 2019-01-28 19:47:33 +08:00
mmu.c hv:Move severl variable declaration for boot code 2019-01-25 21:32:21 +08:00
notify.c HV: rename the term of vm0 to sos vm 2019-01-21 18:03:31 +08:00
page.c HV: rename the term of vm0 to sos vm 2019-01-21 18:03:31 +08:00
pagetable.c hv: replace improper use of panic with ASSERT 2019-01-31 11:09:39 +08:00
pm.c HV: Modularize vtd.c to remove acrn_vm usage 2019-02-06 08:53: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: coding style: refine cpu related function to one exit 2018-12-21 13:34:01 +08:00
static_checks.c hv: use int32_t replace int 2018-12-12 13:08:10 +08:00
timer.c hv:fix violations 2019-01-11 16:52:28 +08:00
trampoline.c HV: modularization improve UEFI macro control code 2019-01-30 16:11:39 +08:00
vmx.c HV: modularization improve UEFI macro control code 2019-01-30 16:11:39 +08:00
vtd.c HV: Remove snoopy_mem from iommu 2019-02-14 10:16:21 +08:00
wakeup.S HV: modularization to refine pm related code. 2018-12-19 13:02:09 +08:00