]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Set stacksize in __aio_create_helper_thread to default for AIO with TLS.
authorRyan S. Arnold <rsa@linux.vnet.ibm.com>
Fri, 1 Jul 2011 12:02:57 +0000 (07:02 -0500)
committerRyan S. Arnold <rsa@us.ibm.com>
Fri, 1 Jul 2011 12:02:57 +0000 (07:02 -0500)
ChangeLog
nptl/sysdeps/unix/sysv/linux/aio_misc.h

index cb874565c00281439e63aea15562d09ee476a4bc..625f9de6db6f1eb141f5d717eb4aa9f8e4e00f21 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2011-06-30  Ryan S. Arnold  <rsa@linux.vnet.ibm.com>
+
+       * nptl/sysdeps/unix/sysv/linux/aio_misc.h
+       (__aio_create_helper_thread): Set the pthread_attr stacksize to the
+       default, 0.  When previously set to PTHREAD_STACK_MIN, pthread_create
+       would fail if TLS requirements on the stack exceed that small value.
+
 2011-06-28  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>
 
        * sysdeps/powerpc/fpu/e_hypot.c: optimizations for POWER5 and POWER6.
index 406d96e86563e7db2dc690da62c2131a273915d3..a692b50e49fb2546d89f3a9bd8ffc29790e1e1d4 100644 (file)
@@ -46,8 +46,9 @@ __aio_create_helper_thread (pthread_t *threadp, void *(*tf) (void *),
   pthread_attr_init (&attr);
   pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED);
 
-  /* The helper thread needs only very little resources.  */
-  (void) pthread_attr_setstacksize (&attr, PTHREAD_STACK_MIN);
+  /* Leave the stack size as the default or it can be too small for TLS
+   * requirements if set to PTHREAD_STACK_MIN.  */
+  (void) pthread_attr_setstacksize (&attr, 0);
 
   /* Block all signals in the helper thread.  To do this thoroughly we
      temporarily have to block all signals here.  */