summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDavid Woodhouse <dwmw@amazon.co.uk>2020-12-04 01:02:04 +0000
committerDavid Woodhouse <dwmw@amazon.co.uk>2021-02-04 14:19:39 +0000
commit8d4e7e80838f45d3466d36d4fcb890424825faa9 (patch)
treec1935c4972aa6529df3092060ca6a2f02faae903 /include
parent40da8ccd724f7ca2f08550a46268bc3a91cc8869 (diff)
KVM: x86: declare Xen HVM shared info capability and add test case
Instead of adding a plethora of new KVM_CAP_XEN_FOO capabilities, just add bits to the return value of KVM_CAP_XEN_HVM. Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
Diffstat (limited to 'include')
-rw-r--r--include/uapi/linux/kvm.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/uapi/linux/kvm.h b/include/uapi/linux/kvm.h
index 4d4cd001c908..63f8f6e95648 100644
--- a/include/uapi/linux/kvm.h
+++ b/include/uapi/linux/kvm.h
@@ -1152,6 +1152,7 @@ struct kvm_x86_mce {
#ifdef KVM_CAP_XEN_HVM
#define KVM_XEN_HVM_CONFIG_HYPERCALL_MSR (1 << 0)
#define KVM_XEN_HVM_CONFIG_INTERCEPT_HCALL (1 << 1)
+#define KVM_XEN_HVM_CONFIG_SHARED_INFO (1 << 2)
struct kvm_xen_hvm_config {
__u32 flags;
@@ -1604,6 +1605,7 @@ struct kvm_xen_hvm_attr {
} u;
};
+/* Available with KVM_CAP_XEN_HVM / KVM_XEN_HVM_CONFIG_SHARED_INFO */
#define KVM_XEN_ATTR_TYPE_LONG_MODE 0x0
#define KVM_XEN_ATTR_TYPE_SHARED_INFO 0x1
#define KVM_XEN_ATTR_TYPE_UPCALL_VECTOR 0x2
@@ -1621,6 +1623,7 @@ struct kvm_xen_vcpu_attr {
} u;
};
+/* Available with KVM_CAP_XEN_HVM / KVM_XEN_HVM_CONFIG_SHARED_INFO */
#define KVM_XEN_VCPU_ATTR_TYPE_VCPU_INFO 0x0
#define KVM_XEN_VCPU_ATTR_TYPE_VCPU_TIME_INFO 0x1