190edf67eSKonstantin Belousov /*- 29b10f59aSPedro F. Giffuni * SPDX-License-Identifier: BSD-3-Clause 39b10f59aSPedro F. Giffuni * 490edf67eSKonstantin Belousov * Copyright (c) 1999 Marcel Moolenaar 590edf67eSKonstantin Belousov * All rights reserved. 690edf67eSKonstantin Belousov * 790edf67eSKonstantin Belousov * Redistribution and use in source and binary forms, with or without 890edf67eSKonstantin Belousov * modification, are permitted provided that the following conditions 990edf67eSKonstantin Belousov * are met: 1090edf67eSKonstantin Belousov * 1. Redistributions of source code must retain the above copyright 1190edf67eSKonstantin Belousov * notice, this list of conditions and the following disclaimer 1290edf67eSKonstantin Belousov * in this position and unchanged. 1390edf67eSKonstantin Belousov * 2. Redistributions in binary form must reproduce the above copyright 1490edf67eSKonstantin Belousov * notice, this list of conditions and the following disclaimer in the 1590edf67eSKonstantin Belousov * documentation and/or other materials provided with the distribution. 1690edf67eSKonstantin Belousov * 3. The name of the author may not be used to endorse or promote products 1790edf67eSKonstantin Belousov * derived from this software without specific prior written permission. 1890edf67eSKonstantin Belousov * 1990edf67eSKonstantin Belousov * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 2090edf67eSKonstantin Belousov * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 2190edf67eSKonstantin Belousov * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 2290edf67eSKonstantin Belousov * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 2390edf67eSKonstantin Belousov * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 2490edf67eSKonstantin Belousov * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 2590edf67eSKonstantin Belousov * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 2690edf67eSKonstantin Belousov * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 2790edf67eSKonstantin Belousov * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 2890edf67eSKonstantin Belousov * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 2990edf67eSKonstantin Belousov */ 3090edf67eSKonstantin Belousov 3190edf67eSKonstantin Belousov #ifndef _SYS__UCONTEXT_H_ 3290edf67eSKonstantin Belousov #define _SYS__UCONTEXT_H_ 3390edf67eSKonstantin Belousov 3490edf67eSKonstantin Belousov typedef struct __ucontext { 3590edf67eSKonstantin Belousov /* 3690edf67eSKonstantin Belousov * Keep the order of the first two fields. Also, 3790edf67eSKonstantin Belousov * keep them the first two fields in the structure. 3890edf67eSKonstantin Belousov * This way we can have a union with struct 3990edf67eSKonstantin Belousov * sigcontext and ucontext_t. This allows us to 4090edf67eSKonstantin Belousov * support them both at the same time. 4190edf67eSKonstantin Belousov * note: the union is not defined, though. 4290edf67eSKonstantin Belousov */ 4390edf67eSKonstantin Belousov __sigset_t uc_sigmask; 4490edf67eSKonstantin Belousov mcontext_t uc_mcontext; 4590edf67eSKonstantin Belousov 4690edf67eSKonstantin Belousov struct __ucontext *uc_link; 4790edf67eSKonstantin Belousov struct __stack_t uc_stack; 4890edf67eSKonstantin Belousov int uc_flags; 4990edf67eSKonstantin Belousov int __spare__[4]; 5090edf67eSKonstantin Belousov } ucontext_t; 5190edf67eSKonstantin Belousov 5290edf67eSKonstantin Belousov #endif /* _SYS__UCONTEXT_H */ 53