Bibo Mao 1c4ee6acdb LoongArch: Lately init pmu after smp is online
[ Upstream commit f3334ebb8a2a1841c2824594dd992e66de19deb2 ]

There is an smp function call named reset_counters() to init PMU
registers of every CPU in PMU initialization state. It requires that all
CPUs are online. However there is an early_initcall() wrapper for the
PMU init funciton init_hw_perf_events(), so that pmu init funciton is
called in do_pre_smp_initcalls() which before function smp_init().
Function reset_counters() cannot work on other CPUs since they haven't
boot up still.

Here replace the wrapper early_initcall() with pure_initcall(), so that
the PMU init function is called after every cpu is online.

Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-06-12 11:02:59 +02:00
..
2022-08-12 09:44:23 -07:00
2022-10-12 16:36:19 +08:00
2022-07-29 18:22:32 +08:00
2022-07-29 18:22:32 +08:00
2022-07-29 18:22:32 +08:00
2022-06-03 20:09:28 +08:00
2022-06-03 20:09:28 +08:00
2022-06-03 20:09:28 +08:00
2022-10-12 16:36:19 +08:00
2022-10-12 10:35:20 -07:00
2022-10-12 16:36:14 +08:00
2022-10-12 16:36:19 +08:00
2022-06-03 20:09:28 +08:00
2022-10-12 16:36:19 +08:00