From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from metis.ext.pengutronix.de ([92.198.50.35]) by canuck.infradead.org with esmtps (Exim 4.72 #1 (Red Hat Linux)) id 1Pem92-0003Oq-Pq for barebox@lists.infradead.org; Mon, 17 Jan 2011 10:17:08 +0000 From: Sascha Hauer Date: Mon, 17 Jan 2011 11:16:59 +0100 Message-Id: <1295259421-26338-8-git-send-email-s.hauer@pengutronix.de> In-Reply-To: <1295259421-26338-1-git-send-email-s.hauer@pengutronix.de> References: <1295259421-26338-1-git-send-email-s.hauer@pengutronix.de> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: barebox-bounces@lists.infradead.org Errors-To: barebox-bounces+u.kleine-koenig=pengutronix.de@lists.infradead.org Subject: [PATCH 7/9] x86: use sections.h header file for linker variables To: barebox@lists.infradead.org Signed-off-by: Sascha Hauer --- arch/x86/boot/main_entry.c | 7 ++----- arch/x86/lib/barebox.lds.S | 2 +- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/arch/x86/boot/main_entry.c b/arch/x86/boot/main_entry.c index 5f199e9..d1d8f34 100644 --- a/arch/x86/boot/main_entry.c +++ b/arch/x86/boot/main_entry.c @@ -24,10 +24,7 @@ */ #include - -/* These symbols are generated by the linker */ -extern char __bss_start; -extern char __bss_end; +#include extern void start_barebox(void); @@ -39,6 +36,6 @@ extern void start_barebox(void); void uboot_entry(void) { /* clear the BSS first */ - memset(&__bss_start, 0x00, &__bss_end - &__bss_start); + memset(__bss_start, 0x00, __bss_stop - __bss_start); start_barebox(); } diff --git a/arch/x86/lib/barebox.lds.S b/arch/x86/lib/barebox.lds.S index 2917d2f..e0919a6 100644 --- a/arch/x86/lib/barebox.lds.S +++ b/arch/x86/lib/barebox.lds.S @@ -188,7 +188,7 @@ SECTIONS __bss_start = .; *(.bss*); *( COMMON ) - __bss_end = .; + __bss_stop = .; _end = .; } > barebox } -- 1.7.2.3 _______________________________________________ barebox mailing list barebox@lists.infradead.org http://lists.infradead.org/mailman/listinfo/barebox