Skip to contentSkip to conversation

msm: headsmp.S: Fix section mismatch

PATCH In review Stephen Boyd 3 participants 3 messages Feb 19, 2011 – Feb 20, 2011

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 msm: headsmp.S: Fix section mismatch

WARNING: vmlinux.o(.cpuinit.text+0xc80): Section mismatch in reference from the function boot_secondary() to the variable .init.text:msm_secondary_startup
The function __cpuinit boot_secondary() references a variable __init msm_secondary_startup. If msm_secondary_startup is only used by boot_secondary then annotate msm_secondary_startup with a matching annotation.

---
 arch/arm/mach-msm/headsmp.S |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
arch/arm/mach-msm/headsmp.S +1 -1
index d0c2143..0c631a9 100644
@@ -11,7 +11,7 @@
 #include <linux/linkage.h>
 #include <linux/init.h>
 
-	__INIT
+	__CPUINIT
 
 /*
  * MSM specific entry point for secondary CPUs.  This provides
Signature · 2 lines
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
#1 lore raw
Quoted 7 lines · Stephen Boyd

WARNING: vmlinux.o(.cpuinit.text+0xc80): Section mismatch in reference from the function boot_secondary() to the variable .init.text:msm_secondary_startup
The function __cpuinit boot_secondary() references a variable __init msm_secondary_startup. If msm_secondary_startup is only used by boot_secondary then annotate msm_secondary_startup with a matching annotation.

Description is pretty gross.. Can you just explain how the section mismatch is happening.

Daniel

#2 lore raw
Quoted 11 lines · Daniel Walker
Quoted 7 lines · Stephen Boyd

WARNING: vmlinux.o(.cpuinit.text+0xc80): Section mismatch in reference from the function boot_secondary() to the variable .init.text:msm_secondary_startup
The function __cpuinit boot_secondary() references a variable __init msm_secondary_startup. If msm_secondary_startup is only used by boot_secondary then annotate msm_secondary_startup with a matching annotation.

Description is pretty gross.. Can you just explain how the section mismatch is happening.

That's the error message, which is explanitory.

mem_secondary_startup is in the __init section, which is always discarded. boot_secondary is in the __cpuinit section, which may or may not be discarded, and if CPU hotplug is enabled, may be called after the __init section has been discarded.