ANDROID: BACKPORT: x86, module: Ignore __typeid__ relocations

Also ignore these relocations when loading modules.

Bug: 145297900
Change-Id: I3d00f93deb3cf370ce25f8672f90e410e87ab79e
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
This commit is contained in:
Sami Tolvanen
2020-01-15 15:29:21 -08:00
committed by Alistair Delva
parent 5ff816cb64
commit 10d14862f3

View File

@@ -201,6 +201,10 @@ int apply_relocate_add(Elf64_Shdr *sechdrs,
goto overflow;
#endif
break;
case R_X86_64_8:
if (!strncmp(strtab + sym->st_name, "__typeid__", 10))
break;
/* fallthrough */
default:
pr_err("%s: Unknown rela relocation: %llu\n",
me->name, ELF64_R_TYPE(rel[i].r_info));