On Thu, Sep 04, 2025 at 10:38:50PM +0000, Dylan Hatch wrote: > +noinline notrace int arch_stack_walk_reliable( > + stack_trace_consume_fn consume_entry, > + void *cookie, struct task_struct *task) > +{ > + struct kunwind_reliable_consume_entry_data data = { > + .consume_entry = consume_entry, > + .cookie = cookie, > + .unreliable = false, > + }; > + > + kunwind_stack_walk(arch_kunwind_reliable_consume_entry, &data, task, > NULL); > + > + if (data.unreliable) > + return -EINVAL;
As far I can tell, the *only* error condition being checked is if it (successfully) fell back to frame pointers. What if there was some bad or missing sframe data? Or some unexpected condition on the stack? Also, does the exception handling code have correct cfi/sframe metadata? In order for it to be "reliable", we need to know the unwind reached the end of the stack (e.g., the task pt_regs frame, from entry-from-user). -- Josh