diff options
-rw-r--r-- | scripts/mod/modpost.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c index a7360c379cba..eeaf57476820 100644 --- a/scripts/mod/modpost.c +++ b/scripts/mod/modpost.c | |||
@@ -576,11 +576,11 @@ static void check_sec_ref(struct module *mod, const char *modname, | |||
576 | r.r_offset = TO_NATIVE(rela->r_offset); | 576 | r.r_offset = TO_NATIVE(rela->r_offset); |
577 | r.r_info = TO_NATIVE(rela->r_info); | 577 | r.r_info = TO_NATIVE(rela->r_info); |
578 | sym = elf->symtab_start + ELF_R_SYM(r.r_info); | 578 | sym = elf->symtab_start + ELF_R_SYM(r.r_info); |
579 | secname = secstrings + sechdrs[sym->st_shndx].sh_name; | ||
580 | /* Skip special sections */ | 579 | /* Skip special sections */ |
581 | if (sym->st_shndx >= SHN_LORESERVE) | 580 | if (sym->st_shndx >= SHN_LORESERVE) |
582 | continue; | 581 | continue; |
583 | 582 | ||
583 | secname = secstrings + sechdrs[sym->st_shndx].sh_name; | ||
584 | if (section(secname)) | 584 | if (section(secname)) |
585 | warn_sec_mismatch(modname, name, elf, sym, r); | 585 | warn_sec_mismatch(modname, name, elf, sym, r); |
586 | } | 586 | } |