glibc/sysdeps/s390
Stefan Liebler dd8f8da99d S390: Use DT_JUMPREL in prelink undo code.
On s390, the current prelink undo code in elf_machine_lazy_rel()
has the requirement, that the plt stubs use the first got slots
after the 3 reserved ones.

In case of undoing prelink, the plt got slots are reset to the correct
addresses whithin the corresponding plt-stub. Therefore the address
is calculated by the address of the first plt-stub-address which
was written by prelink (see l->l_mach.plt) to got[1] and index of
current relocation multiplied with 32 (=size of one plt slot).
The index was calculated with &current-got-slot - &got[3].

This patch removes the requirement, that the plt-got-slots are
starting at got[3]. The index is now calculated with
&current-reloc - &reloc[0]. The first struct Elf64_Rela is stored
at DT_JMPREL.

This patch is needed to prepare for partial relro support.

Ulrich Weigand suggested this approach to use DT_JMPREL - Thanks.

ChangeLog:

	* sysdeps/s390/linkmap.h (struct link_map_machine):
	Remove member gotplt and add member jmprel.
	* sysdeps/s390/s390-32/dl-machine.h
	(elf_machine_runtime_setup): Setup member jmprel with DT_JMPREL
	instead of gotplt with &got[3].
	(elf_machine_lazy_rel): Calculate address with reloc and jmprel.
	* sysdeps/s390/s390-64/dl-machine.h: Likewise.
2016-07-06 15:22:35 +02:00
..
bits S390: Extend structs La_s390_regs / La_s390_retval with vector-registers. 2016-03-31 17:37:16 +02:00
fpu S390: Regenerate ULPs 2016-01-19 10:02:44 +01:00
multiarch S390: Optimize builtin iconv-modules. 2016-05-25 17:18:04 +02:00
nptl elf: Consolidate machine-agnostic DTV definitions in <dl-dtv.h> 2016-06-20 14:31:40 +02:00
s390-32 S390: Use DT_JUMPREL in prelink undo code. 2016-07-06 15:22:35 +02:00
s390-64 S390: Use DT_JUMPREL in prelink undo code. 2016-07-06 15:22:35 +02:00
abort-instr.h S390: Use __asm__ instead of asm. 2015-11-20 08:56:40 +01:00
asm-syntax.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
atomic-machine.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
configure S390: Configure check for vector support in gcc. 2016-05-25 17:18:04 +02:00
configure.ac S390: Configure check for vector support in gcc. 2016-05-25 17:18:04 +02:00
dl-irel.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
dl-procinfo.c Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
dl-procinfo.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
dl-tls.h elf: Consolidate machine-agnostic DTV definitions in <dl-dtv.h> 2016-06-20 14:31:40 +02:00
ffs.c Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
fix-fp-int-convert-overflow.h S/390: Do not raise inexact exception in lrint/lround. [BZ #19486] 2016-01-18 12:48:06 +01:00
gccframe.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
gconv-modules S390: Get rid of make warning: overriding recipe for target gconv-modules. 2016-05-25 17:18:04 +02:00
gmp-mparam.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
Implies * math/divtc3.c: New file. 2006-02-01 03:02:06 +00:00
iso-8859-1_cp037_z900.c S390: Use s390-64 specific ionv-modules on s390-32, too. 2016-05-25 17:18:05 +02:00
jmpbuf-offsets.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
jmpbuf-unwind.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
ldsodefs.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
libc-tls.c Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
linkmap.h S390: Use DT_JUMPREL in prelink undo code. 2016-07-06 15:22:35 +02:00
longjmp.c Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
machine-gmon.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
Makefile S390: Use s390-64 specific ionv-modules on s390-32, too. 2016-05-25 17:18:05 +02:00
mempcpy.S S390: Implement mempcpy with help of memcpy. [BZ #19765] 2016-05-24 10:39:13 +02:00
memusage.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
preconfigure Move base_machine and machine settings from configure.ac to sysdeps preconfigure fragments. 2014-06-25 17:52:56 +00:00
sotruss-lib.c Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
stackinfo.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
string_private.h Add _STRING_INLINE_unaligned and string_private.h 2016-02-18 14:55:29 -02:00
utf8-utf16-z9.c S390: Use s390-64 specific ionv-modules on s390-32, too. 2016-05-25 17:18:05 +02:00
utf8-utf32-z9.c S390: Fix utf32 to utf8 handling of low surrogates (disable cu41). 2016-05-25 17:18:05 +02:00
utf16-utf32-z9.c S390: Fix utf32 to utf16 handling of low surrogates (disable cu42). 2016-05-25 17:18:06 +02:00
Versions S/390: Revert the jmp_buf/ucontext_t ABI change. 2014-07-31 20:04:54 +02:00