diff options
author | Madhavan Srinivasan <maddy@linux.vnet.ibm.com> | 2019-04-04 17:24:49 +0530 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2019-05-03 02:54:58 +1000 |
commit | 708597daf23486ea6f889ca29cc88389ca9a409a (patch) | |
tree | cd23d0c623a26ca24792b14a4373fde9da69a861 /arch/powerpc/perf/power7-pmu.c | |
parent | 1e496391a8452101308a23b7395cdd4983b6e5bd (diff) | |
download | linux-708597daf23486ea6f889ca29cc88389ca9a409a.tar.bz2 |
powerpc/perf: init pmu from core-book3s
Currenty pmu driver file for each ppc64 generation processor
has a __init call in itself. Refactor the code by moving the
__init call to core-books.c. This also clean's up compat mode
pmu driver registration.
Suggested-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Madhavan Srinivasan <maddy@linux.vnet.ibm.com>
[mpe: Use SPDX tag for license]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/perf/power7-pmu.c')
-rw-r--r-- | arch/powerpc/perf/power7-pmu.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/powerpc/perf/power7-pmu.c b/arch/powerpc/perf/power7-pmu.c index 6dbae9884ec4..bb6efd5d2530 100644 --- a/arch/powerpc/perf/power7-pmu.c +++ b/arch/powerpc/perf/power7-pmu.c @@ -445,7 +445,7 @@ static struct power_pmu power7_pmu = { .cache_events = &power7_cache_events, }; -static int __init init_power7_pmu(void) +int init_power7_pmu(void) { if (!cur_cpu_spec->oprofile_cpu_type || strcmp(cur_cpu_spec->oprofile_cpu_type, "ppc64/power7")) @@ -456,5 +456,3 @@ static int __init init_power7_pmu(void) return register_power_pmu(&power7_pmu); } - -early_initcall(init_power7_pmu); |