• Ian Rogers's avatar
    perf evlist: Clear all_cpus before propagating · 33cd6928
    Ian Rogers authored
    all_cpus is merged into during propagation. Initially all_cpus is set
    from PMU sysfs. perf_evlist__set_maps() will recompute it and change
    evsel->cpus to user_requested_cpus if they are given.
    
    If all_cpus isn't cleared then the union of the user_requested_cpus and
    PMU sysfs values is set to all_cpus, whereas just user_requested_cpus is
    necessary.
    
    To avoid this make all_cpus empty prior to propagation.
    Reviewed-by: default avatarAdrian Hunter <adrian.hunter@intel.com>
    Signed-off-by: default avatarIan Rogers <irogers@google.com>
    Cc: Alexander Antonov <alexander.antonov@linux.intel.com>
    Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
    Cc: Alexei Starovoitov <ast@kernel.org>
    Cc: Alexey Bayduraev <alexey.v.bayduraev@linux.intel.com>
    Cc: Andi Kleen <ak@linux.intel.com>
    Cc: Andrii Nakryiko <andrii@kernel.org>
    Cc: Daniel Borkmann <daniel@iogearbox.net>
    Cc: German Gomez <german.gomez@arm.com>
    Cc: James Clark <james.clark@arm.com>
    Cc: Jiri Olsa <jolsa@kernel.org>
    Cc: John Fastabend <john.fastabend@gmail.com>
    Cc: John Garry <john.garry@huawei.com>
    Cc: KP Singh <kpsingh@kernel.org>
    Cc: Kajol Jain <kjain@linux.ibm.com>
    Cc: Leo Yan <leo.yan@linaro.org>
    Cc: Mark Rutland <mark.rutland@arm.com>
    Cc: Martin KaFai Lau <kafai@fb.com>
    Cc: Mathieu Poirier <mathieu.poirier@linaro.org>
    Cc: Mike Leach <mike.leach@linaro.org>
    Cc: Namhyung Kim <namhyung@kernel.org>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Riccardo Mancini <rickyman7@gmail.com>
    Cc: Song Liu <songliubraving@fb.com>
    Cc: Stephane Eranian <eranian@google.com>
    Cc: Suzuki Poulouse <suzuki.poulose@arm.com>
    Cc: Will Deacon <will@kernel.org>
    Cc: Yonghong Song <yhs@fb.com>
    Link: http://lore.kernel.org/lkml/20220503041757.2365696-3-irogers@google.comSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
    33cd6928
evlist.c 15.9 KB