| 58 | } |
| 59 | |
| 60 | int |
| 61 | stack_save_td(struct stack *st, struct thread *td) |
| 62 | { |
| 63 | struct unwind_state frame; |
| 64 | |
| 65 | THREAD_LOCK_ASSERT(td, MA_OWNED); |
| 66 | KASSERT(!TD_IS_SWAPPED(td), |
| 67 | ("stack_save_td: thread %p is swapped", td)); |
| 68 | |
| 69 | if (TD_IS_RUNNING(td)) |
| 70 | return (EOPNOTSUPP); |
| 71 | |
| 72 | frame.sp = td->td_pcb->pcb_sp; |
| 73 | frame.fp = td->td_pcb->pcb_x[29]; |
| 74 | frame.pc = td->td_pcb->pcb_lr; |
| 75 | |
| 76 | stack_capture(td, st, &frame); |
| 77 | return (0); |
| 78 | } |
| 79 | |
| 80 | void |
| 81 | stack_save(struct stack *st) |
nothing calls this directly
no test coverage detected