aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdrian Hunter <adrian.hunter@intel.com>2013-10-22 03:34:09 -0400
committerArnaldo Carvalho de Melo <acme@redhat.com>2013-10-23 09:58:03 -0400
commit89c97d936e76b064a52ee056602b2a62b3f1ef70 (patch)
tree3325db7e1299d00ccc74ab1cd1173fbb1e8a52f0
parent6f3e5eda9d6cc74538430d8f9e8e4baa01249160 (diff)
perf inject: Do not repipe attributes to a perf.data file
perf.data files contain the attributes separately, do not put them in the event stream as well. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Namhyung Kim <namhyung@gmail.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/r/1382427258-17495-6-git-send-email-adrian.hunter@intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
-rw-r--r--tools/perf/builtin-inject.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/tools/perf/builtin-inject.c b/tools/perf/builtin-inject.c
index eb1a5941912b..409ceaf3b9b9 100644
--- a/tools/perf/builtin-inject.c
+++ b/tools/perf/builtin-inject.c
@@ -72,12 +72,17 @@ static int perf_event__repipe_attr(struct perf_tool *tool,
72 union perf_event *event, 72 union perf_event *event,
73 struct perf_evlist **pevlist) 73 struct perf_evlist **pevlist)
74{ 74{
75 struct perf_inject *inject = container_of(tool, struct perf_inject,
76 tool);
75 int ret; 77 int ret;
76 78
77 ret = perf_event__process_attr(tool, event, pevlist); 79 ret = perf_event__process_attr(tool, event, pevlist);
78 if (ret) 80 if (ret)
79 return ret; 81 return ret;
80 82
83 if (!inject->pipe_output)
84 return 0;
85
81 return perf_event__repipe_synth(tool, event); 86 return perf_event__repipe_synth(tool, event);
82} 87}
83 88