aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorManinder Singh <maninder1.s@samsung.com>2015-11-26 13:31:20 +0530
committerMark Hatle <mark.hatle@windriver.com>2016-08-18 09:21:27 -0500
commitbaa4de0d26fb2f9d6c38e3296732db1eb658fabc (patch)
tree1139ad90f6b985f5eabe816ad3c98462ca073f53
parent0c3452db4a025f6f9e9a68b7b7474bc58908135f (diff)
downloadprelink-cross-cross_prelink_aarch64.tar.gz
prelink-cross-cross_prelink_aarch64.tar.bz2
prelink-cross-cross_prelink_aarch64.zip
src/arch-aarch64.c:testsuite failure fixes in aarch64cross_prelink_aarch64
This patch fixes testsuite failure in aarch64 prelink undo section. 2016-03-10 Vaneet Narang <v.narang@samsung.com> Maninder Singh <maninder1.s@samsung.com> * src/arch-aarch64.c: Fix prelink undo error Signed-off-by: Vaneet Narang <v.narang@samsung.com> Signed-off-by: Maninder Singh <maninder1.s@samsung.com> Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-rw-r--r--ChangeLog1
-rw-r--r--src/arch-aarch64.c7
2 files changed, 5 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index ad68dfc..16a152b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,7 @@
Maninder Singh <maninder1.s@samsung.com>
* testuite/reloc2.sh, testsuite/reloc8.sh, testsuite/reloc9.sh,
testsuite/tls3.sh: Fix test suite errors
+ * src/arch-aarch64.c: Fix prelink undo error
2016-03-22 Vaneet Narang <v.narang@samsung.com>
Manjeet Pawar <manjeet.p@samsung.com>
diff --git a/src/arch-aarch64.c b/src/arch-aarch64.c
index 6499c68..3cbfff9 100644
--- a/src/arch-aarch64.c
+++ b/src/arch-aarch64.c
@@ -470,7 +470,9 @@ aarch64_undo_prelink_rela (DSO *dso, GElf_Rela *rela, GElf_Addr relaaddr)
switch (GELF_R_TYPE (rela->r_info))
{
case R_AARCH64_NONE:
+ break;
case R_AARCH64_RELATIVE:
+ write_ne64 (dso, rela->r_offset, 0);
break;
case R_AARCH64_JUMP_SLOT:
sec = addr_to_sec (dso, rela->r_offset);
@@ -487,9 +489,7 @@ aarch64_undo_prelink_rela (DSO *dso, GElf_Rela *rela, GElf_Addr relaaddr)
assert (rela->r_offset >= dso->shdr[sec].sh_addr + 24);
assert (((rela->r_offset - dso->shdr[sec].sh_addr) & 7) == 0);
- write_neclass (dso, rela->r_offset,
- 2 * (rela->r_offset - dso->shdr[sec].sh_addr - 24)
- + data);
+ write_neclass (dso, rela->r_offset, data);
}
break;
case R_AARCH64_GLOB_DAT:
@@ -501,6 +501,7 @@ aarch64_undo_prelink_rela (DSO *dso, GElf_Rela *rela, GElf_Addr relaaddr)
write_ne64 (dso, rela->r_offset, 0);
break;
case R_AARCH64_TLS_TPREL:
+ write_ne64 (dso, rela->r_offset, 0);
break;
case R_AARCH64_TLSDESC:
write_ne64 (dso, rela->r_offset, 0);