Skip to content
Commit 65c141eb authored by Patrick Delaunay's avatar Patrick Delaunay Committed by Tom Rini
Browse files

board_f.c: Ensure 16 alignment of start_addr_sp and reserved memory

Add a function reserve_stack_aligned() to reserved memory with 16 bits
alignment after the stack pointer (gd->start_addr_sp) and use this new
function in board_f.c to reserve all the memory area (malloc, board, gd,
fdt, bootstage, stacks).

This 16 byte alignment is needed for cast on struct pointer
for the reserved memory, for example:
+ x86_64 ABI: https://reviews.llvm.org/D30049

: 16 bytes
+ ARMv8 Instruction Set Overview: quad word, 16 bytes

An other alignment value could be needed for other architecture.

Signed-off-by: default avatarPatrick Delaunay <patrick.delaunay@st.com>
Acked-by: default avatarStephen Warren <swarren@nvidia.com>
parent 6de29923
Loading
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment