summaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
authorstroese <stroese>2003-12-09 14:54:43 +0000
committerstroese <stroese>2003-12-09 14:54:43 +0000
commitb828dda657dd26b5580c4a85e5680a5d16352a4c (patch)
tree60eed193717770e0ac566e362c36d706d9a35301 /board
parent4e5ca3eb670460cd5ad9b07fa4aafc0dee6178be (diff)
downloadu-boot-imx-b828dda657dd26b5580c4a85e5680a5d16352a4c.zip
u-boot-imx-b828dda657dd26b5580c4a85e5680a5d16352a4c.tar.gz
u-boot-imx-b828dda657dd26b5580c4a85e5680a5d16352a4c.tar.bz2
BUBINGA405EP port fixed.
Diffstat (limited to 'board')
-rw-r--r--board/bubinga405ep/bubinga405ep.c18
-rw-r--r--board/bubinga405ep/flash.c37
2 files changed, 31 insertions, 24 deletions
diff --git a/board/bubinga405ep/bubinga405ep.c b/board/bubinga405ep/bubinga405ep.c
index eb9baf4..8694ebe 100644
--- a/board/bubinga405ep/bubinga405ep.c
+++ b/board/bubinga405ep/bubinga405ep.c
@@ -23,7 +23,6 @@
long int spd_sdram (void);
#include <common.h>
-#include "bubinga405ep.h"
#include <asm/processor.h>
@@ -82,18 +81,11 @@ int checkboard (void)
unsigned char *s = getenv ("serial#");
unsigned char *e;
- puts ("Board: ");
-
- if (!s || strncmp (s, "BUBINGA405EP", 9)) {
- puts ("### No HW ID - assuming WALNUT405");
- } else {
- for (e = s; *e; ++e) {
- if (*e == ' ')
- break;
- }
- for (; s < e; ++s) {
- putc (*s);
- }
+ puts ("Board: IBM 405EP Eval Board");
+
+ if (s != NULL) {
+ puts (", serial# ");
+ puts (s);
}
putc ('\n');
diff --git a/board/bubinga405ep/flash.c b/board/bubinga405ep/flash.c
index 6a9907c..d4bd7ee 100644
--- a/board/bubinga405ep/flash.c
+++ b/board/bubinga405ep/flash.c
@@ -101,6 +101,11 @@ unsigned long flash_init (void)
FLASH_BASE0_PRELIM,
FLASH_BASE0_PRELIM+CFG_MONITOR_LEN-1,
&flash_info[0]);
+ /* Also protect sector containing initial power-up instruction */
+ (void)flash_protect(FLAG_PROTECT_SET,
+ 0xFFFFFFFC,
+ 0xFFFFFFFF,
+ &flash_info[0]);
size_b1 = 0 ;
flash_info[0].size = size_b0;
}
@@ -143,6 +148,16 @@ unsigned long flash_init (void)
base_b0+size_b0-CFG_MONITOR_LEN,
base_b0+size_b0-1,
&flash_info[0]);
+ /* Also protect sector containing initial power-up instruction */
+ /* (flash_protect() checks address range - other call ignored) */
+ (void)flash_protect(FLAG_PROTECT_SET,
+ 0xFFFFFFFC,
+ 0xFFFFFFFF,
+ &flash_info[0]);
+ (void)flash_protect(FLAG_PROTECT_SET,
+ 0xFFFFFFFC,
+ 0xFFFFFFFF,
+ &flash_info[1]);
if (size_b1) {
/* Re-do sizing to get full correct info */
@@ -493,18 +508,18 @@ int wait_for_DQ7(flash_info_t *info, int sect)
volatile FLASH_WORD_SIZE *addr = (FLASH_WORD_SIZE *)(info->start[sect]);
start = get_timer (0);
- last = start;
- while ((addr[0] & (FLASH_WORD_SIZE)0x00800080) != (FLASH_WORD_SIZE)0x00800080) {
- if ((now = get_timer(start)) > CFG_FLASH_ERASE_TOUT) {
- printf ("Timeout\n");
- return -1;
- }
- /* show that we're waiting */
- if ((now - last) > 1000) { /* every second */
- putc ('.');
- last = now;
+ last = 0;
+ while ((addr[0] & (FLASH_WORD_SIZE)0x00800080) != (FLASH_WORD_SIZE)0x00800080) {
+ if ((now = get_timer(start)) > CFG_FLASH_ERASE_TOUT) {
+ printf ("Timeout\n");
+ return -1;
+ }
+ /* show that we're waiting */
+ if ((now - last) > 1000) { /* every second */
+ putc ('.');
+ last = now;
+ }
}
- }
return 0;
}