]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
tracing/user_events: Slightly simplify user_seq_show()
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Wed, 19 Feb 2025 15:43:33 +0000 (16:43 +0100)
committerSteven Rostedt (Google) <rostedt@goodmis.org>
Thu, 6 Mar 2025 18:35:27 +0000 (13:35 -0500)
2 seq_puts() calls can be merged.

It saves a few lines of code and a few cycles, should it matter.

Cc: Masami Hiramatsu <mhiramat@kernel.org>
Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Link: https://lore.kernel.org/845caa94b74cea8d72c158bf1994fe250beee28c.1739979791.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
kernel/trace/trace_events_user.c

index 3effc6fce20e65a8077de5221eb69db04fb1a775..af42aaa3d172ccd20fe2cc21f13eeb7fec6c142c 100644 (file)
@@ -2793,11 +2793,8 @@ static int user_seq_show(struct seq_file *m, void *p)
 
                seq_printf(m, "%s", EVENT_TP_NAME(user));
 
-               if (status != 0)
-                       seq_puts(m, " #");
-
                if (status != 0) {
-                       seq_puts(m, " Used by");
+                       seq_puts(m, " Used by");
                        if (status & EVENT_STATUS_FTRACE)
                                seq_puts(m, " ftrace");
                        if (status & EVENT_STATUS_PERF)