summaryrefslogtreecommitdiffstats
path: root/cpukit/libdl/rtl-mdreloc-i386.c
diff options
context:
space:
mode:
authorChris Johns <chrisj@rtems.org>2019-05-03 10:15:20 +1000
committerChris Johns <chrisj@rtems.org>2019-05-03 10:15:20 +1000
commitb36c52097f52012f9a52dff6fc8393d63805158b (patch)
tree011b4cb678d343e0e6422d36bbcce982fdf48e30 /cpukit/libdl/rtl-mdreloc-i386.c
parentbsp/motorola_powerpc: Fix debug output (diff)
downloadrtems-b36c52097f52012f9a52dff6fc8393d63805158b.tar.bz2
libdl: Do not access the ELF file while the allocator is locked.
- Load symbols before allocation. - Parse reloc records and place any reloc recs in a cache to use while the allocator is locked. - Relocate symbols after section allocation. - Split section loading into allocation/locating and loading. - Update all arch back-ends with a new reloc interface to control tramp handling. - Add `-a` and `-t` to the object list shell command. Closes #3741
Diffstat (limited to 'cpukit/libdl/rtl-mdreloc-i386.c')
-rw-r--r--cpukit/libdl/rtl-mdreloc-i386.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/cpukit/libdl/rtl-mdreloc-i386.c b/cpukit/libdl/rtl-mdreloc-i386.c
index 576914cf04..40b09d4be2 100644
--- a/cpukit/libdl/rtl-mdreloc-i386.c
+++ b/cpukit/libdl/rtl-mdreloc-i386.c
@@ -73,7 +73,7 @@ rtems_rtl_elf_relocate_tramp_max_size (void)
return 0;
}
-bool
+rtems_rtl_elf_rel_status
rtems_rtl_elf_relocate_rela_tramp (rtems_rtl_obj* obj,
const Elf_Rela* rela,
const rtems_rtl_obj_sect* sect,
@@ -88,10 +88,10 @@ rtems_rtl_elf_relocate_rela_tramp (rtems_rtl_obj* obj,
(void) syminfo;
(void) symvalue;
rtems_rtl_set_error (EINVAL, "rela type record not supported");
- return false;
+ return rtems_rtl_elf_rel_failure;
}
-bool
+rtems_rtl_elf_rel_status
rtems_rtl_elf_relocate_rela (rtems_rtl_obj* obj,
const Elf_Rela* rel,
const rtems_rtl_obj_sect* sect,
@@ -106,10 +106,10 @@ rtems_rtl_elf_relocate_rela (rtems_rtl_obj* obj,
(void) syminfo;
(void) symvalue;
rtems_rtl_set_error (EINVAL, "rela type record not supported");
- return false;
+ return rtems_rtl_elf_rel_failure;
}
-bool
+rtems_rtl_elf_rel_status
rtems_rtl_elf_relocate_rel_tramp (rtems_rtl_obj* obj,
const Elf_Rel* rel,
const rtems_rtl_obj_sect* sect,
@@ -123,10 +123,10 @@ rtems_rtl_elf_relocate_rel_tramp (rtems_rtl_obj* obj,
(void) symname;
(void) syminfo;
(void) symvalue;
- return true;
+ return rtems_rtl_elf_rel_no_error;
}
-bool
+rtems_rtl_elf_rel_status
rtems_rtl_elf_relocate_rel (rtems_rtl_obj* obj,
const Elf_Rel* rel,
const rtems_rtl_obj_sect* sect,
@@ -188,10 +188,10 @@ rtems_rtl_elf_relocate_rel (rtems_rtl_obj* obj,
"%s: Unsupported relocation type %" PRIu32 " "
"in non-PLT relocations",
sect->name, (uint32_t) ELF_R_TYPE(rel->r_info));
- return false;
+ return rtems_rtl_elf_rel_failure;
}
- return true;
+ return rtems_rtl_elf_rel_no_error;
}
bool