From b34b2d70354518dd3f246a52174f7bde7e3a573a Mon Sep 17 00:00:00 2001 From: Daniel Jacobowitz Date: Tue, 22 Aug 2006 13:18:03 +0000 Subject: [PATCH] * elf32-arm.c (elf32_arm_copy_indirect_symbol): Only copy plt_thumb_refcount from indirect symbols. --- bfd/ChangeLog | 5 +++++ bfd/elf32-arm.c | 18 ++++++++++-------- 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/bfd/ChangeLog b/bfd/ChangeLog index adc0f59e46b..3321856b740 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,8 @@ +2006-08-22 Daniel Jacobowitz + + * elf32-arm.c (elf32_arm_copy_indirect_symbol): Only copy + plt_thumb_refcount from indirect symbols. + 2006-08-22 Alan Modra * elf32-ppc.c (ppc_elf_relocate_section): Correct GOT and PLT HA diff --git a/bfd/elf32-arm.c b/bfd/elf32-arm.c index 8b6278419f3..163114996b0 100644 --- a/bfd/elf32-arm.c +++ b/bfd/elf32-arm.c @@ -2356,15 +2356,17 @@ elf32_arm_copy_indirect_symbol (struct bfd_link_info *info, eind->relocs_copied = NULL; } - /* Copy over PLT info. */ - edir->plt_thumb_refcount += eind->plt_thumb_refcount; - eind->plt_thumb_refcount = 0; - - if (ind->root.type == bfd_link_hash_indirect - && dir->got.refcount <= 0) + if (ind->root.type == bfd_link_hash_indirect) { - edir->tls_type = eind->tls_type; - eind->tls_type = GOT_UNKNOWN; + /* Copy over PLT info. */ + edir->plt_thumb_refcount += eind->plt_thumb_refcount; + eind->plt_thumb_refcount = 0; + + if (dir->got.refcount <= 0) + { + edir->tls_type = eind->tls_type; + eind->tls_type = GOT_UNKNOWN; + } } _bfd_elf_link_hash_copy_indirect (info, dir, ind); -- 2.30.2