1 | // SPDX-License-Identifier: GPL-3.0-only |
---|---|
2 | |
3 | #pragma once |
4 | |
5 | #include <mos/types.h> |
6 | |
7 | typedef struct |
8 | { |
9 | ptr_t address; |
10 | const char *name; |
11 | } kallsyms_t; |
12 | |
13 | extern const kallsyms_t mos_kallsyms[]; |
14 | |
15 | #define mos_caller() (kallsyms_get_symbol_name((ptr_t) __builtin_return_address(0))) |
16 | |
17 | const kallsyms_t *kallsyms_get_symbol(ptr_t addr); |
18 | const char *kallsyms_get_symbol_name(ptr_t addr); |
19 |