perf list: Don't print Unit for "default_core"
authorIan Rogers <irogers@google.com>
Thu, 31 Aug 2023 07:14:19 +0000 (00:14 -0700)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 31 Aug 2023 19:24:47 +0000 (16:24 -0300)
commit478c3f5dcd8ca7eb1ef0c7a7022cca80b528325c
treef3967b85d67c640cf093e15c1aa5a3406632c35b
parentbdc60129915fb4ff7832f4833512779c6a94eb5f
perf list: Don't print Unit for "default_core"

"default_core" was added as a way to demark JSON events whose PMU should
be whatever the default core PMU is, previously this had been assumed to
be "cpu" but that fails on s390 and ARM.

'perf list' displays the PMU in the event description to save storing it
in JSON, but was still comparing against "cpu" and not "default_core",
so update this.

Fixes: d2045f87154bf67a ("perf jevents: Use "default_core" for events with no Unit")
Signed-off-by: Ian Rogers <irogers@google.com>
Tested-by: Kan Liang <kan.liang@linux.intel.com>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: James Clark <james.clark@arm.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20230831071421.2201358-2-irogers@google.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-list.c