1 /* SPDX-License-Identifier: GPL-2.0+ */
4 #include <linux/linkage.h>
6 ENTRY(save_boot_params)
7 stmfd sp!, {r0 - r12, lr} /* @ save registers on stack */
8 ldr r12, =CONFIG_SPL_BOOTROM_SAVE
10 b save_boot_params_ret
11 ENDPROC(save_boot_params)
13 ENTRY(return_to_bootrom)
14 ldr r12, =CONFIG_SPL_BOOTROM_SAVE
16 mov r0, #0x0 /* @ return value: 0x0 NO_ERR */
17 ldmfd sp!, {r0 - r12, pc} /* @ restore regs and return */
18 ENDPROC(return_to_bootrom)
21 * cache_inv - invalidate Cache line
25 .type cache_inv, %function
30 mcr p15, 0, r0, c7, c6, 1
37 * flush_l1_v6 - l1 cache clean invalidate
41 .type flush_l1_v6, %function
46 mcr p15, 0, r0, c7, c10, 5 /* @ data memory barrier */
47 mcr p15, 0, r0, c7, c14, 1 /* @ clean & invalidate D line */
48 mcr p15, 0, r0, c7, c10, 4 /* @ data sync barrier */
55 * flush_l1_v7 - l1 cache clean invalidate
59 .type flush_l1_v7, %function
64 dmb /* @data memory barrier */
65 mcr p15, 0, r0, c7, c14, 1 /* @ clean & invalidate D line */
66 dsb /* @data sync barrier */