aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSuresh Siddha <suresh.b.siddha@intel.com>2008-08-13 14:38:15 -0400
committerIngo Molnar <mingo@elte.hu>2008-08-14 04:56:07 -0400
commitf65bc214e042916135256620f900e9599d65e0cb (patch)
tree4f99f47e5036047e9069f9b7b74be9853e4b021a
parented405958057ca6a8c4c9178a7a3b1167fabb45f5 (diff)
x86, xsave: use BUG_ON() instead of BUILD_BUG_ON()
All these structure sizes are runtime determined. So use a runtime bug check. Signed-off-by: Suresh Siddha <suresh.b.siddha@intel.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
-rw-r--r--arch/x86/kernel/xsave.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/x86/kernel/xsave.c b/arch/x86/kernel/xsave.c
index bb097b1644d8..07713d64debe 100644
--- a/arch/x86/kernel/xsave.c
+++ b/arch/x86/kernel/xsave.c
@@ -82,8 +82,7 @@ int save_i387_xstate(void __user *buf)
82 if (!access_ok(VERIFY_WRITE, buf, sig_xstate_size)) 82 if (!access_ok(VERIFY_WRITE, buf, sig_xstate_size))
83 return -EACCES; 83 return -EACCES;
84 84
85 BUILD_BUG_ON(sizeof(struct user_i387_struct) != 85 BUG_ON(sig_xstate_size < xstate_size);
86 sizeof(tsk->thread.xstate->fxsave));
87 86
88 if ((unsigned long)buf % 64) 87 if ((unsigned long)buf % 64)
89 printk("save_i387_xstate: bad fpstate %p\n", buf); 88 printk("save_i387_xstate: bad fpstate %p\n", buf);