Commit d2b5a315 authored by Jiri Olsa's avatar Jiri Olsa Committed by Arnaldo Carvalho de Melo

perf script: Check output fields only for samples

There's no need to check sampling output fields for events without
perf_event_attr::sample_type field set.
Signed-off-by: default avatarJiri Olsa <jolsa@kernel.org>
Tested-by: default avatarKan Liang <kan.liang@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1444992092-17897-51-git-send-email-jolsa@kernel.orgSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent 1fe7a300
...@@ -686,7 +686,10 @@ static int process_attr(struct perf_tool *tool, union perf_event *event, ...@@ -686,7 +686,10 @@ static int process_attr(struct perf_tool *tool, union perf_event *event,
set_print_ip_opts(&evsel->attr); set_print_ip_opts(&evsel->attr);
return perf_evsel__check_attr(evsel, scr->session); if (evsel->attr.sample_type)
err = perf_evsel__check_attr(evsel, scr->session);
return err;
} }
static int process_comm_event(struct perf_tool *tool, static int process_comm_event(struct perf_tool *tool,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment