aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/kvm_host.h
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/include/asm/kvm_host.h')
-rw-r--r--arch/x86/include/asm/kvm_host.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h
index 9fb6d8da7a43..56c5dca9d78d 100644
--- a/arch/x86/include/asm/kvm_host.h
+++ b/arch/x86/include/asm/kvm_host.h
@@ -620,6 +620,12 @@ struct kvm_vcpu_stat {
620 620
621struct x86_instruction_info; 621struct x86_instruction_info;
622 622
623struct msr_data {
624 bool host_initiated;
625 u32 index;
626 u64 data;
627};
628
623struct kvm_x86_ops { 629struct kvm_x86_ops {
624 int (*cpu_has_kvm_support)(void); /* __init */ 630 int (*cpu_has_kvm_support)(void); /* __init */
625 int (*disabled_by_bios)(void); /* __init */ 631 int (*disabled_by_bios)(void); /* __init */
@@ -642,7 +648,7 @@ struct kvm_x86_ops {
642 648
643 void (*update_db_bp_intercept)(struct kvm_vcpu *vcpu); 649 void (*update_db_bp_intercept)(struct kvm_vcpu *vcpu);
644 int (*get_msr)(struct kvm_vcpu *vcpu, u32 msr_index, u64 *pdata); 650 int (*get_msr)(struct kvm_vcpu *vcpu, u32 msr_index, u64 *pdata);
645 int (*set_msr)(struct kvm_vcpu *vcpu, u32 msr_index, u64 data); 651 int (*set_msr)(struct kvm_vcpu *vcpu, struct msr_data *msr);
646 u64 (*get_segment_base)(struct kvm_vcpu *vcpu, int seg); 652 u64 (*get_segment_base)(struct kvm_vcpu *vcpu, int seg);
647 void (*get_segment)(struct kvm_vcpu *vcpu, 653 void (*get_segment)(struct kvm_vcpu *vcpu,
648 struct kvm_segment *var, int seg); 654 struct kvm_segment *var, int seg);
@@ -793,7 +799,7 @@ static inline int emulate_instruction(struct kvm_vcpu *vcpu,
793 799
794void kvm_enable_efer_bits(u64); 800void kvm_enable_efer_bits(u64);
795int kvm_get_msr(struct kvm_vcpu *vcpu, u32 msr_index, u64 *data); 801int kvm_get_msr(struct kvm_vcpu *vcpu, u32 msr_index, u64 *data);
796int kvm_set_msr(struct kvm_vcpu *vcpu, u32 msr_index, u64 data); 802int kvm_set_msr(struct kvm_vcpu *vcpu, struct msr_data *msr);
797 803
798struct x86_emulate_ctxt; 804struct x86_emulate_ctxt;
799 805
@@ -820,7 +826,7 @@ void kvm_get_cs_db_l_bits(struct kvm_vcpu *vcpu, int *db, int *l);
820int kvm_set_xcr(struct kvm_vcpu *vcpu, u32 index, u64 xcr); 826int kvm_set_xcr(struct kvm_vcpu *vcpu, u32 index, u64 xcr);
821 827
822int kvm_get_msr_common(struct kvm_vcpu *vcpu, u32 msr, u64 *pdata); 828int kvm_get_msr_common(struct kvm_vcpu *vcpu, u32 msr, u64 *pdata);
823int kvm_set_msr_common(struct kvm_vcpu *vcpu, u32 msr, u64 data); 829int kvm_set_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr);
824 830
825unsigned long kvm_get_rflags(struct kvm_vcpu *vcpu); 831unsigned long kvm_get_rflags(struct kvm_vcpu *vcpu);
826void kvm_set_rflags(struct kvm_vcpu *vcpu, unsigned long rflags); 832void kvm_set_rflags(struct kvm_vcpu *vcpu, unsigned long rflags);