blob: d38563a394f2cef1a3d58586a3b789ea3a58a06f [file] [log] [blame]
Greg Kroah-Hartman6f52b162017-11-01 15:08:43 +01001/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
David Howells70c1674f2012-10-16 21:28:05 +01002#ifndef _UAPI_ASM_PARISC_SIGNAL_H
3#define _UAPI_ASM_PARISC_SIGNAL_H
4
5#define SIGHUP 1
6#define SIGINT 2
7#define SIGQUIT 3
8#define SIGILL 4
9#define SIGTRAP 5
10#define SIGABRT 6
11#define SIGIOT 6
Helge Deller1f25df22014-10-10 22:20:17 +020012#define SIGSTKFLT 7
David Howells70c1674f2012-10-16 21:28:05 +010013#define SIGFPE 8
14#define SIGKILL 9
15#define SIGBUS 10
16#define SIGSEGV 11
Helge Deller1f25df22014-10-10 22:20:17 +020017#define SIGXCPU 12
David Howells70c1674f2012-10-16 21:28:05 +010018#define SIGPIPE 13
19#define SIGALRM 14
20#define SIGTERM 15
21#define SIGUSR1 16
22#define SIGUSR2 17
23#define SIGCHLD 18
24#define SIGPWR 19
25#define SIGVTALRM 20
26#define SIGPROF 21
27#define SIGIO 22
28#define SIGPOLL SIGIO
29#define SIGWINCH 23
30#define SIGSTOP 24
31#define SIGTSTP 25
32#define SIGCONT 26
33#define SIGTTIN 27
34#define SIGTTOU 28
35#define SIGURG 29
Helge Deller1f25df22014-10-10 22:20:17 +020036#define SIGXFSZ 30
37#define SIGUNUSED 31
38#define SIGSYS 31 /* Linux doesn't use this */
David Howells70c1674f2012-10-16 21:28:05 +010039
40/* These should not be considered constants from userland. */
Helge Deller1f25df22014-10-10 22:20:17 +020041#define SIGRTMIN 32
David Howells70c1674f2012-10-16 21:28:05 +010042#define SIGRTMAX _NSIG /* it's 44 under HP/UX */
43
44/*
45 * SA_FLAGS values:
46 *
47 * SA_ONSTACK indicates that a registered stack_t will be used.
48 * SA_RESTART flag to get restarting signals (which were the default long ago)
49 * SA_NOCLDSTOP flag to turn off SIGCHLD when children stop.
50 * SA_RESETHAND clears the handler when the signal is delivered.
51 * SA_NOCLDWAIT flag on SIGCHLD to inhibit zombies.
52 * SA_NODEFER prevents the current signal from being masked in the handler.
53 *
54 * SA_ONESHOT and SA_NOMASK are the historical Linux names for the Single
55 * Unix names RESETHAND and NODEFER respectively.
56 */
57#define SA_ONSTACK 0x00000001
58#define SA_RESETHAND 0x00000004
59#define SA_NOCLDSTOP 0x00000008
60#define SA_SIGINFO 0x00000010
61#define SA_NODEFER 0x00000020
62#define SA_RESTART 0x00000040
63#define SA_NOCLDWAIT 0x00000080
64#define _SA_SIGGFAULT 0x00000100 /* HPUX */
65
66#define SA_NOMASK SA_NODEFER
67#define SA_ONESHOT SA_RESETHAND
68
David Howells70c1674f2012-10-16 21:28:05 +010069#define MINSIGSTKSZ 2048
70#define SIGSTKSZ 8192
71
72
73#define SIG_BLOCK 0 /* for blocking signals */
74#define SIG_UNBLOCK 1 /* for unblocking signals */
75#define SIG_SETMASK 2 /* for setting the signal mask */
76
77#define SIG_DFL ((__sighandler_t)0) /* default signal handling */
78#define SIG_IGN ((__sighandler_t)1) /* ignore signal */
79#define SIG_ERR ((__sighandler_t)-1) /* error return from signal */
80
81# ifndef __ASSEMBLY__
82
83# include <linux/types.h>
84
85/* Avoid too many header ordering problems. */
86struct siginfo;
87
88/* Type of a signal handler. */
Helge Dellerd8f54572014-11-10 22:04:47 +010089#if defined(__LP64__)
David Howells70c1674f2012-10-16 21:28:05 +010090/* function pointers on 64-bit parisc are pointers to little structs and the
91 * compiler doesn't support code which changes or tests the address of
92 * the function in the little struct. This is really ugly -PB
93 */
94typedef char __user *__sighandler_t;
95#else
96typedef void __signalfn_t(int);
97typedef __signalfn_t __user *__sighandler_t;
98#endif
99
100typedef struct sigaltstack {
101 void __user *ss_sp;
102 int ss_flags;
103 size_t ss_size;
104} stack_t;
105
106#endif /* !__ASSEMBLY */
107#endif /* _UAPI_ASM_PARISC_SIGNAL_H */