]> git.ipfire.org Git - thirdparty/glibc.git/commit
Fix elf/tst-audit2 on hppa
authorJohn David Anglin <danglin@gcc.gnu.org>
Mon, 14 Feb 2022 15:14:49 +0000 (15:14 +0000)
committerJohn David Anglin <danglin@gcc.gnu.org>
Thu, 3 Mar 2022 21:18:21 +0000 (21:18 +0000)
commit1f770811785e6c79db995b0390d1ef4e67e87d44
treebf7bcb4b88e64e01b43706b0db5f0e77b6faa119
parentc60e6a458b8e2efc39c81d372a88d258009eb1b7
Fix elf/tst-audit2 on hppa

The test elf/tst-audit2 fails on hppa with a segmentation fault in the
long branch stub used to call malloc from calloc.  This occurs because
the test is not a PIC executable and calloc is called from the dynamic
linker before the dp register is initialized in _dl_start_user.

The fix is to move the dp register initialization into
elf_machine_runtime_setup.  Since the address of $global$ can't be
loaded directly, we continue to use the DT_PLTGOT value from the
the main_map to initialize dp.

(cherry picked from commit 2e20cd63c96555d650c525ad5633475e8f11bed4)
sysdeps/hppa/dl-machine.h