zephyr/tests/kernel/fatal/exception
Daniel Leung 116998c677 tests: kernel: print FAILED when wrong faults caught
For some kernel tests, faults and exceptions are expected.
They are caught and the test would continue if the reasons
for faults are as expected. However, when the unexpected
reasons are encountered, the code simply prints a message
and calls k_fatal_halt(). When running under twister,
these messages are not the expected failed messages so
twister will spin till timeout although the execution
has already been halted. This adds another printk() before
halt to signal twister that the test has failed and bails
early.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2023-02-21 18:06:44 -05:00
..
src tests: kernel: print FAILED when wrong faults caught 2023-02-21 18:06:44 -05:00
CMakeLists.txt
prj_arm_fpu_sharing.conf
prj_armv8m_mpu_stack_guard.conf
prj.conf tests: move to using CONFIG_MP_MAX_NUM_CPUS 2022-10-20 22:04:10 +09:00
protection_no_userspace.conf
README
sentinel.conf tests: move to using CONFIG_MP_MAX_NUM_CPUS 2022-10-20 22:04:10 +09:00
testcase.yaml yamllint: fix all yamllint truthy errors 2023-01-04 01:16:45 +09:00

This test case verifies that kernel fatal error handling works correctly.

If a thread causes a CPU exception, and it is not in an ISR or "essential"
thread, the thread gets aborted and the rest of the system executes normally.