This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug dynamic-link/19178] ELF_RTYPE_CLASS_EXTERN_PROTECTED_DATA confuses prelink


https://sourceware.org/bugzilla/show_bug.cgi?id=19178

--- Comment #7 from Mark Hatle <mark.hatle at windriver dot com> ---
I think the logic in the patch isn't quite right.

        {
          if (__glibc_unlikely (ELFW(ST_TYPE) (value->s->st_info)
                                == STT_TLS))
-           type_class = 4;
+           type_class = (RTYPE_CLASS_TLS & ~RTYPE_CLASS_VALID);
          else if (__glibc_unlikely (ELFW(ST_TYPE) (value->s->st_info)
                                     == STT_GNU_IFUNC))
-           type_class |= 8;
+           {
+             type_class |= RTYPE_CLASS_VALID;
+           }
+         /* Clear the ELF_RTYPE_CLASS_EXTERN_PROTECTED_DATA bit since
+            it isn't used by prelink.  */
+         type_class &=
~ELF_RTYPE_CLASS_EXTERN_PROTECTED_DATA(undef_map->machine);
        }

With this change, I was able to verify that the ld.so results from 2.21 and
2.22 are producing the same values for me now.

Otherwise, most of the previous '0' values have been replaced with '4'.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]