[2.6 patch] arch/i386/kernel/smpboot.c:setup_trampoline() must be __cpuinit

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Frank van Maarseveen <frankvm@...>
Cc: <linux-kernel@...>, <stable@...>, Andrew Morton <akpm@...>
Date: Monday, July 9, 2007 - 8:05 pm

This patch fixes the following section mismatch reported by
Frank van Maarseveen:

<--  snip  -->

...
  MODPOST vmlinux
WARNING: arch/i386/kernel/built-in.o(.text+0xf201): Section mismatch: reference to .init.data:trampoline_end (between 'setup_trampoline' and 'cpu_coregroup_map')
WARNING: arch/i386/kernel/built-in.o(.text+0xf207): Section mismatch: reference to .init.data:trampoline_data (between 'setup_trampoline' and 'cpu_coregroup_map')
WARNING: arch/i386/kernel/built-in.o(.text+0xf21a): Section mismatch: reference to .init.data:trampoline_data (between 'setup_trampoline' and 'cpu_coregroup_map')
...

<--  snip  -->

Signed-off-by: Adrian Bunk <bunk@stusta.de>

---

@stable:
Harmless but annoying warnings present when building an i386 SMP kernel 
with CONFIG_HOTPLUG_CPU=n and gcc < 4.0 .

--- linux-2.6.22-rc6-mm1/arch/i386/kernel/smpboot.c.old	2007-07-10 01:26:07.000000000 +0200
+++ linux-2.6.22-rc6-mm1/arch/i386/kernel/smpboot.c	2007-07-10 01:26:18.000000000 +0200
@@ -117,7 +117,7 @@
  * has made sure it's suitably aligned.
  */
 
-static unsigned long __devinit setup_trampoline(void)
+static unsigned long __cpuinit setup_trampoline(void)
 {
 	memcpy(trampoline_base, trampoline_data, trampoline_end - trampoline_data);
 	return virt_to_phys(trampoline_base);

-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
2.6.22: section mismatch warnings, Frank van Maarseveen, (Mon Jul 9, 2:42 pm)
Re: 2.6.22: section mismatch warnings, Adrian Bunk, (Mon Jul 9, 8:14 pm)
Re: 2.6.22: section mismatch warnings, Frank van Maarseveen, (Tue Jul 10, 4:34 am)
Re: 2.6.22: section mismatch warnings, Adrian Bunk, (Mon Jul 9, 3:45 pm)
Re: 2.6.22: section mismatch warnings, Frank van Maarseveen, (Mon Jul 9, 3:48 pm)
[2.6 patch] arch/i386/kernel/smpboot.c:setup_trampoline() mu..., Adrian Bunk, (Mon Jul 9, 8:05 pm)
Re: [2.6 patch] arch/i386/kernel/smpboot.c:setup_trampoline(..., Frank van Maarseveen, (Mon Oct 15, 11:02 am)