Re: [PATCH] tracing: Remove size parameter in __trace_puts()
From: Yury Norov
Date: Thu Dec 18 2025 - 18:49:11 EST
On Thu, Dec 18, 2025 at 04:37:39PM -0500, Steven Rostedt wrote:
> From: Steven Rostedt <rostedt@xxxxxxxxxxx>
>
> The __trace_puts() function takes a string pointer and the size of the
> string itself. All users currently simply pass in the strlen() of the
> string it is also passing in. There's no reason to pass in the size.
> Instead have the __trace_puts() function do the strlen() within the
> function itself.
>
> This fixes a header recursion issue where using strlen() in the macro
> calling __trace_puts() requires adding #include <linux/string.h> in order
> to use strlen(). Removing the use of strlen() from the header fixes the
> recursion issue.
>
> Link: https://lore.kernel.org/all/aUN8Hm377C5A0ILX@yury/
>
> Signed-off-by: Steven Rostedt (Google) <rostedt@xxxxxxxxxxx>
Thanks, Steven. I'll take it with v4 of the above.
Thanks,
Yury