summaryrefslogtreecommitdiff
path: root/lib/libpthread/pthread.c
diff options
context:
space:
mode:
authorjoerg <joerg@NetBSD.org>2012-05-04 12:26:33 +0000
committerjoerg <joerg@NetBSD.org>2012-05-04 12:26:33 +0000
commit0cbed0f4f2f5eecb2e3e23668e0a82696a209ebc (patch)
tree78dc29bd7875ee8cf51df84889eac4eca5f20c84 /lib/libpthread/pthread.c
parented5c821ae2323b747b93767daedf8b57d48b436d (diff)
Simplify check for TLS definition to not hide code. Drop it in another
place as it is redundant.
Diffstat (limited to 'lib/libpthread/pthread.c')
-rw-r--r--lib/libpthread/pthread.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/lib/libpthread/pthread.c b/lib/libpthread/pthread.c
index 4e9ef1858ed..aa603b32f11 100644
--- a/lib/libpthread/pthread.c
+++ b/lib/libpthread/pthread.c
@@ -1,4 +1,4 @@
-/* $NetBSD: pthread.c,v 1.134 2012/04/26 00:21:44 enami Exp $ */
+/* $NetBSD: pthread.c,v 1.135 2012/05/04 12:26:33 joerg Exp $ */
/*-
* Copyright (c) 2001, 2002, 2003, 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: pthread.c,v 1.134 2012/04/26 00:21:44 enami Exp $");
+__RCSID("$NetBSD: pthread.c,v 1.135 2012/05/04 12:26:33 joerg Exp $");
#define __EXPOSE_STACK 1
@@ -1301,14 +1301,12 @@ pthread__initmain(pthread_t *newt)
4 * pthread__pagesize / 1024);
*newt = &pthread__main;
-#if defined(__HAVE_TLS_VARIANT_I) || defined(__HAVE_TLS_VARIANT_II)
-# ifdef __HAVE___LWP_GETTCB_FAST
+#ifdef __HAVE___LWP_GETTCB_FAST
pthread__main.pt_tls = __lwp_gettcb_fast();
-# else
+#else
pthread__main.pt_tls = _lwp_getprivate();
-# endif
- pthread__main.pt_tls->tcb_pthread = &pthread__main;
#endif
+ pthread__main.pt_tls->tcb_pthread = &pthread__main;
}
#ifndef lint