+2013-05-07 Will Newton <will.newton@linaro.org>
+
+ * elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Add a
+ plt_header_size argument for ports where it differs from
+ plt_entry_size.
+ * elf-bfd.h: Likewise.
+ * elf32-i386.c: Pass plt_header_size to
+ _bfd_elf_allocate_ifunc_dyn_relocs.
+ * elf64-x86-64.c: Likewise.
+
2013-05-07 Will Newton <will.newton@linaro.org>
* elf-ifunc.c (_bfd_elf_create_ifunc_dyn_reloc): Remove unused
(bfd *, struct bfd_link_info *);
extern bfd_boolean _bfd_elf_allocate_ifunc_dyn_relocs
(struct bfd_link_info *, struct elf_link_hash_entry *,
- struct elf_dyn_relocs **, unsigned int, unsigned int);
+ struct elf_dyn_relocs **, unsigned int, unsigned int, unsigned int);
extern void elf_append_rela (bfd *, asection *, Elf_Internal_Rela *);
extern void elf_append_rel (bfd *, asection *, Elf_Internal_Rela *);
struct elf_link_hash_entry *h,
struct elf_dyn_relocs **head,
unsigned int plt_entry_size,
+ unsigned int plt_header_size,
unsigned int got_entry_size)
{
asection *plt, *gotplt, *relplt;
/* If this is the first .plt entry, make room for the special
first entry. */
if (plt->size == 0)
- plt->size += plt_entry_size;
+ plt->size += plt_header_size;
}
else
{
if (h->type == STT_GNU_IFUNC
&& h->def_regular)
return _bfd_elf_allocate_ifunc_dyn_relocs (info, h, &eh->dyn_relocs,
- plt_entry_size, 4);
+ plt_entry_size,
+ plt_entry_size, 4);
else if (htab->elf.dynamic_sections_created
&& h->plt.refcount > 0)
{
return _bfd_elf_allocate_ifunc_dyn_relocs (info, h,
&eh->dyn_relocs,
plt_entry_size,
+ plt_entry_size,
GOT_ENTRY_SIZE);
else if (htab->elf.dynamic_sections_created
&& h->plt.refcount > 0)