Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 212042
b: refs/heads/master
c: 8eb91a5
h: refs/heads/master
v: v3
  • Loading branch information
Brian Gerst authored and H. Peter Anvin committed Sep 9, 2010
1 parent b14de04 commit 3ce4c13
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a334fe43d85f570ae907acf988a053c5eff78d6e
refs/heads/master: 8eb91a577d7763d21628f6761045328784b1911c
12 changes: 6 additions & 6 deletions trunk/arch/x86/include/asm/i387.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,12 @@ extern int save_i387_xstate_ia32(void __user *buf);
extern int restore_i387_xstate_ia32(void __user *buf);
#endif

#ifdef CONFIG_MATH_EMULATION
extern void finit_soft_fpu(struct i387_soft_struct *soft);
#else
static inline void finit_soft_fpu(struct i387_soft_struct *soft) {}
#endif

#define X87_FSW_ES (1 << 7) /* Exception Summary */

static __always_inline __pure bool use_xsaveopt(void)
Expand Down Expand Up @@ -189,12 +195,6 @@ static inline void fpu_save_init(struct fpu *fpu)

#else /* CONFIG_X86_32 */

#ifdef CONFIG_MATH_EMULATION
extern void finit_soft_fpu(struct i387_soft_struct *soft);
#else
static inline void finit_soft_fpu(struct i387_soft_struct *soft) {}
#endif

/* perform fxrstor iff the processor has extended states, otherwise frstor */
static inline int fxrstor_checking(struct i387_fxsave_struct *fx)
{
Expand Down
4 changes: 0 additions & 4 deletions trunk/arch/x86/kernel/i387.c
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,8 @@ static void __cpuinit init_thread_xstate(void)

if (cpu_has_fxsr)
xstate_size = sizeof(struct i387_fxsave_struct);
#ifdef CONFIG_X86_32
else
xstate_size = sizeof(struct i387_fsave_struct);
#endif
}

/*
Expand Down Expand Up @@ -119,12 +117,10 @@ void __cpuinit fpu_init(void)

void fpu_finit(struct fpu *fpu)
{
#ifdef CONFIG_X86_32
if (!HAVE_HWFP) {
finit_soft_fpu(&fpu->state->soft);
return;
}
#endif

if (cpu_has_fxsr) {
struct i387_fxsave_struct *fx = &fpu->state->fxsave;
Expand Down

0 comments on commit 3ce4c13

Please sign in to comment.