1 /* Copyright (C) 2008 Free Software Foundation, Inc.
2 This file is part of the GNU C Library.
3 Contributed by David Bartley <dtbartle@csclub.uwaterloo.ca>, 2008.
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, write to the Free
17 Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
20 /* Register atfork handlers to protect signal_lock. */
21 extern void sigaction_atfork (void);
22 #define PLATFORM_PTHREAD_INIT \
23 sigaction_atfork (); \
24 THREAD_SETMEM (pd, main_thread, 1);
26 /* Additional descr fields. */
27 # define PLATFORM_DESCR_FIELDS \
28 int sigpipe_disabled; \
31 /* Use tid as pthread_t (instead of descr). */
32 #define PTHREAD_T_IS_TID
34 /* Use pthread scheduler functions in tpp. */
35 #define TPP_PTHREAD_SCHED
37 /* pthread_setXid not supported/needed. */
38 #define NO_SETXID_SUPPORT
40 /* Disable robust list. */
41 #define NO_ROBUST_LIST_SUPPORT
43 /* Disable futex support. */
44 #define NO_FUTEX_SUPPORT
46 /* Make sure SIGCANCEL sanity check compiles. */
47 #define SI_TKILL SI_LWP
48 #define __ASSUME_CORRECT_SI_PID
50 /* We support tkill. */
52 #undef __ASSUME_TGKILL
54 /* pthread_ is unsigned. */
55 #define FREE_P(descr) ((descr)->tid == (pthread_t)-1)