1/*	$OpenBSD: signal.h,v 1.10 2018/06/23 22:15:14 kettenis Exp $	*/
2/*	$NetBSD: signal.h,v 1.5 2003/10/18 17:57:21 briggs Exp $	*/
3
4/*
5 * Copyright (c) 1994-1996 Mark Brinicombe.
6 * Copyright (c) 1994 Brini.
7 * All rights reserved.
8 *
9 * This code is derived from software written for Brini by Mark Brinicombe
10 *
11 * Redistribution and use in source and binary forms, with or without
12 * modification, are permitted provided that the following conditions
13 * are met:
14 * 1. Redistributions of source code must retain the above copyright
15 *    notice, this list of conditions and the following disclaimer.
16 * 2. Redistributions in binary form must reproduce the above copyright
17 *    notice, this list of conditions and the following disclaimer in the
18 *    documentation and/or other materials provided with the distribution.
19 * 3. All advertising materials mentioning features or use of this software
20 *    must display the following acknowledgement:
21 *	This product includes software developed by Brini.
22 * 4. The name of the company nor the name of the author may be used to
23 *    endorse or promote products derived from this software without specific
24 *    prior written permission.
25 *
26 * THIS SOFTWARE IS PROVIDED BY BRINI ``AS IS'' AND ANY EXPRESS OR IMPLIED
27 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
28 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
29 * IN NO EVENT SHALL BRINI OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
30 * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
31 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
32 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * RiscBSD kernel project
39 *
40 * signal.h
41 *
42 * Architecture dependant signal types and structures
43 *
44 * Created      : 30/09/94
45 */
46
47#ifndef _ARM_SIGNAL_H_
48#define _ARM_SIGNAL_H_
49
50#ifndef _LOCORE
51#include <sys/cdefs.h>
52
53typedef int sig_atomic_t;
54
55#if __BSD_VISIBLE || __XPG_VISIBLE >= 420
56/*
57 * Information pushed on stack when a signal is delivered.
58 * This is used by the kernel to restore state following
59 * execution of the signal handler.  It is also made available
60 * to the handler to allow it to restore state properly if
61 * a non-standard exit is performed.
62 */
63struct sigcontext {
64	long	sc_cookie;
65	int	sc_mask;	/* signal mask to restore */
66
67	unsigned int sc_spsr;
68	unsigned int sc_r0;
69	unsigned int sc_r1;
70	unsigned int sc_r2;
71	unsigned int sc_r3;
72	unsigned int sc_r4;
73	unsigned int sc_r5;
74	unsigned int sc_r6;
75	unsigned int sc_r7;
76	unsigned int sc_r8;
77	unsigned int sc_r9;
78	unsigned int sc_r10;
79	unsigned int sc_r11;
80	unsigned int sc_r12;
81	unsigned int sc_usr_sp;
82	unsigned int sc_usr_lr;
83	unsigned int sc_svc_lr;
84	unsigned int sc_pc;
85
86	unsigned int sc_fpused;
87	unsigned int sc_fpscr;
88	unsigned long long sc_fpreg[32];
89};
90#endif /* __BSD_VISIBLE || __XPG_VISIBLE >= 420 */
91#endif /* !_LOCORE */
92
93#endif	/* !_ARM_SIGNAL_H_ */
94