summaryrefslogtreecommitdiffstats
path: root/libexec
diff options
context:
space:
mode:
authoremaste <emaste@FreeBSD.org>2013-10-02 02:32:58 +0000
committeremaste <emaste@FreeBSD.org>2013-10-02 02:32:58 +0000
commit207f0bc65b61314e16bda2204698184acf1c205b (patch)
tree5adebf40bc0637b803c1e9d721a1b0974a6ec4d7 /libexec
parent7d2bbf6ce3e622de950a7a311d409183a426b893 (diff)
downloadFreeBSD-src-207f0bc65b61314e16bda2204698184acf1c205b.zip
FreeBSD-src-207f0bc65b61314e16bda2204698184acf1c205b.tar.gz
Populate .rld_map on MIPS for debuggers
On MIPS the .dynamic section is read-only, so the pointer to rtld information for debuggers cannot be stored there (in DT_DEBUG). Instead, a special section .rld_map is used. Sponsored by: DARPA, AFRL Approved by: re (delphij)
Diffstat (limited to 'libexec')
-rw-r--r--libexec/rtld-elf/rtld.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/libexec/rtld-elf/rtld.c b/libexec/rtld-elf/rtld.c
index cd18bad..f690d75 100644
--- a/libexec/rtld-elf/rtld.c
+++ b/libexec/rtld-elf/rtld.c
@@ -1111,11 +1111,7 @@ digest_dynamic1(Obj_Entry *obj, int early, const Elf_Dyn **dyn_rpath,
break;
case DT_MIPS_RLD_MAP:
-#ifdef notyet
- if (!early)
- dbg("Filling in DT_DEBUG entry");
- ((Elf_Dyn*)dynp)->d_un.d_ptr = (Elf_Addr) &r_debug;
-#endif
+ *((Elf_Addr *)(dynp->d_un.d_ptr)) = (Elf_Addr) &r_debug;
break;
#endif
OpenPOWER on IntegriCloud