aboutsummaryrefslogtreecommitdiff
path: root/linuxthreads
diff options
context:
space:
mode:
Diffstat (limited to 'linuxthreads')
-rw-r--r--linuxthreads/ChangeLog7
-rw-r--r--linuxthreads/sysdeps/i386/tls.h10
2 files changed, 14 insertions, 3 deletions
diff --git a/linuxthreads/ChangeLog b/linuxthreads/ChangeLog
index 79a3ccec61..fee9a7a67b 100644
--- a/linuxthreads/ChangeLog
+++ b/linuxthreads/ChangeLog
@@ -1,8 +1,13 @@
+2002-02-12 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/i386/tls.c (INSTALL_NEW_DTV): Define.
+ (INSTALL_DTV): Adjust for being passed pointer to element with length.
+
2002-02-08 Ulrich Drepper <drepper@redhat.com>
* sysdeps/i386/tls.h (TLS_INIT_TP): Also initialize %gs.
-2002-02-08 Richard Henderson <rth@twiddle.net>
+2002-02-08 Richard Henderson <rth@redhat.com>
* sysdeps/alpha/elf/pt-initfini.c: Use \n\ for multiline string.
diff --git a/linuxthreads/sysdeps/i386/tls.h b/linuxthreads/sysdeps/i386/tls.h
index 79e4fde9c7..8e1d4698b0 100644
--- a/linuxthreads/sysdeps/i386/tls.h
+++ b/linuxthreads/sysdeps/i386/tls.h
@@ -67,9 +67,15 @@ typedef struct
# define TLS_TCB_AT_TP 1
-/* Install the dtv pointer. */
+/* Install the dtv pointer. The pointer passed is to the element with
+ index -1 which contain the length. */
# define INSTALL_DTV(descr, dtvp) \
- ((tcbhead_t *) descr)->dtv = dtvp
+ ((tcbhead_t *) descr)->dtv = dtvp + 1
+
+/* Install new dtv for current thread. */
+# define INSTALL_NEW_DTV(dtv) \
+ ({ struct _pthread_descr_struct *__descr; \
+ THREAD_SETMEM (__descr, p_header.data.dtvp, dtv); })
/* Code to initially initialize the thread pointer. This might need
special attention since 'errno' is not yet available and if the