diff options
Diffstat (limited to 'linuxthreads/sysdeps/sh')
-rw-r--r-- | linuxthreads/sysdeps/sh/tls.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/linuxthreads/sysdeps/sh/tls.h b/linuxthreads/sysdeps/sh/tls.h index 17a247c6b6..bc9d44fa85 100644 --- a/linuxthreads/sysdeps/sh/tls.h +++ b/linuxthreads/sysdeps/sh/tls.h @@ -64,7 +64,14 @@ typedef struct # define TLS_TCB_SIZE sizeof (tcbhead_t) /* This is the size we need before TCB. */ -# define TLS_PRE_TCB_SIZE sizeof (struct _pthread_descr_struct) +# ifndef IS_IN_rtld +# define TLS_PRE_TCB_SIZE sizeof (struct _pthread_descr_struct) +# else +# include <nptl-struct-pthread.h> +# define TLS_PRE_TCB_SIZE \ + (sizeof (struct _pthread_descr_struct) > NPTL_STRUCT_PTHREAD_SIZE \ + ? sizeof (struct _pthread_descr_struct) : NPTL_STRUCT_PTHREAD_SIZE) +# endif /* Alignment requirements for the TCB. */ # define TLS_TCB_ALIGN __alignof__ (struct _pthread_descr_struct) |