diff options
author | Gleb Natapov <gleb@redhat.com> | 2010-04-13 03:05:23 -0400 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2010-05-17 05:17:39 -0400 |
commit | 020df0794f5764e742feaa718be88b8f1b4ce04f (patch) | |
tree | ce0fca4af2beba046c8632e663bfc082681c6afa /arch/x86/include/asm/kvm_host.h | |
parent | 6bc31bdc55cad6609b1610b4cecad312664f2808 (diff) |
KVM: move DR register access handling into generic code
Currently both SVM and VMX have their own DR handling code. Move it to
x86.c.
Acked-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'arch/x86/include/asm/kvm_host.h')
-rw-r--r-- | arch/x86/include/asm/kvm_host.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h index 0c49c888be6b..5d5e0a9afcf2 100644 --- a/arch/x86/include/asm/kvm_host.h +++ b/arch/x86/include/asm/kvm_host.h | |||
@@ -496,8 +496,7 @@ struct kvm_x86_ops { | |||
496 | void (*set_idt)(struct kvm_vcpu *vcpu, struct desc_ptr *dt); | 496 | void (*set_idt)(struct kvm_vcpu *vcpu, struct desc_ptr *dt); |
497 | void (*get_gdt)(struct kvm_vcpu *vcpu, struct desc_ptr *dt); | 497 | void (*get_gdt)(struct kvm_vcpu *vcpu, struct desc_ptr *dt); |
498 | void (*set_gdt)(struct kvm_vcpu *vcpu, struct desc_ptr *dt); | 498 | void (*set_gdt)(struct kvm_vcpu *vcpu, struct desc_ptr *dt); |
499 | int (*get_dr)(struct kvm_vcpu *vcpu, int dr, unsigned long *dest); | 499 | void (*set_dr7)(struct kvm_vcpu *vcpu, unsigned long value); |
500 | int (*set_dr)(struct kvm_vcpu *vcpu, int dr, unsigned long value); | ||
501 | void (*cache_reg)(struct kvm_vcpu *vcpu, enum kvm_reg reg); | 500 | void (*cache_reg)(struct kvm_vcpu *vcpu, enum kvm_reg reg); |
502 | unsigned long (*get_rflags)(struct kvm_vcpu *vcpu); | 501 | unsigned long (*get_rflags)(struct kvm_vcpu *vcpu); |
503 | void (*set_rflags)(struct kvm_vcpu *vcpu, unsigned long rflags); | 502 | void (*set_rflags)(struct kvm_vcpu *vcpu, unsigned long rflags); |
@@ -602,6 +601,8 @@ void kvm_set_cr0(struct kvm_vcpu *vcpu, unsigned long cr0); | |||
602 | void kvm_set_cr3(struct kvm_vcpu *vcpu, unsigned long cr3); | 601 | void kvm_set_cr3(struct kvm_vcpu *vcpu, unsigned long cr3); |
603 | void kvm_set_cr4(struct kvm_vcpu *vcpu, unsigned long cr4); | 602 | void kvm_set_cr4(struct kvm_vcpu *vcpu, unsigned long cr4); |
604 | void kvm_set_cr8(struct kvm_vcpu *vcpu, unsigned long cr8); | 603 | void kvm_set_cr8(struct kvm_vcpu *vcpu, unsigned long cr8); |
604 | int kvm_set_dr(struct kvm_vcpu *vcpu, int dr, unsigned long val); | ||
605 | int kvm_get_dr(struct kvm_vcpu *vcpu, int dr, unsigned long *val); | ||
605 | unsigned long kvm_get_cr8(struct kvm_vcpu *vcpu); | 606 | unsigned long kvm_get_cr8(struct kvm_vcpu *vcpu); |
606 | void kvm_lmsw(struct kvm_vcpu *vcpu, unsigned long msw); | 607 | void kvm_lmsw(struct kvm_vcpu *vcpu, unsigned long msw); |
607 | void kvm_get_cs_db_l_bits(struct kvm_vcpu *vcpu, int *db, int *l); | 608 | void kvm_get_cs_db_l_bits(struct kvm_vcpu *vcpu, int *db, int *l); |