summaryrefslogtreecommitdiffstats
path: root/lib_blackfin
diff options
context:
space:
mode:
authorWolfgang Denk <wd@denx.de>2010-04-10 23:59:39 +0200
committerWolfgang Denk <wd@denx.de>2010-04-10 23:59:39 +0200
commitfd4e49c18901a50b1648235f26da1e8caa0f8764 (patch)
treebb0a131be7139806b90ea95ca918619765c674d6 /lib_blackfin
parent30dc165a76b5165af77219189bc05d0fa4229d8b (diff)
parent3f1a5c1655d32b7ab8ae74c79934ce100ebcd2bf (diff)
downloadblackbird-obmc-uboot-fd4e49c18901a50b1648235f26da1e8caa0f8764.tar.gz
blackbird-obmc-uboot-fd4e49c18901a50b1648235f26da1e8caa0f8764.zip
Merge branch 'master' of git://git.denx.de/u-boot-blackfin
Diffstat (limited to 'lib_blackfin')
-rw-r--r--lib_blackfin/board.c14
-rw-r--r--lib_blackfin/config.mk4
-rw-r--r--lib_blackfin/u-boot.lds.S5
3 files changed, 15 insertions, 8 deletions
diff --git a/lib_blackfin/board.c b/lib_blackfin/board.c
index 21fff334a0..4e9bb19226 100644
--- a/lib_blackfin/board.c
+++ b/lib_blackfin/board.c
@@ -73,8 +73,12 @@ static int init_baudrate(void)
static void display_global_data(void)
{
-#ifdef CONFIG_DEBUG_EARLY_SERIAL
bd_t *bd;
+
+#ifndef CONFIG_DEBUG_EARLY_SERIAL
+ return;
+#endif
+
bd = gd->bd;
printf(" gd: %p\n", gd);
printf(" |-flags: %lx\n", gd->flags);
@@ -82,7 +86,6 @@ static void display_global_data(void)
printf(" |-baudrate: %lu\n", gd->baudrate);
printf(" |-have_console: %lx\n", gd->have_console);
printf(" |-ram_size: %lx\n", gd->ram_size);
- printf(" |-reloc_off: %lx\n", gd->reloc_off);
printf(" |-env_addr: %lx\n", gd->env_addr);
printf(" |-env_valid: %lx\n", gd->env_valid);
printf(" |-jt(%p): %p\n", gd->jt, *(gd->jt));
@@ -95,7 +98,6 @@ static void display_global_data(void)
printf(" |-bi_flashstart: %lx\n", bd->bi_flashstart);
printf(" |-bi_flashsize: %lx\n", bd->bi_flashsize);
printf(" \\-bi_flashoffset: %lx\n", bd->bi_flashoffset);
-#endif
}
#define CPLB_PAGE_SIZE (4 * 1024 * 1024)
@@ -197,6 +199,7 @@ void init_cplbtables(void)
* "continue" and != 0 means "fatal error, hang the system".
*/
+extern int watchdog_init(void);
extern int exception_init(void);
extern int irq_init(void);
extern int timer_init(void);
@@ -227,6 +230,11 @@ void board_init_f(ulong bootflag)
dcache_enable();
#endif
+#ifdef CONFIG_WATCHDOG
+ serial_early_puts("Setting up external watchdog\n");
+ watchdog_init();
+#endif
+
#ifdef DEBUG
if (CONFIG_SYS_GBL_DATA_SIZE < sizeof(*gd))
hang();
diff --git a/lib_blackfin/config.mk b/lib_blackfin/config.mk
index 323d28f068..1b5cbbaf29 100644
--- a/lib_blackfin/config.mk
+++ b/lib_blackfin/config.mk
@@ -23,7 +23,7 @@
CROSS_COMPILE ?= bfin-uclinux-
-STANDALONE_LOAD_ADDR = 0x1000
+STANDALONE_LOAD_ADDR = 0x1000 -m elf32bfin
CONFIG_BFIN_CPU := $(strip $(subst ",,$(CONFIG_BFIN_CPU)))
CONFIG_BFIN_BOOT_MODE := $(strip $(subst ",,$(CONFIG_BFIN_BOOT_MODE)))
@@ -33,7 +33,7 @@ CONFIG_ENV_SIZE := $(strip $(subst ",,$(CONFIG_ENV_SIZE)))
PLATFORM_RELFLAGS += -ffixed-P3 -fomit-frame-pointer -mno-fdpic
PLATFORM_CPPFLAGS += -DCONFIG_BLACKFIN
-LDFLAGS += --gc-sections
+LDFLAGS += --gc-sections -m elf32bfin
PLATFORM_RELFLAGS += -ffunction-sections -fdata-sections
ifneq (,$(CONFIG_BFIN_CPU))
diff --git a/lib_blackfin/u-boot.lds.S b/lib_blackfin/u-boot.lds.S
index 3be341fad0..2b23d8ba63 100644
--- a/lib_blackfin/u-boot.lds.S
+++ b/lib_blackfin/u-boot.lds.S
@@ -1,7 +1,7 @@
/*
* U-boot - u-boot.lds.S
*
- * Copyright (c) 2005-2008 Analog Device Inc.
+ * Copyright (c) 2005-2010 Analog Device Inc.
*
* (C) Copyright 2000-2004
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
@@ -29,7 +29,6 @@
#include <asm/blackfin.h>
#undef ALIGN
#undef ENTRY
-#undef bfin
#ifndef LDS_BOARD_TEXT
# define LDS_BOARD_TEXT
@@ -100,7 +99,7 @@ SECTIONS
.data :
{
- . = ALIGN(256);
+ . = ALIGN(4);
*(.data .data.*)
*(.data1)
*(.sdata)
OpenPOWER on IntegriCloud