Patchwork [U-Boot,v11,14/30] arm: crt0.S: Remove bogus .globl

login
register
mail settings
Submitter Benoît Thébaudeau
Date April 9, 2013, 7:48 p.m.
Message ID <1365536939-5755-14-git-send-email-benoit.thebaudeau@advansee.com>
Download mbox | patch
Permalink /patch/235203/
State Superseded
Delegated to: Albert ARIBAUD
Headers show

Comments

Benoît Thébaudeau - April 9, 2013, 7:48 p.m.
The purpose of .globl is to export symbols for ld, not to declare external
symbols.

By the way, use the ENTRY() and ENDPROC() macros to define functions rather than
using .global directly.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
---
Changes in v11: None
Changes in v10:
 - Rebase on current u-boot-arm/master.

Changes in v9: None
Changes in v8:
 - Use ENTRY() and ENDPROC() to define functions.

Changes in v7: None
Changes in v6:
 - New patch.

Changes in v5: None
Changes in v4: None
Changes in v3: None
Changes in v2: None

 arch/arm/lib/crt0.S |   28 ++++------------------------
 1 file changed, 4 insertions(+), 24 deletions(-)

Patch

diff --git a/arch/arm/lib/crt0.S b/arch/arm/lib/crt0.S
index 37d9927..1524f7e 100644
--- a/arch/arm/lib/crt0.S
+++ b/arch/arm/lib/crt0.S
@@ -24,6 +24,7 @@ 
 
 #include <config.h>
 #include <asm-offsets.h>
+#include <linux/linkage.h>
 
 /*
  * This file handles the target-independent stages of the U-Boot
@@ -67,33 +68,10 @@ 
  */
 
 /*
- * declare nand_boot() or board_init_r() to jump to at end of crt0
- */
-
-#if defined(CONFIG_NAND_SPL)
-
-.globl nand_boot
-
-#elif ! defined(CONFIG_SPL_BUILD)
-
-.globl board_init_r
-
-#endif
-
-/*
- * start and end of BSS
- */
-
-.globl __bss_start
-.globl __bss_end
-
-/*
  * entry point of crt0 sequence
  */
 
-.global _main
-
-_main:
+ENTRY(_main)
 
 /*
  * Set up initial C runtime environment and call board_init_f(0).
@@ -171,3 +149,5 @@  clbss_l:cmp	r0, r1			/* while not at end of BSS */
 	/* we should not return here. */
 
 #endif
+
+ENDPROC(_main)