Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1571520

[PATCH 01/14] perf ftrace: Remove needless code setting default tracer

From Arnaldo Carvalho de Melo <acme@kernel.org>
Newsgroups linux.kernel
Subject [PATCH 01/14] perf ftrace: Remove needless code setting default tracer
Date 2017-02-01 13:30 +0100
Message-ID <t62cW-5Vf-37@gated-at.bofh.it> (permalink)
References <t62cV-5Vf-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Taeung Song <treeze.taeung@gmail.com>

As a result of commit a3497642c261 ("perf ftrace: Make 'function_graph'
be the default tracer") the ftrace.tracer variable can't be NULL but the
other code setting default tracer remained.

Signed-off-by: Taeung Song <treeze.taeung@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1485423339-22780-1-git-send-email-treeze.taeung@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/builtin-ftrace.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/tools/perf/builtin-ftrace.c b/tools/perf/builtin-ftrace.c
index d05658d2b8f1..414444d0e919 100644
--- a/tools/perf/builtin-ftrace.c
+++ b/tools/perf/builtin-ftrace.c
@@ -202,7 +202,7 @@ int cmd_ftrace(int argc, const char **argv, const char *prefix __maybe_unused)
 {
 	int ret;
 	struct perf_ftrace ftrace = {
-		.tracer = "function_graph",
+		.tracer = DEFAULT_TRACER,
 		.target = { .uid = UINT_MAX, },
 	};
 	const char * const ftrace_usage[] = {
@@ -231,9 +231,6 @@ int cmd_ftrace(int argc, const char **argv, const char *prefix __maybe_unused)
 	if (ret < 0)
 		goto out_delete_evlist;
 
-	if (ftrace.tracer == NULL)
-		ftrace.tracer = DEFAULT_TRACER;
-
 	ret = __cmd_ftrace(&ftrace, argc, argv);
 
 out_delete_evlist:
-- 
2.9.3

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[GIT PULL 00/14] perf/core improvements and fixes Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-02-01 13:30 +0100
  [PATCH 07/14] tools lib bpf: Add BPF program pinning APIs Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-02-01 13:30 +0100
  [PATCH 01/14] perf ftrace: Remove needless code setting default tracer Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-02-01 13:30 +0100
  [PATCH 10/14] tools perf util: Make rm_rf(path) argument const Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-02-01 13:30 +0100
  [PATCH 04/14] perf tools: Propagate perf_config() errors Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-02-01 13:30 +0100
  [PATCH 12/14] perf test: Add libbpf pinning test Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-02-01 13:30 +0100
  [PATCH 13/14] perf tools: Create for_each_event macro for tracepoints iteration Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-02-01 13:30 +0100
  [PATCH 02/14] tools build: Add tools tree support for 'make -s' Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-02-01 13:30 +0100
  [PATCH 09/14] tools lib bpf: Add bpf_object__pin() Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-02-01 13:30 +0100
  Re: [GIT PULL 00/14] perf/core improvements and fixes Ingo Molnar <mingo@kernel.org> - 2017-02-01 15:40 +0100

csiph-web