1*2ae61418Skettenis /* $OpenBSD: signal.h,v 1.2 2017/03/12 17:57:12 kettenis Exp $ */ 2f24071e5Spatrick /* 3f24071e5Spatrick * Copyright (c) 1992, 1993 4f24071e5Spatrick * The Regents of the University of California. All rights reserved. 5f24071e5Spatrick * 6f24071e5Spatrick * This code is derived from software contributed to Berkeley by 7f24071e5Spatrick * Ralph Campbell. 8f24071e5Spatrick * 9f24071e5Spatrick * Redistribution and use in source and binary forms, with or without 10f24071e5Spatrick * modification, are permitted provided that the following conditions 11f24071e5Spatrick * are met: 12f24071e5Spatrick * 1. Redistributions of source code must retain the above copyright 13f24071e5Spatrick * notice, this list of conditions and the following disclaimer. 14f24071e5Spatrick * 2. Redistributions in binary form must reproduce the above copyright 15f24071e5Spatrick * notice, this list of conditions and the following disclaimer in the 16f24071e5Spatrick * documentation and/or other materials provided with the distribution. 17f24071e5Spatrick * 3. Neither the name of the University nor the names of its contributors 18f24071e5Spatrick * may be used to endorse or promote products derived from this software 19f24071e5Spatrick * without specific prior written permission. 20f24071e5Spatrick * 21f24071e5Spatrick * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 22f24071e5Spatrick * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23f24071e5Spatrick * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24f24071e5Spatrick * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 25f24071e5Spatrick * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 26f24071e5Spatrick * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 27f24071e5Spatrick * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 28f24071e5Spatrick * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 29f24071e5Spatrick * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 30f24071e5Spatrick * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 31f24071e5Spatrick * SUCH DAMAGE. 32f24071e5Spatrick * 33f24071e5Spatrick * @(#)signal.h 8.1 (Berkeley) 6/10/93 34f24071e5Spatrick */ 35f24071e5Spatrick 36f24071e5Spatrick #ifndef _MACHINE_SIGNAL_H_ 37f24071e5Spatrick #define _MACHINE_SIGNAL_H_ 38f24071e5Spatrick 39f24071e5Spatrick #include <sys/cdefs.h> 40f24071e5Spatrick 41f24071e5Spatrick typedef int sig_atomic_t; 42f24071e5Spatrick 43f24071e5Spatrick #if __BSD_VISIBLE || __XPG_VISIBLE >= 420 44f24071e5Spatrick /* 45f24071e5Spatrick * Information pushed on stack when a signal is delivered. 46f24071e5Spatrick * This is used by the kernel to restore state following 47f24071e5Spatrick * execution of the signal handler. It is also made available 48f24071e5Spatrick * to the handler to allow it to restore state properly if 49f24071e5Spatrick * a non-standard exit is performed. 50f24071e5Spatrick */ 51f24071e5Spatrick struct sigcontext { 52f24071e5Spatrick int __sc_unused; 53*2ae61418Skettenis int sc_mask; /* signal mask to restore */ 54f24071e5Spatrick 55*2ae61418Skettenis unsigned long sc_sp; 56*2ae61418Skettenis unsigned long sc_lr; 57*2ae61418Skettenis unsigned long sc_elr; 58*2ae61418Skettenis unsigned long sc_spsr; 59*2ae61418Skettenis unsigned long sc_x[30]; 60*2ae61418Skettenis 61*2ae61418Skettenis long sc_cookie; 62f24071e5Spatrick }; 63f24071e5Spatrick #endif /* __BSD_VISIBLE || __XPG_VISIBLE >= 420 */ 64f24071e5Spatrick #endif /* !_MACHINE_SIGNAL_H_ */ 65