diff options
Diffstat (limited to 'drivers/kvm/kvm.h')
-rw-r--r-- | drivers/kvm/kvm.h | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/drivers/kvm/kvm.h b/drivers/kvm/kvm.h index b362e8f8f832..7a34706f42be 100644 --- a/drivers/kvm/kvm.h +++ b/drivers/kvm/kvm.h | |||
@@ -45,10 +45,6 @@ | |||
45 | #define KVM_REFILL_PAGES 25 | 45 | #define KVM_REFILL_PAGES 25 |
46 | #define KVM_MAX_CPUID_ENTRIES 40 | 46 | #define KVM_MAX_CPUID_ENTRIES 40 |
47 | 47 | ||
48 | #define FX_IMAGE_SIZE 512 | ||
49 | #define FX_IMAGE_ALIGN 16 | ||
50 | #define FX_BUF_SIZE (2 * FX_IMAGE_SIZE + FX_IMAGE_ALIGN) | ||
51 | |||
52 | #define DE_VECTOR 0 | 48 | #define DE_VECTOR 0 |
53 | #define NM_VECTOR 7 | 49 | #define NM_VECTOR 7 |
54 | #define DF_VECTOR 8 | 50 | #define DF_VECTOR 8 |
@@ -342,9 +338,8 @@ struct kvm_vcpu { | |||
342 | 338 | ||
343 | struct kvm_guest_debug guest_debug; | 339 | struct kvm_guest_debug guest_debug; |
344 | 340 | ||
345 | char fx_buf[FX_BUF_SIZE]; | 341 | struct i387_fxsave_struct host_fx_image; |
346 | char *host_fx_image; | 342 | struct i387_fxsave_struct guest_fx_image; |
347 | char *guest_fx_image; | ||
348 | int fpu_active; | 343 | int fpu_active; |
349 | int guest_fpu_loaded; | 344 | int guest_fpu_loaded; |
350 | 345 | ||
@@ -704,12 +699,12 @@ static inline unsigned long read_msr(unsigned long msr) | |||
704 | } | 699 | } |
705 | #endif | 700 | #endif |
706 | 701 | ||
707 | static inline void fx_save(void *image) | 702 | static inline void fx_save(struct i387_fxsave_struct *image) |
708 | { | 703 | { |
709 | asm ("fxsave (%0)":: "r" (image)); | 704 | asm ("fxsave (%0)":: "r" (image)); |
710 | } | 705 | } |
711 | 706 | ||
712 | static inline void fx_restore(void *image) | 707 | static inline void fx_restore(struct i387_fxsave_struct *image) |
713 | { | 708 | { |
714 | asm ("fxrstor (%0)":: "r" (image)); | 709 | asm ("fxrstor (%0)":: "r" (image)); |
715 | } | 710 | } |