Skip to content
This repository has been archived by the owner on Jan 24, 2022. It is now read-only.

Commit

Permalink
Add a section to place the veneers in memory
Browse files Browse the repository at this point in the history
The veneers are for now only generated by the Arm GNU linker when it
spots an entry function (one that was decorated with the
cmse_nonsecure_entry attribute).
Adding this section will allow to configure the SAU to make this section
Non-Secure Callable.

Signed-off-by: Hugues de Valon <[email protected]>
  • Loading branch information
hug-dev committed Oct 1, 2020
1 parent 046c8f5 commit 65e5158
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions link.x.in
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,15 @@ SECTIONS
. = ALIGN(4); /* Ensure __erodata is aligned if something unaligned is inserted after .rodata */
__erodata = .;

/* ### .gnu.sgstubs
This section contains the TrustZone-M veneers put there by the Arm GNU linker. */
.gnu.sgstubs : ALIGN(32)
{
__veneer_base = .;
*(.gnu.sgstubs*)
__veneer_limit = .;
} > FLASH

/* ## Sections in RAM */
/* ### .data */
.data : ALIGN(4)
Expand Down

0 comments on commit 65e5158

Please sign in to comment.