perf evsel: Separate open preparation from open itself
authorRiccardo Mancini <rickyman7@gmail.com>
Sat, 21 Aug 2021 09:19:21 +0000 (11:19 +0200)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 31 Aug 2021 19:26:55 +0000 (16:26 -0300)
commitd45ce03434fd0f9177a0d3a7237fce4263eed24b
treef37f684fb63bc5a9d772bc9103ab2f32d1dab6c6
parentbc0496043edf9c78e443bcf74ed2fa04566fdc18
perf evsel: Separate open preparation from open itself

This is a preparatory patch for the following patches with the goal to
separate in evlist__open_cpu the actual perf_event_open, which could be
performed in parallel, from the existing fallback mechanisms, which
should be handled sequentially.

This patch separates the first lines of evsel__open_cpu into a new
__evsel__prepare_open function.

Signed-off-by: Riccardo Mancini <rickyman7@gmail.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lore.kernel.org/lkml/e14118b934c338dbbf68b8677f20d0d7dbf9359a.1629490974.git.rickyman7@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/evsel.c