diff options
| author | Ian Rogers <irogers@google.com> | 2025-07-18 20:05:08 -0700 |
|---|---|---|
| committer | Namhyung Kim <namhyung@kernel.org> | 2025-07-24 13:41:35 -0700 |
| commit | 6d765f5f7ec669f2a16b44afd23cd877efa640de (patch) | |
| tree | 0bbd737066958e6d6824c32e34d89efbfd2b2b9b /tools/lib/perf/evlist.c | |
| parent | perf tool_pmu: Allow num_cpus(_online) to be specific to a cpumask (diff) | |
| download | linux-6d765f5f7ec669f2a16b44afd23cd877efa640de.tar.gz linux-6d765f5f7ec669f2a16b44afd23cd877efa640de.zip | |
libperf evsel: Rename own_cpus to pmu_cpus
own_cpus is generally the cpumask from the PMU. Rename to pmu_cpus to
try to make this clearer. Variable rename with no other changes.
Reviewed-by: Thomas Falcon <thomas.falcon@intel.com>
Signed-off-by: Ian Rogers <irogers@google.com>
Tested-by: James Clark <james.clark@linaro.org>
Link: https://lore.kernel.org/r/20250719030517.1990983-7-irogers@google.com
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Diffstat (limited to 'tools/lib/perf/evlist.c')
| -rw-r--r-- | tools/lib/perf/evlist.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/lib/perf/evlist.c b/tools/lib/perf/evlist.c index b1f4c8176b32..9d9dec21f510 100644 --- a/tools/lib/perf/evlist.c +++ b/tools/lib/perf/evlist.c @@ -46,7 +46,7 @@ static void __perf_evlist__propagate_maps(struct perf_evlist *evlist, * are valid by intersecting with those of the PMU. */ perf_cpu_map__put(evsel->cpus); - evsel->cpus = perf_cpu_map__intersect(evlist->user_requested_cpus, evsel->own_cpus); + evsel->cpus = perf_cpu_map__intersect(evlist->user_requested_cpus, evsel->pmu_cpus); /* * Empty cpu lists would eventually get opened as "any" so remove @@ -61,7 +61,7 @@ static void __perf_evlist__propagate_maps(struct perf_evlist *evlist, list_for_each_entry_from(next, &evlist->entries, node) next->idx--; } - } else if (!evsel->own_cpus || evlist->has_user_cpus || + } else if (!evsel->pmu_cpus || evlist->has_user_cpus || (!evsel->requires_cpu && perf_cpu_map__has_any_cpu(evlist->user_requested_cpus))) { /* * The PMU didn't specify a default cpu map, this isn't a core @@ -72,13 +72,13 @@ static void __perf_evlist__propagate_maps(struct perf_evlist *evlist, */ perf_cpu_map__put(evsel->cpus); evsel->cpus = perf_cpu_map__get(evlist->user_requested_cpus); - } else if (evsel->cpus != evsel->own_cpus) { + } else if (evsel->cpus != evsel->pmu_cpus) { /* * No user requested cpu map but the PMU cpu map doesn't match * the evsel's. Reset it back to the PMU cpu map. */ perf_cpu_map__put(evsel->cpus); - evsel->cpus = perf_cpu_map__get(evsel->own_cpus); + evsel->cpus = perf_cpu_map__get(evsel->pmu_cpus); } if (evsel->system_wide) { |
