Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-15-SP5:GA
perf.12035
perf-ftrace-move-setup_pager-before-opening-tra...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File perf-ftrace-move-setup_pager-before-opening-trace_pipe.patch of Package perf.12035
From: Namhyung Kim <namhyung@kernel.org> Date: Sun, 18 Jun 2017 23:23:00 +0900 Subject: perf ftrace: Move setup_pager before opening trace_pipe Git-commit: 29681bc5bb4326c2f9eac5dc68d8fad3e88b4bb5 Patch-mainline: v4.13-rc1 References: bsc#1070010 (git-fixes) Signed-off-By: Tony Jones <tonyj@suse.de> The 'perf ftrace' command fails to reset tracer after finishing recording like below: $ sudo perf ftrace -v hello write 'nop' to tracing/current_tracer failed: Device or resource busy ... This is because the trace_pipe file is open in pager process. Move the pager setup to before opening the file. Signed-off-by: Namhyung Kim <namhyung@kernel.org> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: kernel-team@lge.com Fixes: 583359646fde ("perf ftrace: Use pager for displaying result") Link: http://lkml.kernel.org/r/20170618142302.25390-2-namhyung@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> --- tools/perf/builtin-ftrace.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/perf/builtin-ftrace.c b/tools/perf/builtin-ftrace.c index 966a94fa8200..982b98ee639e 100644 --- a/tools/perf/builtin-ftrace.c +++ b/tools/perf/builtin-ftrace.c @@ -231,6 +231,8 @@ static int __cmd_ftrace(struct perf_ftrace *ftrace, int argc, const char **argv) goto out_reset; } + setup_pager(); + trace_file = get_tracing_file("trace_pipe"); if (!trace_file) { pr_err("failed to open trace_pipe\n"); @@ -254,8 +256,6 @@ static int __cmd_ftrace(struct perf_ftrace *ftrace, int argc, const char **argv) goto out_close_fd; } - setup_pager(); - perf_evlist__start_workload(ftrace->evlist); while (!done) {
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor