Update copyright dates with scripts/update-copyrights.
[glibc.git] / sysdeps / unix / sysv / linux / nios2 / sys / ucontext.h
blob6701d7ed945314b7a6ae909b84a93ebe37cb0193
1 /* struct ucontext definition, Nios II version.
2 Copyright (C) 2015-2017 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, see
17 <http://www.gnu.org/licenses/>. */
19 /* System V/Nios II ABI compliant context switching support. */
21 #ifndef _SYS_UCONTEXT_H
22 #define _SYS_UCONTEXT_H 1
24 #include <features.h>
25 #include <signal.h>
27 /* We need the signal context definitions even if they are not exposed
28 by <signal.h>. */
29 #include <bits/sigcontext.h>
30 #include <bits/sigstack.h>
33 /* These definitions must be in sync with the kernel. */
35 #define MCONTEXT_VERSION 2
37 /* Context to describe whole processor state. */
38 typedef struct mcontext
40 int version;
41 unsigned long regs[32];
42 } mcontext_t;
44 /* Userlevel context. */
45 typedef struct ucontext
47 unsigned long uc_flags;
48 struct ucontext *uc_link;
49 stack_t uc_stack;
50 mcontext_t uc_mcontext;
51 __sigset_t uc_sigmask;
52 } ucontext_t;
54 #endif /* sys/ucontext.h */