1 /****************************************************************************
2  ****************************************************************************
3  ***
4  ***   This header was automatically generated from a Linux kernel header
5  ***   of the same name, to make information necessary for userspace to
6  ***   call into the kernel available to libc.  It contains only constants,
7  ***   structures, and macros generated from the original header, and thus,
8  ***   contains no copyrightable information.
9  ***
10  ***   To edit the content of this header, modify the corresponding
11  ***   source file (e.g. under external/kernel-headers/original/) then
12  ***   run bionic/libc/kernel/tools/update_all.py
13  ***
14  ***   Any manual change here will be lost the next time this script will
15  ***   be run. You've been warned!
16  ***
17  ****************************************************************************
18  ****************************************************************************/
19 #ifndef _UAPI_ASM_GENERIC_SIGINFO_H
20 #define _UAPI_ASM_GENERIC_SIGINFO_H
21 #include <linux/compiler.h>
22 #include <linux/types.h>
23 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
24 typedef union sigval {
25   int sival_int;
26   void __user * sival_ptr;
27 } sigval_t;
28 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
29 #ifndef __ARCH_SI_PREAMBLE_SIZE
30 #define __ARCH_SI_PREAMBLE_SIZE (3 * sizeof(int))
31 #endif
32 #define SI_MAX_SIZE 128
33 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
34 #ifndef SI_PAD_SIZE
35 #define SI_PAD_SIZE ((SI_MAX_SIZE - __ARCH_SI_PREAMBLE_SIZE) / sizeof(int))
36 #endif
37 #ifndef __ARCH_SI_UID_T
38 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
39 #define __ARCH_SI_UID_T __kernel_uid32_t
40 #endif
41 #ifndef __ARCH_SI_BAND_T
42 #define __ARCH_SI_BAND_T long
43 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
44 #endif
45 #ifndef __ARCH_SI_CLOCK_T
46 #define __ARCH_SI_CLOCK_T __kernel_clock_t
47 #endif
48 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
49 #ifndef __ARCH_SI_ATTRIBUTES
50 #define __ARCH_SI_ATTRIBUTES
51 #endif
52 #ifndef HAVE_ARCH_SIGINFO_T
53 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
54 typedef struct siginfo {
55   int si_signo;
56   int si_errno;
57   int si_code;
58 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
59   union {
60     int _pad[SI_PAD_SIZE];
61     struct {
62       __kernel_pid_t _pid;
63 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
64       __ARCH_SI_UID_T _uid;
65     } _kill;
66     struct {
67       __kernel_timer_t _tid;
68 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
69       int _overrun;
70       char _pad[sizeof(__ARCH_SI_UID_T) - sizeof(int)];
71       sigval_t _sigval;
72       int _sys_private;
73 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
74     } _timer;
75     struct {
76       __kernel_pid_t _pid;
77       __ARCH_SI_UID_T _uid;
78 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
79       sigval_t _sigval;
80     } _rt;
81     struct {
82       __kernel_pid_t _pid;
83 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
84       __ARCH_SI_UID_T _uid;
85       int _status;
86       __ARCH_SI_CLOCK_T _utime;
87       __ARCH_SI_CLOCK_T _stime;
88 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
89     } _sigchld;
90     struct {
91       void __user * _addr;
92 #ifdef __ARCH_SI_TRAPNO
93 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
94       int _trapno;
95 #endif
96       short _addr_lsb;
97       struct {
98 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
99         void __user * _lower;
100         void __user * _upper;
101       } _addr_bnd;
102     } _sigfault;
103 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
104     struct {
105       __ARCH_SI_BAND_T _band;
106       int _fd;
107     } _sigpoll;
108 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
109     struct {
110       void __user * _call_addr;
111       int _syscall;
112       unsigned int _arch;
113 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
114     } _sigsys;
115   } _sifields;
116 } __ARCH_SI_ATTRIBUTES siginfo_t;
117 #define __ARCH_SIGSYS
118 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
119 #endif
120 #define si_pid _sifields._kill._pid
121 #define si_uid _sifields._kill._uid
122 #define si_tid _sifields._timer._tid
123 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
124 #define si_overrun _sifields._timer._overrun
125 #define si_sys_private _sifields._timer._sys_private
126 #define si_status _sifields._sigchld._status
127 #define si_utime _sifields._sigchld._utime
128 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
129 #define si_stime _sifields._sigchld._stime
130 #define si_value _sifields._rt._sigval
131 #define si_int _sifields._rt._sigval.sival_int
132 #define si_ptr _sifields._rt._sigval.sival_ptr
133 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
134 #define si_addr _sifields._sigfault._addr
135 #ifdef __ARCH_SI_TRAPNO
136 #define si_trapno _sifields._sigfault._trapno
137 #endif
138 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
139 #define si_addr_lsb _sifields._sigfault._addr_lsb
140 #define si_lower _sifields._sigfault._addr_bnd._lower
141 #define si_upper _sifields._sigfault._addr_bnd._upper
142 #define si_band _sifields._sigpoll._band
143 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
144 #define si_fd _sifields._sigpoll._fd
145 #ifdef __ARCH_SIGSYS
146 #define si_call_addr _sifields._sigsys._call_addr
147 #define si_syscall _sifields._sigsys._syscall
148 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
149 #define si_arch _sifields._sigsys._arch
150 #endif
151 #define __SI_KILL 0
152 #define __SI_TIMER 0
153 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
154 #define __SI_POLL 0
155 #define __SI_FAULT 0
156 #define __SI_CHLD 0
157 #define __SI_RT 0
158 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
159 #define __SI_MESGQ 0
160 #define __SI_SYS 0
161 #define __SI_CODE(T,N) (N)
162 #define SI_USER 0
163 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
164 #define SI_KERNEL 0x80
165 #define SI_QUEUE - 1
166 #define SI_TIMER __SI_CODE(__SI_TIMER, - 2)
167 #define SI_MESGQ __SI_CODE(__SI_MESGQ, - 3)
168 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
169 #define SI_ASYNCIO - 4
170 #define SI_SIGIO - 5
171 #define SI_TKILL - 6
172 #define SI_DETHREAD - 7
173 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
174 #define SI_FROMUSER(siptr) ((siptr)->si_code <= 0)
175 #define SI_FROMKERNEL(siptr) ((siptr)->si_code > 0)
176 #define ILL_ILLOPC (__SI_FAULT | 1)
177 #define ILL_ILLOPN (__SI_FAULT | 2)
178 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
179 #define ILL_ILLADR (__SI_FAULT | 3)
180 #define ILL_ILLTRP (__SI_FAULT | 4)
181 #define ILL_PRVOPC (__SI_FAULT | 5)
182 #define ILL_PRVREG (__SI_FAULT | 6)
183 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
184 #define ILL_COPROC (__SI_FAULT | 7)
185 #define ILL_BADSTK (__SI_FAULT | 8)
186 #define NSIGILL 8
187 #define FPE_INTDIV (__SI_FAULT | 1)
188 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
189 #define FPE_INTOVF (__SI_FAULT | 2)
190 #define FPE_FLTDIV (__SI_FAULT | 3)
191 #define FPE_FLTOVF (__SI_FAULT | 4)
192 #define FPE_FLTUND (__SI_FAULT | 5)
193 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
194 #define FPE_FLTRES (__SI_FAULT | 6)
195 #define FPE_FLTINV (__SI_FAULT | 7)
196 #define FPE_FLTSUB (__SI_FAULT | 8)
197 #define NSIGFPE 8
198 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
199 #define SEGV_MAPERR (__SI_FAULT | 1)
200 #define SEGV_ACCERR (__SI_FAULT | 2)
201 #define SEGV_BNDERR (__SI_FAULT | 3)
202 #define NSIGSEGV 3
203 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
204 #define BUS_ADRALN (__SI_FAULT | 1)
205 #define BUS_ADRERR (__SI_FAULT | 2)
206 #define BUS_OBJERR (__SI_FAULT | 3)
207 #define BUS_MCEERR_AR (__SI_FAULT | 4)
208 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
209 #define BUS_MCEERR_AO (__SI_FAULT | 5)
210 #define NSIGBUS 5
211 #define TRAP_BRKPT (__SI_FAULT | 1)
212 #define TRAP_TRACE (__SI_FAULT | 2)
213 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
214 #define TRAP_BRANCH (__SI_FAULT | 3)
215 #define TRAP_HWBKPT (__SI_FAULT | 4)
216 #define NSIGTRAP 4
217 #define CLD_EXITED (__SI_CHLD | 1)
218 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
219 #define CLD_KILLED (__SI_CHLD | 2)
220 #define CLD_DUMPED (__SI_CHLD | 3)
221 #define CLD_TRAPPED (__SI_CHLD | 4)
222 #define CLD_STOPPED (__SI_CHLD | 5)
223 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
224 #define CLD_CONTINUED (__SI_CHLD | 6)
225 #define NSIGCHLD 6
226 #define POLL_IN (__SI_POLL | 1)
227 #define POLL_OUT (__SI_POLL | 2)
228 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
229 #define POLL_MSG (__SI_POLL | 3)
230 #define POLL_ERR (__SI_POLL | 4)
231 #define POLL_PRI (__SI_POLL | 5)
232 #define POLL_HUP (__SI_POLL | 6)
233 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
234 #define NSIGPOLL 6
235 #define SYS_SECCOMP (__SI_SYS | 1)
236 #define NSIGSYS 1
237 #define SIGEV_SIGNAL 0
238 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
239 #define SIGEV_NONE 1
240 #define SIGEV_THREAD 2
241 #define SIGEV_THREAD_ID 4
242 #ifndef __ARCH_SIGEV_PREAMBLE_SIZE
243 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
244 #define __ARCH_SIGEV_PREAMBLE_SIZE (sizeof(int) * 2 + sizeof(sigval_t))
245 #endif
246 #define SIGEV_MAX_SIZE 64
247 #define SIGEV_PAD_SIZE ((SIGEV_MAX_SIZE - __ARCH_SIGEV_PREAMBLE_SIZE) / sizeof(int))
248 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
249 typedef struct sigevent {
250   sigval_t sigev_value;
251   int sigev_signo;
252   int sigev_notify;
253 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
254   union {
255     int _pad[SIGEV_PAD_SIZE];
256     int _tid;
257     struct {
258 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
259       void(* _function) (sigval_t);
260       void * _attribute;
261     } _sigev_thread;
262   } _sigev_un;
263 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
264 } sigevent_t;
265 #define sigev_notify_function _sigev_un._sigev_thread._function
266 #define sigev_notify_attributes _sigev_un._sigev_thread._attribute
267 #define sigev_notify_thread_id _sigev_un._tid
268 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
269 #endif
270