Lines Matching +full:set +full:- +full:top
1 // SPDX-License-Identifier: GPL-2.0+
3 * Code shared between SPL and U-Boot proper
22 * Allocate reserved space for use as 'globals' from 'top' address and
35 * - GD is aligned down on a 16-byte boundary
37 * - the early malloc arena is not aligned, therefore it follows the stack
40 * - GD is allocated last, so that the return value of this functions is
45 ulong board_init_f_alloc_reserve(ulong top) in board_init_f_alloc_reserve() argument
49 top -= CONFIG_VAL(SYS_MALLOC_F_LEN); in board_init_f_alloc_reserve()
52 top = rounddown(top-sizeof(struct global_data), 16); in board_init_f_alloc_reserve()
54 return top; in board_init_f_alloc_reserve()
64 * to base+size-1 (where 'size' is the value returned by the allocation
71 * the caller will set gd to the lowest reserved location. Therefore, in
80 * - through gd_ptr if before the call to arch_setup_gd();
82 * - through gd once arch_setup_gd() has been called.
84 * Do not use 'gd->' until arch_setup_gd() has been called!
104 * clear GD entirely and set it up. in board_init_f_init_reserve()
105 * Use gd_ptr, as gd may not be properly set yet. in board_init_f_init_reserve()
111 /* set GD unless architecture did it already */ in board_init_f_init_reserve()
115 /* next alloc will be higher by one GD plus 16-byte alignment */ in board_init_f_init_reserve()
120 * Use gd as it is now properly set for all architectures. in board_init_f_init_reserve()
125 gd->malloc_base = base; in board_init_f_init_reserve()
132 * Board-specific Platform code can reimplement show_boot_progress () if needed