acrn-kernel/arch/x86/kvm
Xiao Guangrong 1c118b8226 KVM: MMU: avoid fast page fault fixing mmio page fault
Currently, fast page fault incorrectly tries to fix mmio page fault when
the generation number is invalid (spte.gen != kvm.gen).  It then returns
to guest to retry the fault since it sees the last spte is nonpresent.
This causes an infinite loop.

Since fast page fault only works for direct mmu, the issue exists when
1) tdp is enabled. It is only triggered only on AMD host since on Intel host
   the mmio page fault is recognized as ept-misconfig whose handler call
   fault-page path with error_code = 0

2) guest paging is disabled. Under this case, the issue is hardly discovered
   since paging disable is short-lived and the sptes will be invalid after
   memslot changed for 150 times

Fix it by filtering out MMIO page faults in page_fault_can_be_fast.

Reported-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Tested-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Signed-off-by: Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-18 12:26:57 +02:00
..
Kconfig kvm: Allow build-time configuration of KVM device assignment 2013-04-28 12:58:56 +03:00
Makefile KVM: get rid of $(addprefix ../../../virt/kvm/, ...) in Makefiles 2013-05-19 15:14:00 +03:00
cpuid.c
cpuid.h
emulate.c KVM fixes for 3.11 2013-07-03 13:21:40 -07:00
i8254.c
i8254.h
i8259.c
irq.c
irq.h
kvm_cache_regs.h
lapic.c KVM fixes for 3.11 2013-07-03 13:21:40 -07:00
lapic.h KVM: Fix RTC interrupt coalescing tracking 2013-06-27 14:20:53 +03:00
mmu.c KVM: MMU: avoid fast page fault fixing mmio page fault 2013-07-18 12:26:57 +02:00
mmu.h KVM: MMU: fast invalidate all mmio sptes 2013-06-27 14:20:36 +03:00
mmu_audit.c
mmutrace.h KVM: MMU: add tracepoint for check_mmio_spte 2013-06-27 14:20:37 +03:00
paging_tmpl.h KVM: MMU: fast invalidate all mmio sptes 2013-06-27 14:20:36 +03:00
pmu.c
svm.c kvm: Add a tracepoint write_tsc_offset 2013-06-27 14:20:51 +03:00
trace.h kvm: Add a tracepoint write_tsc_offset 2013-06-27 14:20:51 +03:00
tss.h
vmx.c KVM: VMX: mark unusable segment as nonpresent 2013-07-04 14:40:36 +02:00
x86.c KVM fixes for 3.11 2013-07-03 13:21:40 -07:00
x86.h