diff options
Diffstat (limited to 'arch/mips/include/asm/siginfo.h')
-rw-r--r-- | arch/mips/include/asm/siginfo.h | 104 |
1 files changed, 1 insertions, 103 deletions
diff --git a/arch/mips/include/asm/siginfo.h b/arch/mips/include/asm/siginfo.h index 20ebeb875ee..dd9a762646f 100644 --- a/arch/mips/include/asm/siginfo.h +++ b/arch/mips/include/asm/siginfo.h | |||
@@ -9,108 +9,8 @@ | |||
9 | #ifndef _ASM_SIGINFO_H | 9 | #ifndef _ASM_SIGINFO_H |
10 | #define _ASM_SIGINFO_H | 10 | #define _ASM_SIGINFO_H |
11 | 11 | ||
12 | #include <uapi/asm/siginfo.h> | ||
12 | 13 | ||
13 | #define __ARCH_SIGEV_PREAMBLE_SIZE (sizeof(long) + 2*sizeof(int)) | ||
14 | #undef __ARCH_SI_TRAPNO /* exception code needs to fill this ... */ | ||
15 | |||
16 | #define HAVE_ARCH_SIGINFO_T | ||
17 | |||
18 | /* | ||
19 | * We duplicate the generic versions - <asm-generic/siginfo.h> is just borked | ||
20 | * by design ... | ||
21 | */ | ||
22 | #define HAVE_ARCH_COPY_SIGINFO | ||
23 | struct siginfo; | ||
24 | |||
25 | /* | ||
26 | * Careful to keep union _sifields from shifting ... | ||
27 | */ | ||
28 | #ifdef CONFIG_32BIT | ||
29 | #define __ARCH_SI_PREAMBLE_SIZE (3 * sizeof(int)) | ||
30 | #endif | ||
31 | #ifdef CONFIG_64BIT | ||
32 | #define __ARCH_SI_PREAMBLE_SIZE (4 * sizeof(int)) | ||
33 | #endif | ||
34 | |||
35 | #include <asm-generic/siginfo.h> | ||
36 | |||
37 | typedef struct siginfo { | ||
38 | int si_signo; | ||
39 | int si_code; | ||
40 | int si_errno; | ||
41 | int __pad0[SI_MAX_SIZE / sizeof(int) - SI_PAD_SIZE - 3]; | ||
42 | |||
43 | union { | ||
44 | int _pad[SI_PAD_SIZE]; | ||
45 | |||
46 | /* kill() */ | ||
47 | struct { | ||
48 | pid_t _pid; /* sender's pid */ | ||
49 | __ARCH_SI_UID_T _uid; /* sender's uid */ | ||
50 | } _kill; | ||
51 | |||
52 | /* POSIX.1b timers */ | ||
53 | struct { | ||
54 | timer_t _tid; /* timer id */ | ||
55 | int _overrun; /* overrun count */ | ||
56 | char _pad[sizeof( __ARCH_SI_UID_T) - sizeof(int)]; | ||
57 | sigval_t _sigval; /* same as below */ | ||
58 | int _sys_private; /* not to be passed to user */ | ||
59 | } _timer; | ||
60 | |||
61 | /* POSIX.1b signals */ | ||
62 | struct { | ||
63 | pid_t _pid; /* sender's pid */ | ||
64 | __ARCH_SI_UID_T _uid; /* sender's uid */ | ||
65 | sigval_t _sigval; | ||
66 | } _rt; | ||
67 | |||
68 | /* SIGCHLD */ | ||
69 | struct { | ||
70 | pid_t _pid; /* which child */ | ||
71 | __ARCH_SI_UID_T _uid; /* sender's uid */ | ||
72 | int _status; /* exit code */ | ||
73 | clock_t _utime; | ||
74 | clock_t _stime; | ||
75 | } _sigchld; | ||
76 | |||
77 | /* IRIX SIGCHLD */ | ||
78 | struct { | ||
79 | pid_t _pid; /* which child */ | ||
80 | clock_t _utime; | ||
81 | int _status; /* exit code */ | ||
82 | clock_t _stime; | ||
83 | } _irix_sigchld; | ||
84 | |||
85 | /* SIGILL, SIGFPE, SIGSEGV, SIGBUS */ | ||
86 | struct { | ||
87 | void __user *_addr; /* faulting insn/memory ref. */ | ||
88 | #ifdef __ARCH_SI_TRAPNO | ||
89 | int _trapno; /* TRAP # which caused the signal */ | ||
90 | #endif | ||
91 | short _addr_lsb; | ||
92 | } _sigfault; | ||
93 | |||
94 | /* SIGPOLL, SIGXFSZ (To do ...) */ | ||
95 | struct { | ||
96 | __ARCH_SI_BAND_T _band; /* POLL_IN, POLL_OUT, POLL_MSG */ | ||
97 | int _fd; | ||
98 | } _sigpoll; | ||
99 | } _sifields; | ||
100 | } siginfo_t; | ||
101 | |||
102 | /* | ||
103 | * si_code values | ||
104 | * Again these have been chosen to be IRIX compatible. | ||
105 | */ | ||
106 | #undef SI_ASYNCIO | ||
107 | #undef SI_TIMER | ||
108 | #undef SI_MESGQ | ||
109 | #define SI_ASYNCIO -2 /* sent by AIO completion */ | ||
110 | #define SI_TIMER __SI_CODE(__SI_TIMER, -3) /* sent by timer expiration */ | ||
111 | #define SI_MESGQ __SI_CODE(__SI_MESGQ, -4) /* sent by real time mesq state change */ | ||
112 | |||
113 | #ifdef __KERNEL__ | ||
114 | 14 | ||
115 | /* | 15 | /* |
116 | * Duplicated here because of <asm-generic/siginfo.h> braindamage ... | 16 | * Duplicated here because of <asm-generic/siginfo.h> braindamage ... |
@@ -126,6 +26,4 @@ static inline void copy_siginfo(struct siginfo *to, struct siginfo *from) | |||
126 | memcpy(to, from, 3*sizeof(int) + sizeof(from->_sifields._sigchld)); | 26 | memcpy(to, from, 3*sizeof(int) + sizeof(from->_sifields._sigchld)); |
127 | } | 27 | } |
128 | 28 | ||
129 | #endif | ||
130 | |||
131 | #endif /* _ASM_SIGINFO_H */ | 29 | #endif /* _ASM_SIGINFO_H */ |