lkml.org 
[lkml]   [2023]   [Jan]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 3/4] tracing: Add trace_array_puts() to write into instance
On Wed, Jan 11, 2023 at 09:56:39AM -0500, Steven Rostedt wrote:
> From: "Steven Rostedt (Google)" <rostedt@goodmis.org>
>
> Add a generic trace_array_puts() that can be used to "trace_puts()" into
> an allocated trace_array instance. This is just another variant of
> trace_array_printk().
>
> Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
> ---
> include/linux/trace.h | 13 +++++++++++++
> kernel/trace/trace.c | 27 +++++++++++++++++----------
> 2 files changed, 30 insertions(+), 10 deletions(-)
>
> diff --git a/include/linux/trace.h b/include/linux/trace.h
> index 80ffda871749..afe61949e83a 100644
> --- a/include/linux/trace.h
> +++ b/include/linux/trace.h
> @@ -33,6 +33,19 @@ struct trace_array;
> int register_ftrace_export(struct trace_export *export);
> int unregister_ftrace_export(struct trace_export *export);
>
> +/**
> + * trace_array_puts - write a constant string into the trace buffer.
> + * @tr: The trace array to write to
> + * @ip: The address of the caller

@ip is not an arg to trace_array_puts(), an can be dropped from the comment.

Other than that, you can add:

Reviewed-by: Ross Zwisler <zwisler@google.com>

\
 
 \ /
  Last update: 2023-03-26 23:38    [W:0.214 / U:0.048 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site