diff options
Diffstat (limited to 'bfd/elf32-d10v.c')
-rw-r--r-- | bfd/elf32-d10v.c | 27 |
1 files changed, 5 insertions, 22 deletions
diff --git a/bfd/elf32-d10v.c b/bfd/elf32-d10v.c index f9454ff..6d3b02d 100644 --- a/bfd/elf32-d10v.c +++ b/bfd/elf32-d10v.c @@ -517,28 +517,11 @@ elf32_d10v_relocate_section (output_bfd, info, input_bfd, input_section, } else { - h = sym_hashes[r_symndx - symtab_hdr->sh_info]; - while (h->root.type == bfd_link_hash_indirect - || h->root.type == bfd_link_hash_warning) - h = (struct elf_link_hash_entry *) h->root.u.i.link; - if (h->root.type == bfd_link_hash_defined - || h->root.type == bfd_link_hash_defweak) - { - sec = h->root.u.def.section; - relocation = (h->root.u.def.value - + sec->output_section->vma - + sec->output_offset); - } - else if (h->root.type == bfd_link_hash_undefweak) - relocation = 0; - else - { - if (!((*info->callbacks->undefined_symbol) - (info, h->root.root.string, input_bfd, - input_section, rel->r_offset, TRUE))) - return FALSE; - relocation = 0; - } + bfd_boolean unresolved_reloc, warned; + + RELOC_FOR_GLOBAL_SYMBOL (h, sym_hashes, r_symndx, symtab_hdr, + relocation, sec, unresolved_reloc, + info, warned); } if (h != NULL) |