diff options
Diffstat (limited to 'scripts/mod/modpost.c')
-rw-r--r-- | scripts/mod/modpost.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c index 3318692e4e76..f6127b9f5aca 100644 --- a/scripts/mod/modpost.c +++ b/scripts/mod/modpost.c | |||
@@ -503,6 +503,11 @@ static int ignore_undef_symbol(struct elf_info *info, const char *symname) | |||
503 | strncmp(symname, "_rest32gpr_", sizeof("_rest32gpr_") - 1) == 0 || | 503 | strncmp(symname, "_rest32gpr_", sizeof("_rest32gpr_") - 1) == 0 || |
504 | strncmp(symname, "_save32gpr_", sizeof("_save32gpr_") - 1) == 0) | 504 | strncmp(symname, "_save32gpr_", sizeof("_save32gpr_") - 1) == 0) |
505 | return 1; | 505 | return 1; |
506 | if (info->hdr->e_machine == EM_PPC64) | ||
507 | /* Special register function linked on all modules during final link of .ko */ | ||
508 | if (strncmp(symname, "_restgpr0_", sizeof("_restgpr0_") - 1) == 0 || | ||
509 | strncmp(symname, "_savegpr0_", sizeof("_savegpr0_") - 1) == 0) | ||
510 | return 1; | ||
506 | /* Do not ignore this symbol */ | 511 | /* Do not ignore this symbol */ |
507 | return 0; | 512 | return 0; |
508 | } | 513 | } |
@@ -1342,7 +1347,7 @@ static unsigned int *reloc_location(struct elf_info *elf, | |||
1342 | int section = sechdr->sh_info; | 1347 | int section = sechdr->sh_info; |
1343 | 1348 | ||
1344 | return (void *)elf->hdr + sechdrs[section].sh_offset + | 1349 | return (void *)elf->hdr + sechdrs[section].sh_offset + |
1345 | (r->r_offset - sechdrs[section].sh_addr); | 1350 | r->r_offset - sechdrs[section].sh_addr; |
1346 | } | 1351 | } |
1347 | 1352 | ||
1348 | static int addend_386_rel(struct elf_info *elf, Elf_Shdr *sechdr, Elf_Rela *r) | 1353 | static int addend_386_rel(struct elf_info *elf, Elf_Shdr *sechdr, Elf_Rela *r) |