Damjan Marion | 7892560 | 2024-05-23 13:06:39 +0000 | [diff] [blame] | 1 | /* SPDX-License-Identifier: Apache-2.0 |
| 2 | * Copyright (c) 2024 Cisco Systems, Inc. |
| 3 | */ |
| 4 | |
| 5 | #ifndef __STACK_H__ |
| 6 | #define __STACK_H__ |
| 7 | |
| 8 | #include <vppinfra/clib.h> |
| 9 | |
| 10 | typedef struct |
| 11 | { |
| 12 | uword ip, sp; |
| 13 | uword offset; |
| 14 | char name[64]; |
| 15 | const char *file_name; |
| 16 | u32 index; |
| 17 | u8 is_signal_frame; |
| 18 | } clib_stack_frame_t; |
| 19 | |
| 20 | clib_stack_frame_t *clib_stack_frame_get (clib_stack_frame_t *); |
| 21 | |
| 22 | #define foreach_clib_stack_frame(sf) \ |
| 23 | for (clib_stack_frame_t _sf = {}, *sf = clib_stack_frame_get (&_sf); sf; \ |
| 24 | sf = clib_stack_frame_get (sf)) |
| 25 | |
| 26 | #endif /* __STACK_H__ */ |