[PATCH v3 0/3] Enable notify VM exit

Chenyi Qiang posted 3 patches 2 years ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20220421074028.18196-1-chenyi.qiang@intel.com
Maintainers: "Michael S. Tsirkin" <mst@redhat.com>, Marcel Apfelbaum <marcel.apfelbaum@gmail.com>, Paolo Bonzini <pbonzini@redhat.com>, Richard Henderson <richard.henderson@linaro.org>, Eduardo Habkost <eduardo@habkost.net>, Cornelia Huck <cohuck@redhat.com>, Marcelo Tosatti <mtosatti@redhat.com>
There is a newer version of this series
hw/i386/x86.c               | 45 ++++++++++++++++++++++++
include/hw/i386/x86.h       |  5 +++
linux-headers/asm-x86/kvm.h |  4 ++-
linux-headers/linux/kvm.h   | 10 ++++++
target/i386/cpu.c           |  1 +
target/i386/cpu.h           |  1 +
target/i386/kvm/kvm.c       | 70 ++++++++++++++++++++++++++-----------
7 files changed, 114 insertions(+), 22 deletions(-)
[PATCH v3 0/3] Enable notify VM exit
Posted by Chenyi Qiang 2 years ago
Notify VM exit is introduced to mitigate the potential DOS attach from
malicious VM. This series is the userspace part to enable this feature
through a new KVM capability KVM_CAP_X86_NOTIFY_VMEXIT. The detailed
info can be seen in Patch 3.

The corresponding KVM patches are avaiable at:
https://lore.kernel.org/lkml/20220421072958.16375-1-chenyi.qiang@intel.com/

---
Change logs:
v2 -> v3
- Extend the argument to include both the notify window and some flags
  when enabling KVM_CAP_X86_BUS_LOCK_EXIT CAP.
- Change to use KVM_VCPUEVENTS_VALID_TRIPLE_FAULT in flags field and add
  pending_triple_fault field in struct kvm_vcpu_events.
- v2: https://lore.kernel.org/qemu-devel/20220318082934.25030-1-chenyi.qiang@intel.com/

v1 -> v2
- Add some commit message to explain why we disable Notify VM exit by default.
- Rename KVM_VCPUEVENT_SHUTDOWN to KVM_VCPUEVENT_TRIPLE_FAULT.
- Do the corresponding change to use the KVM_VCPUEVENTS_TRIPLE_FAULT
  to save/restore the triple fault event to avoid lose some synthesized
  triple fault from KVM.
- v1: https://lore.kernel.org/qemu-devel/20220310090205.10645-1-chenyi.qiang@intel.com/

---

Chenyi Qiang (3):
  linux-header: update linux header
  i386: kvm: Save&restore triple fault event
  i386: Add notify VM exit support

 hw/i386/x86.c               | 45 ++++++++++++++++++++++++
 include/hw/i386/x86.h       |  5 +++
 linux-headers/asm-x86/kvm.h |  4 ++-
 linux-headers/linux/kvm.h   | 10 ++++++
 target/i386/cpu.c           |  1 +
 target/i386/cpu.h           |  1 +
 target/i386/kvm/kvm.c       | 70 ++++++++++++++++++++++++++-----------
 7 files changed, 114 insertions(+), 22 deletions(-)

-- 
2.17.1