diff options
author | Rob Herring <robh@kernel.org> | 2023-01-27 23:55:46 +0300 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2023-02-02 22:32:19 +0300 |
commit | 2889959489ef4118953116496a06203aaf6c35b6 (patch) | |
tree | be26c06177999d1dad71f999392948dcebcd8b28 | |
parent | 1c249565426e3a9940102c0ba9f63914f7cda73d (diff) | |
download | linux-2889959489ef4118953116496a06203aaf6c35b6.tar.xz |
perf arm-spe: Only warn once for each unsupported address packet
Unknown address packet indexes are not an error as the Arm architecture
can (and has with SPEv1.2) define new ones and implementation defined
ones are also allowed. The error message for every occurrence of the
packet is needlessly noisy as well. Change the message to print just
once for each unknown index.
Reviewed-by: Leo Yan <leo.yan@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.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: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20230127205546.667740-1-robh@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
-rw-r--r-- | tools/perf/util/arm-spe-decoder/arm-spe-decoder.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tools/perf/util/arm-spe-decoder/arm-spe-decoder.c b/tools/perf/util/arm-spe-decoder/arm-spe-decoder.c index 091987dd3966..40dcedfd75cd 100644 --- a/tools/perf/util/arm-spe-decoder/arm-spe-decoder.c +++ b/tools/perf/util/arm-spe-decoder/arm-spe-decoder.c @@ -68,7 +68,11 @@ static u64 arm_spe_calc_ip(int index, u64 payload) /* Clean highest byte */ payload = SPE_ADDR_PKT_ADDR_GET_BYTES_0_6(payload); } else { - pr_err("unsupported address packet index: 0x%x\n", index); + static u32 seen_idx = 0; + if (!(seen_idx & BIT(index))) { + seen_idx |= BIT(index); + pr_warning("ignoring unsupported address packet index: 0x%x\n", index); + } } return payload; |