summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristoffer Dall2014-08-26 14:00:38 +0200
committerPaolo Bonzini2014-08-29 13:47:05 +0200
commit44b5ce73c99c389817be71b9161bceb197d40ecb (patch)
tree3d56a9ee276f6b2fc1fd3e2dd5e93e7fbf824078
parentKVM: Unconditionally export KVM_CAP_READONLY_MEM (diff)
downloadkernel-qcow2-linux-44b5ce73c99c389817be71b9161bceb197d40ecb.tar.gz
kernel-qcow2-linux-44b5ce73c99c389817be71b9161bceb197d40ecb.tar.xz
kernel-qcow2-linux-44b5ce73c99c389817be71b9161bceb197d40ecb.zip
KVM: Unconditionally export KVM_CAP_USER_NMI
The idea between capabilities and the KVM_CHECK_EXTENSION ioctl is that userspace can, at run-time, determine if a feature is supported or not. This allows KVM to being supporting a new feature with a new kernel version without any need to update user space. Unfortunately, since the definition of KVM_CAP_USER_NMI was guarded by #ifdef __KVM_HAVE_USER_NMI, such discovery still required a user space update. Therefore, unconditionally export KVM_CAP_USER_NMI and change the the typo in the comment for the IOCTL number definition as well. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r--include/uapi/linux/kvm.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/include/uapi/linux/kvm.h b/include/uapi/linux/kvm.h
index 90d3edab839c..0695a1e3e332 100644
--- a/include/uapi/linux/kvm.h
+++ b/include/uapi/linux/kvm.h
@@ -654,9 +654,7 @@ struct kvm_ppc_smmu_info {
#endif
/* Bug in KVM_SET_USER_MEMORY_REGION fixed: */
#define KVM_CAP_DESTROY_MEMORY_REGION_WORKS 21
-#ifdef __KVM_HAVE_USER_NMI
#define KVM_CAP_USER_NMI 22
-#endif
#ifdef __KVM_HAVE_GUEST_DEBUG
#define KVM_CAP_SET_GUEST_DEBUG 23
#endif
@@ -1091,7 +1089,7 @@ struct kvm_s390_ucas_mapping {
#define KVM_S390_INITIAL_RESET _IO(KVMIO, 0x97)
#define KVM_GET_MP_STATE _IOR(KVMIO, 0x98, struct kvm_mp_state)
#define KVM_SET_MP_STATE _IOW(KVMIO, 0x99, struct kvm_mp_state)
-/* Available with KVM_CAP_NMI */
+/* Available with KVM_CAP_USER_NMI */
#define KVM_NMI _IO(KVMIO, 0x9a)
/* Available with KVM_CAP_SET_GUEST_DEBUG */
#define KVM_SET_GUEST_DEBUG _IOW(KVMIO, 0x9b, struct kvm_guest_debug)