Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
0002 #ifndef _UAPI_ASM_X86_SIGNAL_H
0003 #define _UAPI_ASM_X86_SIGNAL_H
0004 
0005 #ifndef __ASSEMBLY__
0006 #include <linux/types.h>
0007 #include <linux/time.h>
0008 #include <linux/compiler.h>
0009 
0010 /* Avoid too many header ordering problems.  */
0011 struct siginfo;
0012 
0013 #ifndef __KERNEL__
0014 /* Here we must cater to libcs that poke about in kernel headers.  */
0015 
0016 #define NSIG        32
0017 typedef unsigned long sigset_t;
0018 
0019 #endif /* __KERNEL__ */
0020 #endif /* __ASSEMBLY__ */
0021 
0022 
0023 #define SIGHUP       1
0024 #define SIGINT       2
0025 #define SIGQUIT      3
0026 #define SIGILL       4
0027 #define SIGTRAP      5
0028 #define SIGABRT      6
0029 #define SIGIOT       6
0030 #define SIGBUS       7
0031 #define SIGFPE       8
0032 #define SIGKILL      9
0033 #define SIGUSR1     10
0034 #define SIGSEGV     11
0035 #define SIGUSR2     12
0036 #define SIGPIPE     13
0037 #define SIGALRM     14
0038 #define SIGTERM     15
0039 #define SIGSTKFLT   16
0040 #define SIGCHLD     17
0041 #define SIGCONT     18
0042 #define SIGSTOP     19
0043 #define SIGTSTP     20
0044 #define SIGTTIN     21
0045 #define SIGTTOU     22
0046 #define SIGURG      23
0047 #define SIGXCPU     24
0048 #define SIGXFSZ     25
0049 #define SIGVTALRM   26
0050 #define SIGPROF     27
0051 #define SIGWINCH    28
0052 #define SIGIO       29
0053 #define SIGPOLL     SIGIO
0054 /*
0055 #define SIGLOST     29
0056 */
0057 #define SIGPWR      30
0058 #define SIGSYS      31
0059 #define SIGUNUSED   31
0060 
0061 /* These should not be considered constants from userland.  */
0062 #define SIGRTMIN    32
0063 #define SIGRTMAX    _NSIG
0064 
0065 #define SA_RESTORER 0x04000000
0066 
0067 #define MINSIGSTKSZ 2048
0068 #define SIGSTKSZ    8192
0069 
0070 #include <asm-generic/signal-defs.h>
0071 
0072 #ifndef __ASSEMBLY__
0073 
0074 
0075 # ifndef __KERNEL__
0076 /* Here we must cater to libcs that poke about in kernel headers.  */
0077 #ifdef __i386__
0078 
0079 struct sigaction {
0080     union {
0081       __sighandler_t _sa_handler;
0082       void (*_sa_sigaction)(int, struct siginfo *, void *);
0083     } _u;
0084     sigset_t sa_mask;
0085     unsigned long sa_flags;
0086     void (*sa_restorer)(void);
0087 };
0088 
0089 #define sa_handler  _u._sa_handler
0090 #define sa_sigaction    _u._sa_sigaction
0091 
0092 #else /* __i386__ */
0093 
0094 struct sigaction {
0095     __sighandler_t sa_handler;
0096     unsigned long sa_flags;
0097     __sigrestore_t sa_restorer;
0098     sigset_t sa_mask;       /* mask last for extensibility */
0099 };
0100 
0101 #endif /* !__i386__ */
0102 # endif /* ! __KERNEL__ */
0103 
0104 typedef struct sigaltstack {
0105     void __user *ss_sp;
0106     int ss_flags;
0107     __kernel_size_t ss_size;
0108 } stack_t;
0109 
0110 #endif /* __ASSEMBLY__ */
0111 
0112 #endif /* _UAPI_ASM_X86_SIGNAL_H */