binutils-gdb/ld/emultempl
Thomas Preud'homme 0955507f6e Add support for stable secure gateway veneers addresses
2016-08-26  Thomas Preud'homme  <thomas.preudhomme@arm.com>

bfd/
	* bfd-in.h (bfd_elf32_arm_set_target_relocs): Add a new parameter for
	the input import library bfd.
	* bfd-in2.h: Regenerate.
	* elf32-arm.c (struct elf32_arm_link_hash_table): New in_implib_bfd
	and new_cmse_stub_offset fields.
	(stub_hash_newfunc): Initialize stub_offset and stub_template_size to
	-1.
	(elf32_arm_add_stub): Likewise for stub_offset.
	(arm_new_stubs_start_offset_ptr): New function.
	(arm_build_one_stub): Only allocate a stub_offset if it is -1.  Allow
	empty SG veneers to have zero relocations.
	(arm_size_one_stub): Only initialize stub size and template
	information for non empty veneers.  Do not update veneer section size
	if veneer already has an offset.
	(elf32_arm_create_stub): Return the stub entry pointer or NULL instead
	of a boolean indicating success or failure.
	(cmse_scan): Change stub_changed parameter into an integer pointer
	parameter cmse_stub_created to count the number of stub created and
	adapt to change of return value in elf32_arm_create_stub.
	(cmse_entry_fct_p): New function.
	(arm_list_new_cmse_stub): Likewise.
	(set_cmse_veneer_addr_from_implib): Likewise.
	(elf32_arm_size_stubs): Define cmse_stub_created, pass its address to
	cmse_scan instead of that of cmse_stub_changed to compute the number
	of stub created and use it to initialize stub_changed.  Call
	set_cmse_veneer_addr_from_implib after all cmse_scan.  Adapt to change
	of return value in elf32_arm_create_stub.  Use
	arm_stub_section_start_offset () if not NULL to initialize size of
	secure gateway veneers section.  Initialize stub_offset of Cortex-A8
	erratum fix to -1.  Use ret to hold return value.
	(elf32_arm_build_stubs): Use arm_stub_section_start_offset () if not
	NULL to initialize size of secure gateway veneers section.  Adapt
	comment to stress the importance of zeroing veneer section content.
	(bfd_elf32_arm_set_target_relocs): Add new in_implib_bfd parameter to
	initialize eponymous field in struct elf32_arm_link_hash_table.

ld/
	* emultempl/armelf.em (in_implib_filename): Declare and initialize new
	variable.
	(arm_elf_create_output_section_statements): Open import input library
	file for writing and pass resulting in_implib_bfd to
	bfd_elf32_arm_set_target_relocs.
	(PARSE_AND_LIST_PROLOGUE): Define OPTION_IN_IMPLIB option.
	(PARSE_AND_LIST_LONGOPTS): Define --in-implib option.
	(PARSE_AND_LIST_OPTIONS): Add help message for --in-implib option.
	(PARSE_AND_LIST_ARGS_CASES): Handle new OPTION_IN_IMPLIB case.
	* ld.texinfo (--cmse-implib): Update to mention --in-implib.
	(--in-implib): Document new option.
	* NEWS: Likewise.
	* testsuite/ld-arm/arm-elf.exp
	(Secure gateway import library generation): add --defsym VER=1 to gas
	CLI.
	(Secure gateway import library generation: errors): Likewise.
	(Input secure gateway import library): New test.
	(Input secure gateway import library: no output import library):
	Likewise.
	(Input secure gateway import library: not an SG input import library):
	Likewise.
	(Input secure gateway import library: earlier stub section base):
	Likewise.
	(Input secure gateway import library: later stub section base):
	Likewise.
	(Input secure gateway import library: veneer comeback): Likewise.
	(Input secure gateway import library: entry function change):
	Likewise.
	* testsuite/ld-arm/cmse-implib.s: Add input import library testing.
	* testsuite/ld-arm/cmse-implib.rd: Update accordingly.
	* testsuite/ld-arm/cmse-new-implib.out: New file.
	* testsuite/ld-arm/cmse-new-implib.rd: Likewise.
	* testsuite/ld-arm/cmse-new-implib-no-output.out: Likewise.
	* testsuite/ld-arm/cmse-new-implib-not-sg-in-implib.out: Likewise.
	* testsuite/ld-arm/cmse-new-earlier-later-implib.out: Likewise.
	* testsuite/ld-arm/cmse-new-comeback-implib.rd: Likewise.
	* testsuite/ld-arm/cmse-new-wrong-implib.out: Likewise.
2016-08-26 11:00:36 +01:00
..
README Copyright update for binutils 2016-01-01 23:00:01 +10:30
aarch64elf.em Enable relro by default for AArch64, ARM and SCORE. 2016-08-19 09:27:52 +01:00
aix.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
alphaelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
arclinux.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
armcoff.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
armelf.em Add support for stable secure gateway veneers addresses 2016-08-26 11:00:36 +01:00
astring.sed
avrelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
beos.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
bfin.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
cr16elf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
crxelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf-generic.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf32.em Add support for creating ELF import libraries 2016-07-15 17:50:48 +01:00
epiphanyelf_4x4.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
genelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
generic.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
gld960.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
gld960c.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
hppaelf.em [HPPA] Attach linker created dynamic sections to stub bfd 2016-05-11 22:51:14 +09:30
ia64elf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
irix.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
linux.em Enable relro by default for AArch64, ARM and SCORE. 2016-08-19 09:27:52 +01:00
lnk960.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
m68hc1xelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
m68kcoff.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
m68kelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
metagelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
mipself.em MIPS/LD: Convert ELF linker emulation option macros to an enum 2016-01-04 23:35:03 +00:00
mmix-elfnmmo.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
mmixelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
mmo.em Speedup mmo and pe orphan placement for relocatable link 2016-03-02 05:07:50 -08:00
msp430.em Remove use of alloca. 2016-03-21 16:31:46 +00:00
nds32elf.em Don't include libbfd.h outside of bfd, part 1 2016-07-16 13:25:11 +09:30
needrelax.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
netbsd.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
nios2elf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
ostring.sed
pe.em Add support for creating ELF import libraries 2016-07-15 17:50:48 +01:00
pep.em Add support for creating ELF import libraries 2016-07-15 17:50:48 +01:00
ppc32elf.em Don't include libbfd.h outside of bfd, part 1 2016-07-16 13:25:11 +09:30
ppc64elf.em Don't include libbfd.h outside of bfd, part 1 2016-07-16 13:25:11 +09:30
rxelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
scoreelf.em Enable relro by default for AArch64, ARM and SCORE. 2016-08-19 09:27:52 +01:00
sh64elf.em Don't include libbfd.h outside of bfd, part 1 2016-07-16 13:25:11 +09:30
solaris2.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
spu_icache.S
spu_icache.o_c Regenerate spu overlay and icache manager files 2014-11-04 22:36:13 +10:30
spu_ovl.S Copyright update for binutils 2016-01-01 23:00:01 +10:30
spu_ovl.o_c Regenerate spu overlay and icache manager files 2014-11-04 22:36:13 +10:30
spuelf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
sunos.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
tic6xdsbt.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
ticoff.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
v850elf.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
vanilla.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
vms.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
vxworks.em Copyright update for binutils 2016-01-01 23:00:01 +10:30
xtensaelf.em Don't include libbfd.h outside of bfd, part 1 2016-07-16 13:25:11 +09:30
z80.em Copyright update for binutils 2016-01-01 23:00:01 +10:30

README

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

The files in this directory are sourced by genscripts.sh, after
setting some variables to substitute in, to produce
C source files that contain jump tables for each emulation.

Copyright (C) 2012-2016 Free Software Foundation, Inc.

Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright
notice and this notice are preserved.