aa65f4f338f9b2cb2b47725e1a1a463dc63cd085
2 * Copyright (c) 2015-2018, ARM Limited and Contributors. All rights reserved.
4 * SPDX-License-Identifier: BSD-3-Clause
7 #include <arch_helpers.h>
13 #include <platform_def.h>
15 #include <v2m_flash.h>
17 #pragma weak plat_arm_error_handler
20 * ARM common implementation for error handler
22 void __dead2
plat_arm_error_handler(int err
)
29 /* Image load or authentication error. Erase the ToC */
30 INFO("Erasing FIP ToC from flash...\n");
31 (void)nor_unlock(PLAT_ARM_FIP_BASE
);
32 ret
= nor_word_program(PLAT_ARM_FIP_BASE
, 0);
34 ERROR("Cannot erase ToC\n");
40 /* Unexpected error */
44 (void)console_flush();
46 /* Loop until the watchdog resets the system */
51 void __dead2
plat_error_handler(int err
)
53 plat_arm_error_handler(err
);