Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

perf inject: With --convert-callchain ignore the dummy event for dwarf stacks

On hybrid systems there is generally >1 event and a dummy event.

The perf inject --convert-callchain option is failing to convert
perf.data files on such systems reporting "--convert-callchain requires
DWARF call graph."

The failing event is the dummy event that doesn't need to be set up for
samples.

As such ignore this event when checking the evsels.

Fixes: 92ea788d2af4e65a ("perf inject: Add --convert-callchain option")
Signed-off-by: Ian Rogers <irogers@google.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: James Clark <james.clark@linaro.org>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>

authored by

Ian Rogers and committed by
Arnaldo Carvalho de Melo
e786a04b dc329efc

+1 -1
+1 -1
tools/perf/builtin-inject.c
··· 2729 2729 } 2730 2730 2731 2731 evlist__for_each_entry(inject.session->evlist, evsel) { 2732 - if (!evsel__has_dwarf_callchain(evsel)) { 2732 + if (!evsel__has_dwarf_callchain(evsel) && !evsel__is_dummy_event(evsel)) { 2733 2733 pr_err("--convert-callchain requires DWARF call graph.\n"); 2734 2734 goto out_delete; 2735 2735 }