[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250826094830.29df8e62@gandalf.local.home>
Date: Tue, 26 Aug 2025 09:48:30 -0400
From: Steven Rostedt <rostedt@...dmis.org>
To: Vladimir Riabchun <ferr.lambarginio@...il.com>
Cc: mhiramat@...nel.org, mark.rutland@....com, linux-kernel@...r.kernel.org,
linux-trace-kernel@...r.kernel.org, Josh Poimboeuf <jpoimboe@...hat.com>
Subject: Re: [PATCH] ftrace/samples: Fix function size computation
On Tue, 26 Aug 2025 12:13:44 +0200
Vladimir Riabchun <ferr.lambarginio@...il.com> wrote:
> In my_tramp1 function ASM_RET instruction was placed below
> .size directive, leading to a wrong function size.
Looking at the Fixes commit, it appears that the .size directive was placed
above the ret instruction ;-)
-- Steve
>
> Fixes: 9d907f1ae80b ("samples/ftrace: Fix asm function ELF annotations")
> Signed-off-by: Vladimir Riabchun <ferr.lambarginio@...il.com>
> ---
> samples/ftrace/ftrace-direct-modify.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/samples/ftrace/ftrace-direct-modify.c b/samples/ftrace/ftrace-direct-modify.c
> index cfea7a38befb..da3a9f2091f5 100644
> --- a/samples/ftrace/ftrace-direct-modify.c
> +++ b/samples/ftrace/ftrace-direct-modify.c
> @@ -75,8 +75,8 @@ asm (
> CALL_DEPTH_ACCOUNT
> " call my_direct_func1\n"
> " leave\n"
> -" .size my_tramp1, .-my_tramp1\n"
> ASM_RET
> +" .size my_tramp1, .-my_tramp1\n"
>
> " .type my_tramp2, @function\n"
> " .globl my_tramp2\n"
Powered by blists - more mailing lists