Skip to content

Commit d96289f

Browse files
rmurphy-armgregkh
authored andcommitted
perf/arm-cmn: Initialise cmn->cpu earlier
commit 597704e upstream. For all the complexity of handling affinity for CPU hotplug, what we've apparently managed to overlook is that arm_cmn_init_irqs() has in fact always been setting the *initial* affinity of all IRQs to CPU 0, not the CPU we subsequently choose for event scheduling. Oh dear. Cc: stable@vger.kernel.org Fixes: 0ba6477 ("perf: Add Arm CMN-600 PMU driver") Signed-off-by: Robin Murphy <robin.murphy@arm.com> Reviewed-by: Ilkka Koskinen <ilkka@os.amperecomputing.com> Link: https://lore.kernel.org/r/b12fccba6b5b4d2674944f59e4daad91cd63420b.1747069914.git.robin.murphy@arm.com Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent c6d2c0d commit d96289f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/perf/arm-cmn.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2557,6 +2557,7 @@ static int arm_cmn_probe(struct platform_device *pdev)
25572557

25582558
cmn->dev = &pdev->dev;
25592559
cmn->part = (unsigned long)device_get_match_data(cmn->dev);
2560+
cmn->cpu = cpumask_local_spread(0, dev_to_node(cmn->dev));
25602561
platform_set_drvdata(pdev, cmn);
25612562

25622563
if (cmn->part == PART_CMN600 && has_acpi_companion(cmn->dev)) {
@@ -2584,7 +2585,6 @@ static int arm_cmn_probe(struct platform_device *pdev)
25842585
if (err)
25852586
return err;
25862587

2587-
cmn->cpu = cpumask_local_spread(0, dev_to_node(cmn->dev));
25882588
cmn->pmu = (struct pmu) {
25892589
.module = THIS_MODULE,
25902590
.parent = cmn->dev,

0 commit comments

Comments
 (0)