ELF: Don't check relocations in non-loaded, non-alloced sections
[deliverable/binutils-gdb.git] / bfd / elf32-lm32.c
index 3c31dd44c853d91a3cb058c4a7d118f40d9dd8e4..aba821ffd1a4245b1dee969b7db50974c776077e 100644 (file)
@@ -1128,15 +1128,6 @@ lm32_elf_check_relocs (bfd *abfd,
   if (bfd_link_relocatable (info))
     return TRUE;
 
-  /* Don't do anything special with non-loaded, non-alloced sections.
-     In particular, any relocs in such sections should not affect GOT
-     and PLT reference counting (ie. we don't allow them to create GOT
-     or PLT entries), there's no possibility or desire to optimize TLS
-     relocs, and there's not much point in propagating relocs to shared
-     libs that the dynamic linker won't relocate.  */
-  if ((sec->flags & SEC_ALLOC) == 0)
-    return TRUE;
-
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
   sym_hashes = elf_sym_hashes (abfd);
   sym_hashes_end = sym_hashes + symtab_hdr->sh_size/sizeof (Elf32_External_Sym);
This page took 0.023618 seconds and 4 git commands to generate.