diff options
author | Ian Rogers <irogers@google.com> | 2023-08-31 00:14:20 -0700 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2023-08-31 16:24:55 -0300 |
commit | 58d3a4cea4a45414a21a712078d95b39dcdda10d (patch) | |
tree | d629b62bc661e76ca12770be861f099b9391aa63 /tools/perf/util/record.c | |
parent | 478c3f5dcd8ca7eb1ef0c7a7022cca80b528325c (diff) |
perf parse-events: Name the two term enums
Name the enums used by 'struct parse_events_term' to
parse_events__term_val_type and parse_events__term_type.
This allows greater compile time error checking.
Fix -Wswitch related issues by explicitly listing all enum values prior
to default.
Add config_term_name to safely look up a parse_events__term_type name,
bounds checking the array access first.
Add documentation to 'struct parse_events_terms' and reorder to save
space.
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: 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-3-irogers@google.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/record.c')
0 files changed, 0 insertions, 0 deletions