Skip to content

Commit

Permalink
hppa/ia64: _dl_symbol_address: add PLT bypass for rtld
Browse files Browse the repository at this point in the history
This symbol is defined in the ldso, and is used both there and libc.so.
There is no hidden symbol for it though which leads to relocations in
the ldso and the elf/check-localplt test failing.  Add a hidden def for
rtld to fix all of that.

This function/file is only used by hppa & ia64, so no testing is needed
for other arches.
  • Loading branch information
Mike Frysinger committed Jul 16, 2015
1 parent e591758 commit 2a6ad81
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 0 deletions.
7 changes: 7 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
2015-07-16 Mike Frysinger <vapier@gentoo.org>

* elf/dl-symaddr.c (_dl_symbol_address): Add rtld_hidden_def.
* sysdeps/hppa/dl-lookupcfg.h (_dl_symbol_address): Add
rtld_hidden_proto.
* sysdeps/ia64/dl-lookupcfg.h (_dl_symbol_address): Likewise.

2015-07-16 Siddhesh Poyarekar <siddhesh@redhat.com>

* tst-nodelete-opened.c (do_test): Add comment to clarify how
Expand Down
1 change: 1 addition & 0 deletions elf/dl-symaddr.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,4 @@ _dl_symbol_address (struct link_map *map, const ElfW(Sym) *ref)
else
return (void *) value;
}
rtld_hidden_def (_dl_symbol_address)
1 change: 1 addition & 0 deletions sysdeps/hppa/dl-lookupcfg.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
struct link_map;

void *_dl_symbol_address (struct link_map *map, const ElfW(Sym) *ref);
rtld_hidden_proto (_dl_symbol_address)

#define DL_SYMBOL_ADDRESS(map, ref) _dl_symbol_address(map, ref)

Expand Down
1 change: 1 addition & 0 deletions sysdeps/ia64/dl-lookupcfg.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
struct link_map;

extern void *_dl_symbol_address (struct link_map *map, const Elf64_Sym *ref);
rtld_hidden_proto (_dl_symbol_address)

#define DL_SYMBOL_ADDRESS(map, ref) _dl_symbol_address(map, ref)

Expand Down

0 comments on commit 2a6ad81

Please sign in to comment.