Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/libexec/ld.elf_so/arch/hppa Another TLS reloc. Thanks to joe...
details: https://anonhg.NetBSD.org/src/rev/b35b8f2d84c7
branches: trunk
changeset: 763358:b35b8f2d84c7
user: skrll <skrll%NetBSD.org@localhost>
date: Thu Mar 17 22:07:52 2011 +0000
description:
Another TLS reloc. Thanks to joerg for a hint.
diffstat:
libexec/ld.elf_so/arch/hppa/hppa_reloc.c | 20 ++++++++++++++++++--
1 files changed, 18 insertions(+), 2 deletions(-)
diffs (41 lines):
diff -r bffff93bb4e0 -r b35b8f2d84c7 libexec/ld.elf_so/arch/hppa/hppa_reloc.c
--- a/libexec/ld.elf_so/arch/hppa/hppa_reloc.c Thu Mar 17 19:48:37 2011 +0000
+++ b/libexec/ld.elf_so/arch/hppa/hppa_reloc.c Thu Mar 17 22:07:52 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: hppa_reloc.c,v 1.37 2011/03/14 08:49:29 skrll Exp $ */
+/* $NetBSD: hppa_reloc.c,v 1.38 2011/03/17 22:07:52 skrll Exp $ */
/*-
* Copyright (c) 2002, 2004 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: hppa_reloc.c,v 1.37 2011/03/14 08:49:29 skrll Exp $");
+__RCSID("$NetBSD: hppa_reloc.c,v 1.38 2011/03/17 22:07:52 skrll Exp $");
#endif /* not lint */
#include <stdlib.h>
@@ -473,6 +473,22 @@
rdbg(("COPY (avoid in main)"));
break;
+ case R_TYPE(TLS_TPREL32):
+ def = _rtld_find_symdef(symnum, obj, &defobj, false);
+ if (def == NULL)
+ return -1;
+
+ if (!defobj->tls_done && _rtld_tls_offset_allocate(obj))
+ return -1;
+
+ *where = (Elf_Addr)(obj->tlsoffset + def->st_value +
+ rela->r_addend + sizeof(struct tls_tcb));
+
+ rdbg(("TPREL32 %s in %s --> %p in %s",
+ obj->strtab + obj->symtab[symnum].st_name,
+ obj->path, (void *)*where, defobj->path));
+ break;
+
case R_TYPE(TLS_DTPMOD32):
def = _rtld_find_symdef(symnum, obj, &defobj, false);
if (def == NULL)
Home |
Main Index |
Thread Index |
Old Index