about summary refs log tree commit diff
path: root/nptl/allocatestack.c
diff options
context:
space:
mode:
authorAllan McRae <allan@archlinux.org>2014-02-05 21:14:59 +1000
committerAllan McRae <allan@archlinux.org>2014-02-06 08:46:20 +1000
commit73d61e4f6c65da714c0f8a3a233725322553ceba (patch)
tree1bd578a230d6b0d7a7d09c53de0c243008928df3 /nptl/allocatestack.c
parent27e839f6f068b6109c6bf2f634f4426b48723218 (diff)
downloadglibc-73d61e4f6c65da714c0f8a3a233725322553ceba.tar.gz
glibc-73d61e4f6c65da714c0f8a3a233725322553ceba.tar.xz
glibc-73d61e4f6c65da714c0f8a3a233725322553ceba.zip
Revert "Async-signal safe TLS."
This reverts commit 7f507ee17aee720fa423fa38502bc3caa0dd03d7.

Conflicts:
	ChangeLog
	nptl/tst-tls7.c
	nptl/tst-tls7mod.c
Diffstat (limited to 'nptl/allocatestack.c')
-rw-r--r--nptl/allocatestack.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/nptl/allocatestack.c b/nptl/allocatestack.c
index 2a5ac22117..7f6094ebb2 100644
--- a/nptl/allocatestack.c
+++ b/nptl/allocatestack.c
@@ -1173,18 +1173,13 @@ init_one_static_tls (struct pthread *curp, struct link_map *map)
 #  error "Either TLS_TCB_AT_TP or TLS_DTV_AT_TP must be defined"
 # endif
 
-  /* Initialize the memory.  */
-  memset (__mempcpy (dest, map->l_tls_initimage, map->l_tls_initimage_size),
-	  '\0', map->l_tls_blocksize - map->l_tls_initimage_size);
-
   /* Fill in the DTV slot so that a later LD/GD access will find it.  */
-  dtv[map->l_tls_modid].pointer.is_static = true;
-  /* Pairs against the read barrier in tls_get_attr_tail, guaranteeing
-     any thread waiting for an update to pointer.val sees the
-     initimage write.  */
-  atomic_write_barrier ();
   dtv[map->l_tls_modid].pointer.val = dest;
+  dtv[map->l_tls_modid].pointer.is_static = true;
 
+  /* Initialize the memory.  */
+  memset (__mempcpy (dest, map->l_tls_initimage, map->l_tls_initimage_size),
+	  '\0', map->l_tls_blocksize - map->l_tls_initimage_size);
 }
 
 void