]> www.infradead.org Git - users/rw/ppcboot.git/commitdiff
Fix bugs in OXC flash driver
authorwdenk <wdenk>
Wed, 22 May 2002 00:55:04 +0000 (00:55 +0000)
committerwdenk <wdenk>
Wed, 22 May 2002 00:55:04 +0000 (00:55 +0000)
board/oxc/flash.c
include/config_OXC.h

index d4d4c09229bfcd6ed2cbb153009c8fd613c553fd..32512a3fee398fdf2343cbbad83dd1f22c5161c5 100644 (file)
@@ -6,7 +6,7 @@
  * (C) Copyright 2000
  * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
  *
- * Flash Routines for STM29W320DB flash chips
+ * Flash Routines for STM29W320DB/STM29W800D flash chips
  *
  *--------------------------------------------------------------------
  * See file CREDITS for list of people who contributed to this
@@ -65,8 +65,7 @@ unsigned long flash_init (void)
        flash_get_size((vu_char *)(-size), &flash_info[0]);
     }
 
-#if (CFG_MONITOR_BASE >= CFG_FLASH0_BASE) || \
-    (CFG_MONITOR_BASE >= CFG_FLASH1_BASE)
+#if (CFG_MONITOR_BASE >= CFG_FLASH_PRELIMBASE)
     /* monitor protection ON by default */
     flash_protect(FLAG_PROTECT_SET,
                  CFG_MONITOR_BASE,
index 4399bde8c16fb6d747f0f4351070c0a42de2320e..61ec6f54f190368b874298eb96f9e4917b68b5e7 100644 (file)
  * FLASH
  */
 
-#define CFG_FLASH0_BASE                0xFFF00000
-#define CFG_FLASH1_BASE                0xFFE00000
-#define CFG_FLASH_BASE         (0-flash_info[0].size)
 #define CFG_FLASH_PRELIMBASE   0xFF800000
+#define CFG_FLASH_BASE         (0-flash_info[0].size)
 
 #define CFG_MAX_FLASH_BANKS    1       /* max number of memory banks           */
 #define CFG_MAX_FLASH_SECT     32      /* max number of sectors on one chip    */
 #define CFG_MONITOR_BASE       TEXT_BASE
 #define CFG_MONITOR_LEN                0x00030000
 
-#if (CFG_MONITOR_BASE < CFG_FLASH0_BASE) && \
-    (CFG_MONITOR_BASE < CFG_FLASH1_BASE)
+#if (CFG_MONITOR_BASE < CFG_FLASH_PRELIMBASE)
 # define CFG_RAMBOOT           1
 #else
 # undef CFG_RAMBOOT