1 #ifndef ASM_X86__IA32_H
2 #define ASM_X86__IA32_H
5 #ifdef CONFIG_IA32_EMULATION
7 #include <linux/compat.h>
10 * 32 bit structures for IA32 support.
13 #include <asm/sigcontext32.h>
17 unsigned int sa_handler; /* Really a pointer, but need to deal
19 unsigned int sa_flags;
20 unsigned int sa_restorer; /* Another 32 bit pointer */
21 compat_sigset_t sa_mask; /* A 32 bit mask */
24 struct old_sigaction32 {
25 unsigned int sa_handler; /* Really a pointer, but need to deal
27 compat_old_sigset_t sa_mask; /* A 32 bit mask */
28 unsigned int sa_flags;
29 unsigned int sa_restorer; /* Another 32 bit pointer */
32 typedef struct sigaltstack_ia32 {
38 struct ucontext_ia32 {
39 unsigned int uc_flags;
41 stack_ia32_t uc_stack;
42 struct sigcontext_ia32 uc_mcontext;
43 compat_sigset_t uc_sigmask; /* mask last for extensibility */
46 /* This matches struct stat64 in glibc2.2, hence the absolutely
47 * insane amounts of padding around dev_t's.
50 unsigned long long st_dev;
51 unsigned char __pad0[4];
53 #define STAT64_HAS_BROKEN_ST_INO 1
54 unsigned int __st_ino;
57 unsigned int st_nlink;
62 unsigned long long st_rdev;
63 unsigned char __pad3[4];
66 unsigned int st_blksize;
68 long long st_blocks;/* Number 512-byte blocks allocated */
71 unsigned st_atime_nsec;
73 unsigned st_mtime_nsec;
75 unsigned st_ctime_nsec;
77 unsigned long long st_ino;
78 } __attribute__((packed));
80 typedef struct compat_siginfo {
86 int _pad[((128 / sizeof(int)) - 3)];
90 unsigned int _pid; /* sender's pid */
91 unsigned int _uid; /* sender's uid */
96 compat_timer_t _tid; /* timer id */
97 int _overrun; /* overrun count */
98 compat_sigval_t _sigval; /* same as below */
99 int _sys_private; /* not to be passed to user */
100 int _overrun_incr; /* amount to add to overrun */
103 /* POSIX.1b signals */
105 unsigned int _pid; /* sender's pid */
106 unsigned int _uid; /* sender's uid */
107 compat_sigval_t _sigval;
112 unsigned int _pid; /* which child */
113 unsigned int _uid; /* sender's uid */
114 int _status; /* exit code */
115 compat_clock_t _utime;
116 compat_clock_t _stime;
119 /* SIGILL, SIGFPE, SIGSEGV, SIGBUS */
121 unsigned int _addr; /* faulting insn/memory ref. */
126 int _band; /* POLL_IN, POLL_OUT, POLL_MSG */
135 struct sigcontext_ia32 sc;
136 struct _fpstate_ia32 fpstate;
137 unsigned int extramask[_COMPAT_NSIG_WORDS-1];
140 struct rt_sigframe32 {
145 compat_siginfo_t info;
146 struct ucontext_ia32 uc;
147 struct _fpstate_ia32 fpstate;
152 compat_ino_t f_tinode;
157 #define IA32_STACK_TOP IA32_PAGE_OFFSET
161 extern int ia32_setup_arg_pages(struct linux_binprm *bprm,
162 unsigned long stack_top, int exec_stack);
164 extern void ia32_pick_mmap_layout(struct mm_struct *mm);
168 #endif /* !CONFIG_IA32_SUPPORT */
170 #endif /* ASM_X86__IA32_H */