b282b6f8a8
Compiling the kernel with CONFIG_HOTPLUG = y and CONFIG_HOTPLUG_CPU = n with CONFIG_RELOCATABLE = y generates the following modpost warnings WARNING: vmlinux - Section mismatch: reference to .init.data: from .text between '_cpu_up' (at offset 0xc0141b7d) and 'cpu_up' WARNING: vmlinux - Section mismatch: reference to .init.data: from .text between '_cpu_up' (at offset 0xc0141b9c) and 'cpu_up' WARNING: vmlinux - Section mismatch: reference to .init.text:__cpu_up from .text between '_cpu_up' (at offset 0xc0141bd8) and 'cpu_up' WARNING: vmlinux - Section mismatch: reference to .init.data: from .text between '_cpu_up' (at offset 0xc0141c05) and 'cpu_up' WARNING: vmlinux - Section mismatch: reference to .init.data: from .text between '_cpu_up' (at offset 0xc0141c26) and 'cpu_up' WARNING: vmlinux - Section mismatch: reference to .init.data: from .text between '_cpu_up' (at offset 0xc0141c37) and 'cpu_up' This is because cpu_up, _cpu_up and __cpu_up (in some architectures) are defined as __devinit AND __cpu_up calls some __cpuinit functions. Since __cpuinit would map to __init with this kind of a configuration, we get a .text refering .init.data warning. This patch solves the problem by converting all of __cpu_up, _cpu_up and cpu_up from __devinit to __cpuinit. The approach is justified since the callers of cpu_up are either dependent on CONFIG_HOTPLUG_CPU or are of __init type. Thus when CONFIG_HOTPLUG_CPU=y, all these cpu up functions would land up in .text section, and when CONFIG_HOTPLUG_CPU=n, all these functions would land up in .init section. Tested on a i386 SMP machine running linux-2.6.20-rc3-mm1. Signed-off-by: Gautham R Shenoy <ego@in.ibm.com> Cc: Vivek Goyal <vgoyal@in.ibm.com> Cc: Mikael Starvik <starvik@axis.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Kyle McMartin <kyle@mcmartin.ca> Cc: Paul Mackerras <paulus@samba.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: "David S. Miller" <davem@davemloft.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org> |
||
---|---|---|
.. | ||
vdso32 | ||
vdso64 | ||
align.c | ||
asm-offsets.c | ||
audit.c | ||
binfmt_elf32.c | ||
btext.c | ||
compat_audit.c | ||
cpu_setup_6xx.S | ||
cpu_setup_ppc970.S | ||
cputable.c | ||
crash_dump.c | ||
crash.c | ||
dma_64.c | ||
entry_32.S | ||
entry_64.S | ||
firmware.c | ||
fpu.S | ||
head_4xx.S | ||
head_8xx.S | ||
head_32.S | ||
head_44x.S | ||
head_64.S | ||
head_booke.h | ||
head_fsl_booke.S | ||
ibmebus.c | ||
idle_6xx.S | ||
idle_power4.S | ||
idle.c | ||
init_task.c | ||
io.c | ||
iomap.c | ||
iommu.c | ||
irq.c | ||
kprobes.c | ||
l2cr_6xx.S | ||
legacy_serial.c | ||
lparcfg.c | ||
lparmap.c | ||
machine_kexec_32.c | ||
machine_kexec_64.c | ||
machine_kexec.c | ||
Makefile | ||
misc_32.S | ||
misc_64.S | ||
misc.S | ||
module_32.c | ||
module_64.c | ||
nvram_64.c | ||
of_device.c | ||
of_platform.c | ||
paca.c | ||
pci_32.c | ||
pci_64.c | ||
pci_dn.c | ||
pmc.c | ||
ppc32.h | ||
ppc_ksyms.c | ||
proc_ppc64.c | ||
process.c | ||
prom_init.c | ||
prom_parse.c | ||
prom.c | ||
ptrace32.c | ||
ptrace-common.h | ||
ptrace.c | ||
rtas_flash.c | ||
rtas_pci.c | ||
rtas-proc.c | ||
rtas-rtc.c | ||
rtas.c | ||
semaphore.c | ||
setup_32.c | ||
setup_64.c | ||
setup-common.c | ||
setup.h | ||
signal_32.c | ||
signal_64.c | ||
smp-tbsync.c | ||
smp.c | ||
swsusp_32.S | ||
sys_ppc32.c | ||
syscalls.c | ||
sysfs.c | ||
systbl.S | ||
tau_6xx.c | ||
time.c | ||
traps.c | ||
udbg_16550.c | ||
udbg.c | ||
vdso.c | ||
vecemu.c | ||
vector.S | ||
vio.c | ||
vmlinux.lds.S |