summaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/kvm.h
diff options
context:
space:
mode:
authorJan Kiszka2009-12-06 18:24:15 +0100
committerMarcelo Tosatti2009-12-27 16:36:33 +0100
commitdab4b911a5327859bb8f969249c6978c26cd4853 (patch)
treea21d0ef04e3bf831b2f9e674b6266535267cc9ce /arch/x86/include/asm/kvm.h
parentKVM: LAPIC: make sure IRR bitmap is scanned after vm load (diff)
downloadkernel-qcow2-linux-dab4b911a5327859bb8f969249c6978c26cd4853.tar.gz
kernel-qcow2-linux-dab4b911a5327859bb8f969249c6978c26cd4853.tar.xz
kernel-qcow2-linux-dab4b911a5327859bb8f969249c6978c26cd4853.zip
KVM: x86: Extend KVM_SET_VCPU_EVENTS with selective updates
User space may not want to overwrite asynchronously changing VCPU event states on write-back. So allow to skip nmi.pending and sipi_vector by setting corresponding bits in the flags field of kvm_vcpu_events. [avi: advertise the bits in KVM_GET_VCPU_EVENTS] Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/x86/include/asm/kvm.h')
-rw-r--r--arch/x86/include/asm/kvm.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/x86/include/asm/kvm.h b/arch/x86/include/asm/kvm.h
index 950df434763f..f46b79f6c16c 100644
--- a/arch/x86/include/asm/kvm.h
+++ b/arch/x86/include/asm/kvm.h
@@ -254,6 +254,10 @@ struct kvm_reinject_control {
__u8 reserved[31];
};
+/* When set in flags, include corresponding fields on KVM_SET_VCPU_EVENTS */
+#define KVM_VCPUEVENT_VALID_NMI_PENDING 0x00000001
+#define KVM_VCPUEVENT_VALID_SIPI_VECTOR 0x00000002
+
/* for KVM_GET/SET_VCPU_EVENTS */
struct kvm_vcpu_events {
struct {