xref: /rk3399_ARM-atf/plat/common/aarch32/platform_helpers.S (revision ff2743e544f0f82381ebb9dff8f14eacb837d2e0)
1/*
2 * Copyright (c) 2016-2018, ARM Limited and Contributors. All rights reserved.
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
7#include <arch.h>
8#include <asm_macros.S>
9
10	.weak	plat_report_exception
11	.weak	plat_crash_console_init
12	.weak	plat_crash_console_putc
13	.weak	plat_crash_console_flush
14	.weak	plat_reset_handler
15	.weak	plat_disable_acp
16	.weak	bl1_plat_prepare_exit
17	.weak	platform_mem_init
18	.weak	plat_panic_handler
19
20	/* -----------------------------------------------------
21	 * Placeholder function which should be redefined by
22	 * each platform.
23	 * -----------------------------------------------------
24	 */
25func plat_report_exception
26	bx	lr
27endfunc plat_report_exception
28
29	/* -----------------------------------------------------
30	 * Placeholder function which should be redefined by
31	 * each platform.
32	 * -----------------------------------------------------
33	 */
34func plat_crash_console_init
35	mov	r0, #0
36	bx	lr
37endfunc plat_crash_console_init
38
39	/* -----------------------------------------------------
40	 * Placeholder function which should be redefined by
41	 * each platform.
42	 * -----------------------------------------------------
43	 */
44func plat_crash_console_putc
45	bx	lr
46endfunc plat_crash_console_putc
47
48	/* -----------------------------------------------------
49	 * Placeholder function which should be redefined by
50	 * each platform.
51	 * -----------------------------------------------------
52	 */
53func plat_crash_console_flush
54	mov	r0, #0
55	bx	lr
56endfunc plat_crash_console_flush
57
58	/* -----------------------------------------------------
59	 * Placeholder function which should be redefined by
60	 * each platform.
61	 * -----------------------------------------------------
62	 */
63func plat_reset_handler
64	bx	lr
65endfunc plat_reset_handler
66
67	/* -----------------------------------------------------
68	 * Placeholder function which should be redefined by
69	 * each platform.
70	 * -----------------------------------------------------
71	 */
72func plat_disable_acp
73	bx	lr
74endfunc plat_disable_acp
75
76	/* ---------------------------------------------------------------------
77	 * Placeholder function which should be redefined by
78	 * each platform.
79	 * ---------------------------------------------------------------------
80	 */
81func platform_mem_init
82	bx	lr
83endfunc platform_mem_init
84
85	/* -----------------------------------------------------
86	 * void bl1_plat_prepare_exit(entry_point_info_t *ep_info);
87	 * Called before exiting BL1. Default: do nothing
88	 * -----------------------------------------------------
89	 */
90func bl1_plat_prepare_exit
91	bx	lr
92endfunc bl1_plat_prepare_exit
93
94	/* -----------------------------------------------------
95	 * void plat_panic_handler(void) __dead2;
96	 * Endless loop by default.
97	 * -----------------------------------------------------
98	 */
99func plat_panic_handler
100	b	plat_panic_handler
101endfunc plat_panic_handler
102