summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorliqiong <liqiong@nfschina.com>2022-05-13 15:52:21 +0800
committerSteven Rostedt (Google) <rostedt@goodmis.org>2022-05-26 21:13:00 -0400
commit2decd16f47e3df3234b5486fe89a9aa5a1102af1 (patch)
tree95364cda4e95d0c3ef260227d59d3e140695037e /kernel
parent2d601b98643dd2846e2958d931826e7b7af44969 (diff)
tracing: Cleanup code by removing init "char *name"
The pointer is assigned to "type->name" anyway. no need to initialize with "preemption". Link: https://lkml.kernel.org/r/20220513075221.26275-1-liqiong@nfschina.com Signed-off-by: liqiong <liqiong@nfschina.com> Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/trace/trace.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
index e38a7ca4cdd0..f400800bc910 100644
--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -4276,9 +4276,7 @@ print_trace_header(struct seq_file *m, struct trace_iterator *iter)
struct tracer *type = iter->trace;
unsigned long entries;
unsigned long total;
- const char *name = "preemption";
-
- name = type->name;
+ const char *name = type->name;
get_total_entries(buf, &total, &entries);