diff options
author | Nick Child <nick.child@ibm.com> | 2021-12-16 17:00:16 -0500 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2021-12-23 22:33:10 +1100 |
commit | d276960d9296b6a9074795fe60a513abf8474e35 (patch) | |
tree | ad78d75bcbe616149886648a4312accce6eb2637 /arch/powerpc/kernel/smp.c | |
parent | a8968521cfdc3e339fe69473d6632e0aa8d7202a (diff) | |
download | linux-d276960d9296b6a9074795fe60a513abf8474e35.tar.gz linux-d276960d9296b6a9074795fe60a513abf8474e35.tar.bz2 linux-d276960d9296b6a9074795fe60a513abf8474e35.zip |
powerpc/kernel: Add __init attribute to eligible functions
Some functions defined in `arch/powerpc/kernel` (and one in `arch/powerpc/
kexec`) are deserving of an `__init` macro attribute. These functions are
only called by other initialization functions and therefore should inherit
the attribute.
Also, change function declarations in header files to include `__init`.
Signed-off-by: Nick Child <nick.child@ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20211216220035.605465-2-nick.child@ibm.com
Diffstat (limited to 'arch/powerpc/kernel/smp.c')
-rw-r--r-- | arch/powerpc/kernel/smp.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/powerpc/kernel/smp.c b/arch/powerpc/kernel/smp.c index c338f9d8ab37..b7fd6a72aa76 100644 --- a/arch/powerpc/kernel/smp.c +++ b/arch/powerpc/kernel/smp.c @@ -936,7 +936,8 @@ out: return tg; } -static int update_mask_from_threadgroup(cpumask_var_t *mask, struct thread_groups *tg, int cpu, int cpu_group_start) +static int __init update_mask_from_threadgroup(cpumask_var_t *mask, struct thread_groups *tg, + int cpu, int cpu_group_start) { int first_thread = cpu_first_thread_sibling(cpu); int i; @@ -1682,7 +1683,7 @@ int setup_profiling_timer(unsigned int multiplier) } #endif -static void fixup_topology(void) +static void __init fixup_topology(void) { int i; |