mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: barebox@lists.infradead.org
Subject: [PATCH 5/9] ARM start.c: use sections.h header file for linker variables
Date: Mon, 17 Jan 2011 11:16:57 +0100	[thread overview]
Message-ID: <1295259421-26338-6-git-send-email-s.hauer@pengutronix.de> (raw)
In-Reply-To: <1295259421-26338-1-git-send-email-s.hauer@pengutronix.de>

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 arch/arm/cpu/start.c |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c
index b55df5d..e0fb712 100644
--- a/arch/arm/cpu/start.c
+++ b/arch/arm/cpu/start.c
@@ -25,6 +25,7 @@
 #include <asm/barebox-arm.h>
 #include <asm/system.h>
 #include <asm-generic/memory_layout.h>
+#include <asm/sections.h>
 
 void __naked __section(.text_entry) exception_vectors(void)
 {
@@ -40,8 +41,6 @@ void __naked __section(.text_entry) exception_vectors(void)
 	);
 }
 
-extern char __bss_start, _end;
-
 /*
  * The actual reset vector. This code is position independent and usually
  * does not run at the address it's linked at.
@@ -108,7 +107,7 @@ void __naked __bare_init board_init_lowlevel_return(void)
 				(unsigned int)&__bss_start - TEXT_BASE);
 
 	/* clear bss */
-	memset(&__bss_start, 0, &_end - &__bss_start);
+	memset(__bss_start, 0, __bss_stop - __bss_start);
 
 	/* call start_barebox with its absolute address */
 	r = (unsigned int)&start_barebox;
-- 
1.7.2.3


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  parent reply	other threads:[~2011-01-17 10:17 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-17 10:16 cleanup " Sascha Hauer
2011-01-17 10:16 ` [PATCH 1/9] ppc pcm030: provide _stext, _text and __bss_stop in linker script Sascha Hauer
2011-01-17 10:16 ` [PATCH 2/9] blackfin: provide " Sascha Hauer
2011-01-17 10:16 ` [PATCH 3/9] ARM: " Sascha Hauer
2011-01-17 10:16 ` [PATCH 4/9] add sections.h header file Sascha Hauer
2011-01-17 10:16 ` Sascha Hauer [this message]
2011-01-17 10:16 ` [PATCH 6/9] ARM: remove unnecessary include Sascha Hauer
2011-01-17 10:16 ` [PATCH 7/9] x86: use sections.h header file for linker variables Sascha Hauer
2011-01-17 10:17 ` [PATCH 8/9] reloc.h: remove linker variables which are now in asm/sections.h Sascha Hauer
2011-01-17 10:17 ` [PATCH 9/9] startup: make debug printing of linker variables work again Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1295259421-26338-6-git-send-email-s.hauer@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox