blob: 563da4f8e367a28dc8298abb6ffc42ae22070a54 [file] [log] [blame]
Soby Mathewb4c6df42022-11-09 11:13:29 +00001/*
2 * SPDX-License-Identifier: BSD-3-Clause
3 * SPDX-FileCopyrightText: Copyright TF-RMM Contributors.
4 */
5
6#include <arch_helpers.h>
7#include <assert.h>
8#include <debug.h>
9
10void __assert(const char *file, int line, const char *expression)
11{
12 ERROR("Assertion \"%s\" failed %s:%d\n", expression, file, line);
13 while (true) {
14 wfe();
15 }
16}
17
18void __assert_func(const char *file, int line, const char *func, const char *expression)
19{
20 ERROR("Assertion \"%s\" failed %s:%d, %s\n", expression, file, line, func);
21 while (true) {
22 wfe();
23 }
24}
25
26