|
52 | 52 | extern "C" {
|
53 | 53 | #endif
|
54 | 54 |
|
| 55 | +#ifndef _ASMLANGUAGE |
| 56 | + |
| 57 | +#include <zephyr/fatal_types.h> |
| 58 | + |
| 59 | +enum k_fatal_error_reason_arch { |
| 60 | + /* Cortex-M MEMFAULT exceptions */ |
| 61 | + K_ERR_ARM_MEM_GENERIC = K_ERR_ARCH_START, |
| 62 | + K_ERR_ARM_MEM_STACKING, |
| 63 | + K_ERR_ARM_MEM_UNSTACKING, |
| 64 | + K_ERR_ARM_MEM_DATA_ACCESS, |
| 65 | + K_ERR_ARM_MEM_INSTRUCTION_ACCESS, |
| 66 | + K_ERR_ARM_MEM_FP_LAZY_STATE_PRESERVATION, |
| 67 | + |
| 68 | + /* Cortex-M BUSFAULT exceptions */ |
| 69 | + K_ERR_ARM_BUS_GENERIC, |
| 70 | + K_ERR_ARM_BUS_STACKING, |
| 71 | + K_ERR_ARM_BUS_UNSTACKING, |
| 72 | + K_ERR_ARM_BUS_PRECISE_DATA_BUS, |
| 73 | + K_ERR_ARM_BUS_IMPRECISE_DATA_BUS, |
| 74 | + K_ERR_ARM_BUS_INSTRUCTION_BUS, |
| 75 | + K_ERR_ARM_BUS_FP_LAZY_STATE_PRESERVATION, |
| 76 | + |
| 77 | + /* Cortex-M USAGEFAULT exceptions */ |
| 78 | + K_ERR_ARM_USAGE_GENERIC, |
| 79 | + K_ERR_ARM_USAGE_DIV_0, |
| 80 | + K_ERR_ARM_USAGE_UNALIGNED_ACCESS, |
| 81 | + K_ERR_ARM_USAGE_STACK_OVERFLOW, |
| 82 | + K_ERR_ARM_USAGE_NO_COPROCESSOR, |
| 83 | + K_ERR_ARM_USAGE_ILLEGAL_EXC_RETURN, |
| 84 | + K_ERR_ARM_USAGE_ILLEGAL_EPSR, |
| 85 | + K_ERR_ARM_USAGE_UNDEFINED_INSTRUCTION, |
| 86 | + |
| 87 | + /* Cortex-M SECURE exceptions */ |
| 88 | + K_ERR_ARM_SECURE_GENERIC, |
| 89 | + K_ERR_ARM_SECURE_ENTRY_POINT, |
| 90 | + K_ERR_ARM_SECURE_INTEGRITY_SIGNATURE, |
| 91 | + K_ERR_ARM_SECURE_EXCEPTION_RETURN, |
| 92 | + K_ERR_ARM_SECURE_ATTRIBUTION_UNIT, |
| 93 | + K_ERR_ARM_SECURE_TRANSITION, |
| 94 | + K_ERR_ARM_SECURE_LAZY_STATE_PRESERVATION, |
| 95 | + K_ERR_ARM_SECURE_LAZY_STATE_ERROR, |
| 96 | + |
| 97 | + /* Cortex-A/R exceptions*/ |
| 98 | + K_ERR_ARM_UNDEFINED_INSTRUCTION, |
| 99 | + K_ERR_ARM_ALIGNMENT_FAULT, |
| 100 | + K_ERR_ARM_BACKGROUND_FAULT, |
| 101 | + K_ERR_ARM_PERMISSION_FAULT, |
| 102 | + K_ERR_ARM_SYNC_EXTERNAL_ABORT, |
| 103 | + K_ERR_ARM_ASYNC_EXTERNAL_ABORT, |
| 104 | + K_ERR_ARM_SYNC_PARITY_ERROR, |
| 105 | + K_ERR_ARM_ASYNC_PARITY_ERROR, |
| 106 | + K_ERR_ARM_DEBUG_EVENT |
| 107 | +}; |
| 108 | + |
| 109 | +#endif /* _ASMLANGUAGE */ |
| 110 | + |
55 | 111 | /**
|
56 | 112 | * @brief Declare the ARCH_STACK_PTR_ALIGN
|
57 | 113 | *
|
|
0 commit comments