GCC Code Coverage Report


Directory: ./
File: firmware/hw_layer/ports/arm_common.cpp
Date: 2025-10-03 00:57:22
Coverage Exec Excl Total
Lines: 0.0% 0 0 2
Functions: 0.0% 0 0 1
Branches: -% 0 0 0
Decisions: -% 0 - 0

Line Branch Decision Exec Source
1 /**
2 * @file arm_common.cpp
3 * @brief Low level common ARM code
4 *
5 * @date Nov 14, 2023
6 * @author Andrey Belomutskiy, (c) 2012-2023
7 * @author andreika <prometheus.pcb@gmail.com>
8 */
9
10 #include "pch.h"
11
12 #if EFI_PROD_CODE
13 #include "mpu_util.h"
14 #endif /* EFI_PROD_CODE */
15
16 void causeHardFault() {
17 #if EFI_PROD_CODE
18 // Set the function pointer to an invalid address
19 void (*invalidFunction)() = (void(*)())0xDEADBEEF;
20 // Calling the invalid function will trigger a hard fault
21 invalidFunction();
22 #endif /* EFI_PROD_CODE */
23 }
24