Re: [PATCH v3 09/19] unwind: Introduce sframe user space unwinding

From: Steven Rostedt
Date: Wed Nov 13 2024 - 15:51:10 EST


On Wed, 13 Nov 2024 16:56:25 +0100
Jens Remus <jremus@xxxxxxxxxxxxx> wrote:

> On 28.10.2024 22:47, Josh Poimboeuf wrote:
>
> > diff --git a/kernel/unwind/user.c b/kernel/unwind/user.c
>
> > @@ -68,7 +83,12 @@ int unwind_user_start(struct unwind_user_state *state)
> > return -EINVAL;
> > }
> >
> > - state->type = UNWIND_USER_TYPE_FP;
> > + if (current_has_sframe())
> > + state->type = UNWIND_USER_TYPE_SFRAME;
> > + else if (IS_ENABLED(CONFIG_UNWIND_USER_FP))
>
> The test must be for CONFIG_HAVE_UNWIND_USER_FP. :-)

Yep, that too.

Thanks,

-- Steve

>
> > + state->type = UNWIND_USER_TYPE_FP;
> > + else
> > + state->type = UNWIND_USER_TYPE_NONE;
> >
> > state->sp = user_stack_pointer(regs);
> > state->ip = instruction_pointer(regs);
>
> Regards,
> Jens