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#if !ERROR_DEPRECATED 12 .weak plat_crash_console_init 13 .weak plat_crash_console_putc 14 .weak plat_crash_console_flush 15#endif 16 .weak plat_reset_handler 17 .weak plat_disable_acp 18 .weak bl1_plat_prepare_exit 19 .weak platform_mem_init 20 .weak plat_panic_handler 21 22 /* ----------------------------------------------------- 23 * Placeholder function which should be redefined by 24 * each platform. 25 * ----------------------------------------------------- 26 */ 27func plat_report_exception 28 bx lr 29endfunc plat_report_exception 30 31#if !ERROR_DEPRECATED 32 /* ----------------------------------------------------- 33 * Placeholder function which should be redefined by 34 * each platform. 35 * ----------------------------------------------------- 36 */ 37func plat_crash_console_init 38 mov r0, #0 39 bx lr 40endfunc plat_crash_console_init 41 42 /* ----------------------------------------------------- 43 * Placeholder function which should be redefined by 44 * each platform. 45 * ----------------------------------------------------- 46 */ 47func plat_crash_console_putc 48 bx lr 49endfunc plat_crash_console_putc 50 51 /* ----------------------------------------------------- 52 * Placeholder function which should be redefined by 53 * each platform. 54 * ----------------------------------------------------- 55 */ 56func plat_crash_console_flush 57 mov r0, #0 58 bx lr 59endfunc plat_crash_console_flush 60#endif 61 62 /* ----------------------------------------------------- 63 * Placeholder function which should be redefined by 64 * each platform. 65 * ----------------------------------------------------- 66 */ 67func plat_reset_handler 68 bx lr 69endfunc plat_reset_handler 70 71 /* ----------------------------------------------------- 72 * Placeholder function which should be redefined by 73 * each platform. 74 * ----------------------------------------------------- 75 */ 76func plat_disable_acp 77 bx lr 78endfunc plat_disable_acp 79 80 /* --------------------------------------------------------------------- 81 * Placeholder function which should be redefined by 82 * each platform. 83 * --------------------------------------------------------------------- 84 */ 85func platform_mem_init 86 bx lr 87endfunc platform_mem_init 88 89 /* ----------------------------------------------------- 90 * void bl1_plat_prepare_exit(entry_point_info_t *ep_info); 91 * Called before exiting BL1. Default: do nothing 92 * ----------------------------------------------------- 93 */ 94func bl1_plat_prepare_exit 95 bx lr 96endfunc bl1_plat_prepare_exit 97 98 /* ----------------------------------------------------- 99 * void plat_panic_handler(void) __dead2; 100 * Endless loop by default. 101 * ----------------------------------------------------- 102 */ 103func plat_panic_handler 104 b plat_panic_handler 105endfunc plat_panic_handler 106