calibrate_delay() must be __cpuinit
calibrate_delay() must be __cpuinit, not __{dev,}init. I've verified that this is correct for all users. While doing the latter, I also did the following cleanups: - remove pointless additional prototypes in C files - ensure all users #include <linux/delay.h> This fixes the following section mismatches with CONFIG_HOTPLUG=n, CONFIG_HOTPLUG_CPU=y: WARNING: vmlinux.o(.text+0x1128d): Section mismatch: reference to .init.text.1:calibrate_delay (between 'check_cx686_slop' and 'set_cx86_reorder') WARNING: vmlinux.o(.text+0x25102): Section mismatch: reference to .init.text.1:calibrate_delay (between 'smp_callin' and 'cpu_coregroup_map') Signed-off-by: Adrian Bunk <bunk@kernel.org> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: Richard Henderson <rth@twiddle.net> Cc: "Luck, Tony" <tony.luck@intel.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: "David S. Miller" <davem@davemloft.net> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@elte.hu> Cc: Christian Zankel <chris@zankel.net> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
committed by
Linus Torvalds
parent
eb38a996eb
commit
6c81c32f96
@ -28,7 +28,7 @@ __setup("lpj=", lpj_setup);
|
||||
#define DELAY_CALIBRATION_TICKS ((HZ < 100) ? 1 : (HZ/100))
|
||||
#define MAX_DIRECT_CALIBRATION_RETRIES 5
|
||||
|
||||
static unsigned long __devinit calibrate_delay_direct(void)
|
||||
static unsigned long __cpuinit calibrate_delay_direct(void)
|
||||
{
|
||||
unsigned long pre_start, start, post_start;
|
||||
unsigned long pre_end, end, post_end;
|
||||
@ -101,7 +101,7 @@ static unsigned long __devinit calibrate_delay_direct(void)
|
||||
return 0;
|
||||
}
|
||||
#else
|
||||
static unsigned long __devinit calibrate_delay_direct(void) {return 0;}
|
||||
static unsigned long __cpuinit calibrate_delay_direct(void) {return 0;}
|
||||
#endif
|
||||
|
||||
/*
|
||||
@ -111,7 +111,7 @@ static unsigned long __devinit calibrate_delay_direct(void) {return 0;}
|
||||
*/
|
||||
#define LPS_PREC 8
|
||||
|
||||
void __devinit calibrate_delay(void)
|
||||
void __cpuinit calibrate_delay(void)
|
||||
{
|
||||
unsigned long ticks, loopbit;
|
||||
int lps_precision = LPS_PREC;
|
||||
|
Reference in New Issue
Block a user