mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] x86: properly cpuinit-annotate SMP boot trampolines
@ 2009-09-04  8:16 Jan Beulich
  2009-09-20 18:29 ` [tip:x86/urgent] x86: cpuinit-annotate SMP boot trampolines properly tip-bot for Jan Beulich
  0 siblings, 1 reply; 2+ messages in thread
From: Jan Beulich @ 2009-09-04  8:16 UTC (permalink / raw)
  To: mingo, tglx, hpa; +Cc: linux-kernel

Add missing annotations, and make use of include/linux/init.h's macros.

Signed-off-by: Jan Beulich <jbeulich@novell.com>

---
 arch/x86/kernel/trampoline.c    |    4 ++--
 arch/x86/kernel/trampoline_32.S |    8 ++------
 arch/x86/kernel/trampoline_64.S |    5 +++--
 3 files changed, 7 insertions(+), 10 deletions(-)

--- linux-2.6.31-rc8/arch/x86/kernel/trampoline.c	2009-03-24 00:12:14.000000000 +0100
+++ 2.6.31-rc8-x86-trampoline-cpuinit/arch/x86/kernel/trampoline.c	2009-09-02 12:13:01.000000000 +0200
@@ -4,7 +4,7 @@
 #include <asm/e820.h>
 
 /* ready for x86_64 and x86 */
-unsigned char *trampoline_base = __va(TRAMPOLINE_BASE);
+unsigned char *__cpuinitdata trampoline_base = __va(TRAMPOLINE_BASE);
 
 void __init reserve_trampoline_memory(void)
 {
@@ -26,7 +26,7 @@ void __init reserve_trampoline_memory(vo
  * bootstrap into the page concerned. The caller
  * has made sure it's suitably aligned.
  */
-unsigned long setup_trampoline(void)
+unsigned long __cpuinit setup_trampoline(void)
 {
 	memcpy(trampoline_base, trampoline_data, TRAMPOLINE_SIZE);
 	return virt_to_phys(trampoline_base);
--- linux-2.6.31-rc8/arch/x86/kernel/trampoline_32.S	2009-06-10 05:05:27.000000000 +0200
+++ 2.6.31-rc8-x86-trampoline-cpuinit/arch/x86/kernel/trampoline_32.S	2009-09-02 12:13:01.000000000 +0200
@@ -28,16 +28,12 @@
  */
 
 #include <linux/linkage.h>
+#include <linux/init.h>
 #include <asm/segment.h>
 #include <asm/page_types.h>
 
 /* We can free up trampoline after bootup if cpu hotplug is not supported. */
-#ifndef CONFIG_HOTPLUG_CPU
-.section ".cpuinit.data","aw",@progbits
-#else
-.section .rodata,"a",@progbits
-#endif
-
+__CPUINITRODATA
 .code16
 
 ENTRY(trampoline_data)
--- linux-2.6.31-rc8/arch/x86/kernel/trampoline_64.S	2009-06-10 05:05:27.000000000 +0200
+++ 2.6.31-rc8-x86-trampoline-cpuinit/arch/x86/kernel/trampoline_64.S	2009-09-02 12:13:01.000000000 +0200
@@ -25,14 +25,15 @@
  */
 
 #include <linux/linkage.h>
+#include <linux/init.h>
 #include <asm/pgtable_types.h>
 #include <asm/page_types.h>
 #include <asm/msr.h>
 #include <asm/segment.h>
 #include <asm/processor-flags.h>
 
-.section .rodata, "a", @progbits
-
+/* We can free up the trampoline after bootup if cpu hotplug is not supported. */
+__CPUINITRODATA
 .code16
 
 ENTRY(trampoline_data)




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-09-20 18:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-04  8:16 [PATCH] x86: properly cpuinit-annotate SMP boot trampolines Jan Beulich
2009-09-20 18:29 ` [tip:x86/urgent] x86: cpuinit-annotate SMP boot trampolines properly tip-bot for Jan Beulich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome