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

Jens Remus <[email protected]>
Newsgroups org.kernel.vger.linux-toolchains,org.kernel.vger.linux-kernel,org.kernel.vger.linux-perf-users
Organization IBM Deutschland Research & Development GmbH
Message-ID <[email protected]>
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. :-)

> +		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
-- 
Jens Remus
Linux on Z Development (D3303) and z/VSE Support
+49-7031-16-1128 Office
[email protected]

IBM

IBM Deutschland Research & Development GmbH; Vorsitzender des 
Aufsichtsrats: Wolfgang Wendt; Geschäftsführung: David Faller; Sitz der 
Gesellschaft: Böblingen; Registergericht: Amtsgericht Stuttgart, HRB 243294
IBM Data Privacy Statement: https://www.ibm.com/privacy/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.