2 * Copyright (c) 2002-2005 Apple Computer, Inc. All rights reserved.
4 * @APPLE_LICENSE_HEADER_START@
6 * The contents of this file constitute Original Code as defined in and
7 * are subject to the Apple Public Source License Version 1.1 (the
8 * "License"). You may not use this file except in compliance with the
9 * License. Please obtain a copy of the License at
10 * http://www.apple.com/publicsource and read it before using this file.
12 * This Original Code and all software distributed under the License are
13 * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
14 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
15 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
16 * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
17 * License for the specific language governing rights and limitations
20 * @APPLE_LICENSE_HEADER_END@
23 #ifndef _SYS_UCONTEXT_H_
24 #define _SYS_UCONTEXT_H_
26 #include <sys/cdefs.h>
27 #include <sys/_types.h>
28 #include <machine/ucontext.h>
32 typedef __darwin_sigset_t sigset_t
;
37 typedef __darwin_stack_t stack_t
;
42 #ifndef _POSIX_C_SOURCE
43 typedef struct ucontext ucontext_t
;
44 #else /* _POSIX_C_SOURCE */
45 typedef struct __darwin_ucontext ucontext_t
;
46 #endif /* _POSIX_C_SOURCE */
49 #ifndef _POSIX_C_SOURCE
52 typedef struct ucontext64 ucontext64_t
;
54 #endif /* _POSIX_C_SOURCE */
57 #include <machine/types.h> /* user_addr_t, user_size_t */
59 /* kernel representation of struct ucontext64 for 64 bit processes */
60 struct user_ucontext64
{
62 sigset_t uc_sigmask
; /* signal mask */
63 struct user_sigaltstack uc_stack
; /* stack */
64 user_addr_t uc_link
; /* ucontext pointer */
65 user_size_t uc_mcsize
; /* mcontext size */
66 user_addr_t uc_mcontext64
; /* machine context */
69 typedef struct user_ucontext64 user_ucontext64_t
;
72 #endif /* _SYS_UCONTEXT_H_ */