aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-x86/kvm.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-x86/kvm.h')
-rw-r--r--include/asm-x86/kvm.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/include/asm-x86/kvm.h b/include/asm-x86/kvm.h
index 644a325077f0..32c7dda61474 100644
--- a/include/asm-x86/kvm.h
+++ b/include/asm-x86/kvm.h
@@ -9,6 +9,9 @@
9#include <asm/types.h> 9#include <asm/types.h>
10#include <linux/ioctl.h> 10#include <linux/ioctl.h>
11 11
12/* Architectural interrupt line count. */
13#define KVM_NR_INTERRUPTS 256
14
12struct kvm_memory_alias { 15struct kvm_memory_alias {
13 __u32 slot; /* this has a different namespace than memory slots */ 16 __u32 slot; /* this has a different namespace than memory slots */
14 __u32 flags; 17 __u32 flags;
@@ -99,4 +102,37 @@ struct kvm_dtable {
99}; 102};
100 103
101 104
105/* for KVM_GET_SREGS and KVM_SET_SREGS */
106struct kvm_sregs {
107 /* out (KVM_GET_SREGS) / in (KVM_SET_SREGS) */
108 struct kvm_segment cs, ds, es, fs, gs, ss;
109 struct kvm_segment tr, ldt;
110 struct kvm_dtable gdt, idt;
111 __u64 cr0, cr2, cr3, cr4, cr8;
112 __u64 efer;
113 __u64 apic_base;
114 __u64 interrupt_bitmap[(KVM_NR_INTERRUPTS + 63) / 64];
115};
116
117struct kvm_msr_entry {
118 __u32 index;
119 __u32 reserved;
120 __u64 data;
121};
122
123/* for KVM_GET_MSRS and KVM_SET_MSRS */
124struct kvm_msrs {
125 __u32 nmsrs; /* number of msrs in entries */
126 __u32 pad;
127
128 struct kvm_msr_entry entries[0];
129};
130
131/* for KVM_GET_MSR_INDEX_LIST */
132struct kvm_msr_list {
133 __u32 nmsrs; /* number of msrs in entries */
134 __u32 indices[0];
135};
136
137
102#endif 138#endif