linux-kselftest.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] Handle MMIO during event delivery error on SVM
@ 2024-09-27 16:16 Ivan Orlov
  2024-09-27 16:16 ` [PATCH 1/3] KVM: x86, vmx: Add function for event delivery error generation Ivan Orlov
                   ` (2 more replies)
  0 siblings, 3 replies; 16+ messages in thread
From: Ivan Orlov @ 2024-09-27 16:16 UTC (permalink / raw)
  To: bp, dave.hansen, mingo, pbonzini, seanjc, shuah, tglx
  Cc: Ivan Orlov, hpa, kvm, linux-kernel, linux-kselftest, x86,
	jalliste, nh-open-source, pdurrant

Currently, the situation when guest accesses MMIO during event delivery
is handled differently in VMX and SVM: on VMX KVM returns internal error
with suberror = KVM_INTERNAL_ERROR_DELIVERY_EV, when SVM simply goes
into infinite loop trying to deliver an event again and again.

This patch series eliminates this difference by returning a KVM internal
error with suberror = KVM_INTERNAL_ERROR_DELIVERY_EV when guest is
performing MMIO during event delivery, for both VMX and SVM.

Also, it introduces a selftest test case which covers the MMIO during
event delivery error handling.

Ivan Orlov (3):
  KVM: x86, vmx: Add function for event delivery error generation
  KVM: vmx, svm, mmu: Process MMIO during event delivery
  selftests: KVM: Add test case for MMIO during event delivery

 arch/x86/include/asm/kvm_host.h               |  8 ++++
 arch/x86/kvm/mmu/mmu.c                        | 15 +++++-
 arch/x86/kvm/svm/svm.c                        |  4 ++
 arch/x86/kvm/vmx/vmx.c                        | 32 ++++---------
 arch/x86/kvm/x86.c                            | 22 +++++++++
 .../selftests/kvm/set_memory_region_test.c    | 46 +++++++++++++++++++
 6 files changed, 104 insertions(+), 23 deletions(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2024-10-17 16:58 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-27 16:16 [PATCH 0/3] Handle MMIO during event delivery error on SVM Ivan Orlov
2024-09-27 16:16 ` [PATCH 1/3] KVM: x86, vmx: Add function for event delivery error generation Ivan Orlov
2024-10-11 23:20   ` Sean Christopherson
2024-10-12  0:06     ` Sean Christopherson
2024-10-15 19:52     ` Ivan Orlov
2024-10-16 21:05       ` Sean Christopherson
2024-10-16 22:05         ` Ivan Orlov
2024-10-16 23:12           ` Sean Christopherson
2024-09-27 16:16 ` [PATCH 2/3] KVM: vmx, svm, mmu: Process MMIO during event delivery Ivan Orlov
2024-10-12  0:05   ` Sean Christopherson
2024-10-16 22:53     ` Ivan Orlov
2024-10-17 16:20       ` Sean Christopherson
2024-09-27 16:16 ` [PATCH 3/3] selftests: KVM: Add test case for " Ivan Orlov
2024-10-12  0:21   ` Sean Christopherson
2024-10-17 16:27     ` David Woodhouse
2024-10-17 16:58       ` Sean Christopherson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).