From c075c18537d18ccb6760ba1f5727ce2c0890285a Mon Sep 17 00:00:00 2001 From: Pavel Chupin Date: Wed, 16 Oct 2013 19:13:58 +0400 Subject: [PATCH] x86_64: Add R_X86_64_64 relocation handling Change-Id: I86ffc56fa6a9053bed44e92a579530c2beb8eb2c Signed-off-by: Pavel Chupin --- linker/linker.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/linker/linker.cpp b/linker/linker.cpp index d08bf75d6..196acb6d5 100755 --- a/linker/linker.cpp +++ b/linker/linker.cpp @@ -947,6 +947,14 @@ static int soinfo_relocate_a(soinfo* si, Elf_Rela* rela, unsigned count, soinfo* *reinterpret_cast(reloc) = sym_addr + rela->r_addend; break; + case R_X86_64_64: + count_relocation(kRelocRelative); + MARK(rela->r_offset); + TRACE_TYPE(RELO, "RELO R_X86_64_64 %08zx <- +%08zx %s", static_cast(reloc), + static_cast(sym_addr), sym_name); + *reinterpret_cast(reloc) = sym_addr + rela->r_addend; + break; + case R_X86_64_PC32: count_relocation(kRelocRelative); MARK(rela->r_offset);