1 /* SPDX-License-Identifier: GPL-2.0+ */ 2 /* 3 * (C) Copyright 2011 4 * Graeme Russ, <graeme.russ@gmail.com> 5 */ 6 7 #ifndef _RELOCATE_H_ 8 #define _RELOCATE_H_ 9 10 #include <common.h> 11 12 /** 13 * copy_uboot_to_ram() - Copy U-Boot to its new relocated position 14 * 15 * @return 0 if OK, -ve on error 16 */ 17 int copy_uboot_to_ram(void); 18 19 /** 20 * clear_bss() - Clear the BSS (Blocked Start by Symbol) segment 21 * 22 * This clears the memory used by global variables 23 * 24 * @return 0 if OK, -ve on error 25 */ 26 int clear_bss(void); 27 28 /** 29 * do_elf_reloc_fixups() - Fix up ELF relocations in the relocated code 30 * 31 * This processes the relocation tables to ensure that the code can run in its 32 * new location. 33 * 34 * @return 0 if OK, -ve on error 35 */ 36 int do_elf_reloc_fixups(void); 37 38 #endif /* _RELOCATE_H_ */ 39