]> bbs.cooldavid.org Git - net-next-2.6.git/blame - arch/x86/kernel/sigframe.h
x86, xsave: dynamically allocate sigframes fpstate instead of static allocation
[net-next-2.6.git] / arch / x86 / kernel / sigframe.h
CommitLineData
123a6347
HH
1#ifdef CONFIG_X86_32
2struct sigframe {
fc0b1af2 3 char __user *pretcode;
1da177e4
LT
4 int sig;
5 struct sigcontext sc;
3c1c7f10
SS
6 /*
7 * fpstate is unused. fpstate is moved/allocated after
8 * retcode[] below. This movement allows to have the FP state and the
9 * future state extensions (xsave) stay together.
10 * And at the same time retaining the unused fpstate, prevents changing
11 * the offset of extramask[] in the sigframe and thus prevent any
12 * legacy application accessing/modifying it.
13 */
14 struct _fpstate fpstate_unused;
1da177e4
LT
15 unsigned long extramask[_NSIG_WORDS-1];
16 char retcode[8];
3c1c7f10 17 /* fp state follows here */
1da177e4
LT
18};
19
123a6347 20struct rt_sigframe {
fc0b1af2 21 char __user *pretcode;
1da177e4 22 int sig;
fc0b1af2
AV
23 struct siginfo __user *pinfo;
24 void __user *puc;
1da177e4
LT
25 struct siginfo info;
26 struct ucontext uc;
1da177e4 27 char retcode[8];
3c1c7f10 28 /* fp state follows here */
1da177e4 29};
123a6347
HH
30#else
31struct rt_sigframe {
32 char __user *pretcode;
33 struct ucontext uc;
34 struct siginfo info;
3c1c7f10 35 /* fp state follows here */
123a6347
HH
36};
37#endif