Skip to content

Commit f2368a2

Browse files
Yicong Yangwilldeacon
authored andcommitted
drivers/perf: hisi: Don't update the associated_cpus on CPU offline
Event will be scheduled on CPU of hisi_pmu::on_cpu which is selected from the intersection of hisi_pmu::associated_cpus and online CPUs. So the associated_cpus don't need to be maintained with online CPUs. This will save one update operation if one associated CPU is offlined. Signed-off-by: Yicong Yang <yangyicong@hisilicon.com> Link: https://lore.kernel.org/r/20241210141525.37788-3-yangyicong@huawei.com Signed-off-by: Will Deacon <will@kernel.org>
1 parent 4172980 commit f2368a2

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

drivers/perf/hisilicon/hisi_uncore_pmu.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -492,9 +492,6 @@ int hisi_uncore_pmu_offline_cpu(unsigned int cpu, struct hlist_node *node)
492492
node);
493493
unsigned int target;
494494

495-
if (!cpumask_test_and_clear_cpu(cpu, &hisi_pmu->associated_cpus))
496-
return 0;
497-
498495
/* Nothing to do if this CPU doesn't own the PMU */
499496
if (hisi_pmu->on_cpu != cpu)
500497
return 0;

0 commit comments

Comments
 (0)