PR23123, PowerPC32 ifunc regression
[external/binutils.git] / bfd / elf64-ppc.c
index 9009768..09377d1 100644 (file)
@@ -7304,8 +7304,8 @@ ppc64_elf_adjust_dynamic_symbol (struct bfd_link_info *info,
              if (!readonly_dynrelocs (h))
                {
                  h->pointer_equality_needed = 0;
-                 /* If we haven't seen a branch reloc then we don't need
-                    a plt entry.  */
+                 /* If we haven't seen a branch reloc and the symbol
+                    isn't an ifunc then we don't need a plt entry.  */
                  if (!h->needs_plt)
                    h->plt.plist = NULL;
                }
@@ -7321,8 +7321,8 @@ ppc64_elf_adjust_dynamic_symbol (struct bfd_link_info *info,
       else if (!h->needs_plt
               && !readonly_dynrelocs (h))
        {
-         /* If we haven't seen a branch reloc then we don't need a
-            plt entry.  */
+         /* If we haven't seen a branch reloc and the symbol isn't an
+            ifunc then we don't need a plt entry.  */
          h->plt.plist = NULL;
          h->pointer_equality_needed = 0;
          return TRUE;