Re: [PATCH v3 35/51] x86/unwind: add new unwind interface and implementations
From: Josh Poimboeuf
Date: Mon Aug 15 2016 - 19:06:56 EST
On Fri, Aug 12, 2016 at 09:28:54AM -0500, Josh Poimboeuf wrote:
> + /*
> + * The caller can optionally provide a stack pointer directly
> + * (sp) or indirectly (regs->sp), which indicates which stack
> + * frame to start unwinding at. Skip ahead until we reach it.
> + */
> + while (!unwind_done(state) &&
> + (!on_stack(&state->stack_info, first_sp, sizeof(*first_sp) ||
> + state->bp < first_sp)))
> + unwind_next_frame(state);
Ack, the parentheses got messed up with a last minute formatting change
and gcc didn't catch it. This should actually be:
while (!unwind_done(state) &&
(!on_stack(&state->stack_info, first_sp, sizeof(*first_sp)) ||
state->bp < first_sp))
unwind_next_frame(state);
--
Josh