ia64/xen-unstable

view xen/include/asm-x86/i387.h @ 19848:5839491bbf20

[IA64] replace MAX_VCPUS with d->max_vcpus where necessary.

don't use MAX_VCPUS, and use vcpu::max_vcpus.
The changeset of 2f9e1348aa98 introduced max_vcpus to allow more vcpus
per guest. This patch is ia64 counter part.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
author Isaku Yamahata <yamahata@valinux.co.jp>
date Mon Jun 29 11:26:05 2009 +0900 (2009-06-29)
parents b7ae31726aa6
children
line source
1 /*
2 * include/asm-i386/i387.h
3 *
4 * Copyright (C) 1994 Linus Torvalds
5 *
6 * Pentium III FXSR, SSE support
7 * General FPU state handling cleanups
8 * Gareth Hughes <gareth@valinux.com>, May 2000
9 */
11 #ifndef __ASM_I386_I387_H
12 #define __ASM_I386_I387_H
14 #include <xen/sched.h>
15 #include <asm/processor.h>
17 extern void init_fpu(void);
18 extern void save_init_fpu(struct vcpu *v);
19 extern void restore_fpu(struct vcpu *v);
21 #define unlazy_fpu(v) do { \
22 if ( (v)->fpu_dirtied ) \
23 save_init_fpu(v); \
24 } while ( 0 )
26 #define load_mxcsr(val) do { \
27 unsigned long __mxcsr = ((unsigned long)(val) & 0xffbf); \
28 __asm__ __volatile__ ( "ldmxcsr %0" : : "m" (__mxcsr) ); \
29 } while ( 0 )
31 static inline void setup_fpu(struct vcpu *v)
32 {
33 /* Avoid recursion. */
34 clts();
36 if ( !v->fpu_dirtied )
37 {
38 v->fpu_dirtied = 1;
39 if ( v->fpu_initialised )
40 restore_fpu(v);
41 else
42 init_fpu();
43 }
44 }
46 #endif /* __ASM_I386_I387_H */