Zephyr API 3.6.99
|
To add API support to an architecture, arch_stack_walk()
should be implemented and a non-user configurable Kconfig ARCH_HAS_STACKWALK
that is default to y
should be created in the architecture's top level Kconfig, with all the relevant dependencies.
More...
Typedefs | |
typedef bool(* | stack_trace_callback_fn) (void *cookie, unsigned long addr) |
stack_trace_callback_fn - Callback for arch_stack_walk | |
Functions | |
void | arch_stack_walk (stack_trace_callback_fn callback_fn, void *cookie, const struct k_thread *thread, const struct arch_esf *esf) |
Architecture-specific function to walk the stack. | |
To add API support to an architecture, arch_stack_walk()
should be implemented and a non-user configurable Kconfig ARCH_HAS_STACKWALK
that is default to y
should be created in the architecture's top level Kconfig, with all the relevant dependencies.
#include <zephyr/arch/arch_interface.h>
stack_trace_callback_fn - Callback for arch_stack_walk
cookie | Caller supplied pointer handed back by arch_stack_walk |
addr | The stack entry address to consume |
void arch_stack_walk | ( | stack_trace_callback_fn | callback_fn, |
void * | cookie, | ||
const struct k_thread * | thread, | ||
const struct arch_esf * | esf ) |
#include <zephyr/arch/arch_interface.h>
Architecture-specific function to walk the stack.
callback_fn | Callback which is invoked by the architecture code for each entry. |
cookie | Caller supplied pointer which is handed back to callback_fn |
thread | Pointer to a k_thread struct, can be NULL |
esf | Pointer to an arch_esf struct, can be NULL |
============ ======= ============================================ thread esf ============ ======= ============================================ thread NULL Stack trace from thread (can be _current) thread esf Stack trace starting on esf ============ ======= ============================================