diff options
author | Shahab Vahedi <shahab@synopsys.com> | 2022-11-27 18:38:25 +0100 |
---|---|---|
committer | Vineet Gupta <vineet.gupta@linux.dev> | 2022-11-29 14:33:56 -0800 |
commit | 6ae0737d430900fff02569548a92bdca49622a15 (patch) | |
tree | d4a31f9ce9429b57c190f0b9c66d2e94e4d655a2 /sysdeps/arc | |
parent | 987f8647e8d6206cebc613e5c162ff8b4d014d40 (diff) | |
download | glibc-6ae0737d430900fff02569548a92bdca49622a15.tar.gz glibc-6ae0737d430900fff02569548a92bdca49622a15.tar.xz glibc-6ae0737d430900fff02569548a92bdca49622a15.zip |
ARC: update definitions in elf/elf.h
While porting ARCv2 to elfutils [1], it was brought up that the necessary changes to the project's libelf/elf.h must come from glibc, because they sync it from glibc [2]. Therefore, this patch is to update ARC entries in elf/elf.h. The majority of the update is about adding new definitions, specially for the relocations. However, there is one rename, one deletion, and one change: - R_ARC_JUMP_SLOT renamed to R_ARC_JMP_SLOT to match binutils. - R_ARC_B26 removed because it is unused and deprecated. - R_ARC_TLS_DTPOFF_S9 changed from 0x4a to the correct value 0x49. Finally, a specific SHT class for ARC has been added to glibcelf.py. Else, it would result in a collision: _register_elf_h(Sht, ranges=True, File "/src/glibc/scripts/glibcelf.py", line x, in _register_elf_h raise ValueError('duplicate value {}: {}, {}'.format( ValueError: duplicate value 1879048193: SHT_ARC_ATTRIBUTES, SHT_X86_64_UNWIND [1] https://sourceware.org/pipermail/elfutils-devel/2022q4/005530.html [2] https://sourceware.org/pipermail/elfutils-devel/2022q4/005548.html No regression has been observed after applying this patch. Below follows the result: UNSUPPORTED: crypt/cert UNSUPPORTED: elf/tst-audit22 FAIL: elf/tst-audit25a FAIL: elf/tst-audit25b FAIL: elf/tst-bz15311 FAIL: elf/tst-bz28937 FAIL: elf/tst-dlmopen4 UNSUPPORTED: elf/tst-dlopen-self-container UNSUPPORTED: elf/tst-dlopen-tlsmodid-container UNSUPPORTED: elf/tst-glibc-hwcaps-prepend-cache UNSUPPORTED: elf/tst-ldconfig-bad-aux-cache UNSUPPORTED: elf/tst-ldconfig-ld_so_conf-update UNSUPPORTED: elf/tst-pldd UNSUPPORTED: elf/tst-preload-pthread-libc XPASS: elf/tst-protected1a XPASS: elf/tst-protected1b FAIL: elf/tst-tls-allocation-failure-static-patched FAIL: elf/tst-tls1 FAIL: elf/tst-tls3 FAIL: elf/tst-tlsalign-extern UNSUPPORTED: elf/tst-valgrind-smoke UNSUPPORTED: grp/tst-initgroups1 UNSUPPORTED: grp/tst-initgroups2 UNSUPPORTED: io/tst-getcwd-smallbuff UNSUPPORTED: locale/tst-localedef-path-norm FAIL: localedata/sort-test UNSUPPORTED: localedata/tst-localedef-hardlinks FAIL: malloc/tst-malloc-thread-fail-malloc-check FAIL: malloc/tst-malloc_info-malloc-check UNSUPPORTED: math/test-fesetexcept-traps UNSUPPORTED: math/test-fexcept-traps UNSUPPORTED: math/test-nearbyint-except UNSUPPORTED: math/test-nearbyint-except-2 UNSUPPORTED: misc/tst-adjtimex UNSUPPORTED: misc/tst-clock_adjtime FAIL: misc/tst-misalign-clone FAIL: misc/tst-misalign-clone-internal UNSUPPORTED: misc/tst-ntp_adjtime UNSUPPORTED: misc/tst-pkey UNSUPPORTED: misc/tst-rseq UNSUPPORTED: misc/tst-rseq-disable UNSUPPORTED: misc/tst-syslog UNSUPPORTED: misc/tst-ttyname FAIL: nptl/test-cond-printers FAIL: nptl/test-condattr-printers FAIL: nptl/test-mutex-printers FAIL: nptl/test-mutexattr-printers FAIL: nptl/test-rwlock-printers FAIL: nptl/test-rwlockattr-printers UNSUPPORTED: nptl/tst-pthread-gdb-attach UNSUPPORTED: nptl/tst-pthread-gdb-attach-static UNSUPPORTED: nptl/tst-pthread-getattr UNSUPPORTED: nptl/tst-rseq-nptl UNSUPPORTED: nss/tst-nss-compat1 UNSUPPORTED: nss/tst-nss-db-endgrent UNSUPPORTED: nss/tst-nss-db-endpwent UNSUPPORTED: nss/tst-nss-files-hosts-long UNSUPPORTED: nss/tst-nss-gai-actions UNSUPPORTED: nss/tst-nss-test3 UNSUPPORTED: nss/tst-reload1 UNSUPPORTED: nss/tst-reload2 UNSUPPORTED: posix/bug-ga2 UNSUPPORTED: posix/bug-ga2-mem FAIL: posix/globtest UNSUPPORTED: posix/tst-vfork3 UNSUPPORTED: posix/tst-vfork3-mem UNSUPPORTED: resolv/mtrace-tst-leaks2 UNSUPPORTED: resolv/tst-leaks2 UNSUPPORTED: resolv/tst-resolv-ai_idn UNSUPPORTED: resolv/tst-resolv-ai_idn-latin1 UNSUPPORTED: resolv/tst-resolv-res_init UNSUPPORTED: resolv/tst-resolv-res_init-thread UNSUPPORTED: rt/tst-bz28213 UNSUPPORTED: rt/tst-mqueue1 UNSUPPORTED: rt/tst-mqueue10 UNSUPPORTED: rt/tst-mqueue2 UNSUPPORTED: rt/tst-mqueue3 UNSUPPORTED: rt/tst-mqueue4 UNSUPPORTED: rt/tst-mqueue5 UNSUPPORTED: rt/tst-mqueue6 UNSUPPORTED: rt/tst-mqueue8 UNSUPPORTED: rt/tst-mqueue8x UNSUPPORTED: rt/tst-mqueue9 UNSUPPORTED: stdlib/test-bz22786 UNSUPPORTED: stdlib/tst-system UNSUPPORTED: string/test-bcopy UNSUPPORTED: string/test-memmove UNSUPPORTED: string/tst-memmove-overflow UNSUPPORTED: string/tst-strerror UNSUPPORTED: string/tst-strsignal UNSUPPORTED: time/tst-clock_settime UNSUPPORTED: time/tst-settimeofday Summary of test results: 21 FAIL 4184 PASS 69 UNSUPPORTED 16 XFAIL 2 XPASS Signed-off-by: Shahab Vahedi <shahab@synopsys.com> Signed-off-by: Vineet Gupta <vineet.gupta@linux.dev>
Diffstat (limited to 'sysdeps/arc')
-rw-r--r-- | sysdeps/arc/dl-machine.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sysdeps/arc/dl-machine.h b/sysdeps/arc/dl-machine.h index c6ad232384..8420cd0006 100644 --- a/sysdeps/arc/dl-machine.h +++ b/sysdeps/arc/dl-machine.h @@ -183,14 +183,14 @@ __start: \n\ ELF_RTYPE_CLASS_NOCOPY iff TYPE should not be allowed to resolve to one of the main executable's symbols, as for a COPY reloc. */ #define elf_machine_type_class(type) \ - ((((type) == R_ARC_JUMP_SLOT \ + ((((type) == R_ARC_JMP_SLOT \ || (type) == R_ARC_TLS_DTPMOD \ || (type) == R_ARC_TLS_DTPOFF \ || (type) == R_ARC_TLS_TPOFF) * ELF_RTYPE_CLASS_PLT) \ | (((type) == R_ARC_COPY) * ELF_RTYPE_CLASS_COPY)) /* A reloc type used for ld.so cmdline arg lookups to reject PLT entries. */ -#define ELF_MACHINE_JMP_SLOT R_ARC_JUMP_SLOT +#define ELF_MACHINE_JMP_SLOT R_ARC_JMP_SLOT /* Fixup a PLT entry to bounce directly to the function at VALUE. */ @@ -261,7 +261,7 @@ elf_machine_rela (struct link_map *map, struct r_scope_elem *scope[], break; case R_ARC_GLOB_DAT: - case R_ARC_JUMP_SLOT: + case R_ARC_JMP_SLOT: *reloc_addr = value; break; @@ -321,7 +321,7 @@ elf_machine_lazy_rel (struct link_map *map, struct r_scope_elem *scope[], ElfW(Addr) *const reloc_addr = (void *) (l_addr + reloc->r_offset); const unsigned int r_type = ELFW (R_TYPE) (reloc->r_info); - if (r_type == R_ARC_JUMP_SLOT) + if (r_type == R_ARC_JMP_SLOT) *reloc_addr += l_addr; else _dl_reloc_bad_type (map, r_type, 1); |