]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
zynq: Synchronize nor flash
authorMichal Simek <monstr@monstr.eu>
Mon, 24 Sep 2012 12:51:22 +0000 (14:51 +0200)
committerMichal Simek <monstr@monstr.eu>
Mon, 24 Sep 2012 15:13:28 +0000 (17:13 +0200)
Signed-off-by: Michal Simek <monstr@monstr.eu>
include/configs/zynq_afx.h
include/configs/zynq_common.h
include/configs/zynq_cseflash.h
include/configs/zynq_ep107.h
include/configs/zynq_zc70x.h
include/configs/zynq_zc770.h
include/configs/zynq_zed.h

index e266003b8e1a587cdcd0e79d99bde5e0a5c51938..a84659303419779edc040c4b83a9c9fde956d273 100644 (file)
 
 #define CONFIG_ZYNQ_SERIAL_UART1
 
-#include <configs/zynq_common.h>
-
-#if defined(CONFIG_AFX_NOR)
-#undef CONFIG_SYS_NO_FLASH
-#else
 #define CONFIG_SYS_NO_FLASH
+#if defined(CONFIG_AFX_NOR)
+# undef CONFIG_SYS_NO_FLASH
 #endif
 
+
+#include <configs/zynq_common.h>
+
+
+
 #include <config_cmd_default.h>
-#define CONFIG_CMD_SAVEENV     /* Command to save ENV to Flash */
 #define CONFIG_REGINFO         /* Again, debugging */
 #undef CONFIG_CMD_SETGETDCR    /* README says 4xx only */
 #define CONFIG_TIMESTAMP       /* print image timestamp on bootm, etc */
 #define CONFIG_ZYNQ_XILINX_FLASH_HEADER
 #endif
 
-/*
- * NOR Flash Settings
- */
-#ifndef CONFIG_SYS_NO_FLASH
-#define CONFIG_SYS_FLASH_BASE           0xE2000000
-#define CONFIG_SYS_FLASH_SIZE           (16 * 1024 * 1024)
-#define CONFIG_SYS_MAX_FLASH_BANKS      1
-
-/* max number of sectors/blocks on one chip */
-#define CONFIG_SYS_MAX_FLASH_SECT       512
-#define CONFIG_SYS_FLASH_ERASE_TOUT     1000
-#define CONFIG_SYS_FLASH_WRITE_TOUT     5000
-#define CONFIG_FLASH_SHOW_PROGRESS     10
-
-#define CONFIG_SYS_FLASH_CFI
-#undef CONFIG_SYS_FLASH_EMPTY_INFO
-#define CONFIG_FLASH_CFI_DRIVER
-#undef CONFIG_SYS_FLASH_PROTECTION /* don't use hardware protection */
-#define CONFIG_SYS_FLASH_USE_BUFFER_WRITE /* use buffered writes (20x faster) */
-#define CONFIG_ENV_OFFSET              0xC0000         /*768 KB*/
-#define CONFIG_ENV_SECT_SIZE           0x20000         /*128 KB*/
-#define CONFIG_ENV_IS_IN_FLASH
-#ifdef CONFIG_ZYNQ_XILINX_FLASH_HEADER
-#define CONFIG_ZYNQ_XIP_START CONFIG_SYS_FLASH_BASE
-#endif
-#else
-#define CONFIG_ENV_IS_NOWHERE
-#endif
 
 /*
  * Physical Memory map
index 44d2fa1a2ea65c401d60470305306d36d774b4f6..5df1860e3fb796619014f429afccf0e0ff17d4af 100644 (file)
 #endif
 #define CONFIG_SYS_HZ          1000
 
+
+/* no NOR flash */
+#ifdef CONFIG_SYS_NO_FLASH
+# define CONFIG_ENV_IS_NOWHERE
+#else
+# define CONFIG_SYS_FLASH_BASE           0xE2000000
+# define CONFIG_SYS_FLASH_SIZE           (16 * 1024 * 1024)
+# define CONFIG_SYS_MAX_FLASH_BANKS      1
+/* max number of sectors/blocks on one chip */
+# define CONFIG_SYS_MAX_FLASH_SECT       512
+# define CONFIG_SYS_FLASH_ERASE_TOUT     1000
+# define CONFIG_SYS_FLASH_WRITE_TOUT     5000
+# define CONFIG_FLASH_SHOW_PROGRESS    10
+
+# define CONFIG_SYS_FLASH_CFI
+# undef CONFIG_SYS_FLASH_EMPTY_INFO
+# define CONFIG_FLASH_CFI_DRIVER
+
+# undef CONFIG_SYS_FLASH_PROTECTION /* don't use hardware protection */
+# define CONFIG_SYS_FLASH_USE_BUFFER_WRITE /* use buffered writes (20x faster) */
+
+# ifndef CONFIG_ENV_IS_NOWHERE
+#  define CONFIG_ENV_OFFSET            0xC0000         /*768 KB*/
+#  define CONFIG_ENV_SECT_SIZE         0x20000         /*128 KB*/
+#  define CONFIG_ENV_IS_IN_FLASH
+#  define CONFIG_CMD_SAVEENV   /* Command to save ENV to Flash */
+#  ifdef CONFIG_ZYNQ_XILINX_FLASH_HEADER
+#   define CONFIG_ZYNQ_XIP_START CONFIG_SYS_FLASH_BASE
+#  endif
+# endif
+#endif
+
 #include <asm/arch/xparameters.h>
 
 #define CONFIG_SYS_TEXT_BASE 0x04000000
index 5a8e146cc39bab7e1603e51c89e498270cc4b92a..9c370da9ed9aeae9bef51d6707640f96934b18a5 100644 (file)
@@ -4,6 +4,8 @@
 #ifndef __CONFIG_H
 #define __CONFIG_H
 
+#define CONFIG_ENV_IS_NOWHERE
+
 #include <configs/zynq_common.h>
 
 /* Disable uart console */
@@ -19,8 +21,8 @@
  */
 #undef CONFIG_OF_LIBFDT
 
-#undef CONFIG_SYS_NO_FLASH
-#define CONFIG_ENV_IS_NOWHERE
+
+
 
 #include <config_cmd_default.h>
 #undef CONFIG_CMD_PING         /* Might be useful for debugging */
 /* #define CONFIG_ZYNQ_IP_ENV  */
 
 
-#ifndef CONFIG_SYS_NO_FLASH
-
-/* FLASH organization */
-#define CONFIG_SYS_FLASH_BASE           0xE2000000
-#define CONFIG_SYS_FLASH_SIZE           (16 * 1024 * 1024)
-#define CONFIG_SYS_MAX_FLASH_BANKS      1
-/* max number of sectors/blocks on one chip */
-#define CONFIG_SYS_MAX_FLASH_SECT       512
-#define CONFIG_SYS_FLASH_ERASE_TOUT     1000
-#define CONFIG_SYS_FLASH_WRITE_TOUT     5000
-
-#define CONFIG_FLASH_SHOW_PROGRESS     10
-
-#define CONFIG_SYS_FLASH_CFI
-#undef CONFIG_SYS_FLASH_EMPTY_INFO
-#define CONFIG_FLASH_CFI_DRIVER
-
-#undef CONFIG_SYS_FLASH_PROTECTION /* don't use hardware protection */
-#define CONFIG_SYS_FLASH_USE_BUFFER_WRITE /* use buffered writes (20x faster) */
-#endif
 
 /* Because (at least at first) we're going to be loaded via JTAG_Tcl */
 #define CONFIG_SKIP_LOWLEVEL_INIT
index f7bd6ab368b4430b02ab461e08f2f5e18e39c236..710c42064f892639cff5c2f352987a3d956687a7 100644 (file)
                "tftp 0x800000 ramdisk8M.image.gz;" \
                "go 0x8000\0"
 
-/* Uncomment it if you don't want Flash */
-//#define CONFIG_SYS_NO_FLASH
 
 #include <config_cmd_default.h>
 #define CONFIG_CMD_PING                /* Might be useful for debugging */
-#define CONFIG_CMD_SAVEENV     /* Command to save ENV to Flash */
 #define CONFIG_REGINFO         /* Again, debugging */
 #undef CONFIG_CMD_SETGETDCR    /* README says 4xx only */
 
 /* this is to set ipaddr, ethaddr and serverip env variables. */
 #define CONFIG_ZYNQ_IP_ENV
 
-/*
- * NOR Flash Settings
- */
-#ifndef CONFIG_SYS_NO_FLASH
-
-#define CONFIG_SYS_FLASH_BASE           0xE2000000
-#define CONFIG_SYS_FLASH_SIZE           (16 * 1024 * 1024)
-#define CONFIG_SYS_MAX_FLASH_BANKS      1
-/* max number of sectors/blocks on one chip */
-#define CONFIG_SYS_MAX_FLASH_SECT       512
-#define CONFIG_SYS_FLASH_ERASE_TOUT     1000
-#define CONFIG_SYS_FLASH_WRITE_TOUT     5000
-#define CONFIG_FLASH_SHOW_PROGRESS     10
-
-#define CONFIG_SYS_FLASH_CFI
-#undef CONFIG_SYS_FLASH_EMPTY_INFO
-#define CONFIG_FLASH_CFI_DRIVER
-#undef CONFIG_SYS_FLASH_PROTECTION /* don't use hardware protection */
-#define CONFIG_SYS_FLASH_USE_BUFFER_WRITE /* use buffered writes (20x faster) */
-#define CONFIG_ENV_OFFSET              0xC0000         /*768 KB*/
-#define CONFIG_ENV_SECT_SIZE           0x20000         /*128 KB*/
-#define CONFIG_ENV_IS_IN_FLASH
-#else
-#define CONFIG_ENV_IS_NOWHERE
-#endif
 
 /*
  * Physical Memory map
index b6c61eec581b21dc93097b2fe5f531f89028bcf3..09cde5a102eb738d93840a3510e8b250804a8c93 100644 (file)
 #define CONFIG_ZYNQ_GEM0
 #define CONFIG_PHY_ADDR        7
 
+#define CONFIG_SYS_NO_FLASH
+
+
 #include <configs/zynq_common.h>
 
-/* no NOR on zc702 */
-#define CONFIG_SYS_NO_FLASH
-#define CONFIG_ENV_IS_NOWHERE
 
 #include <config_cmd_default.h>
 #define CONFIG_CMD_PING                /* Might be useful for debugging */
index 2f3a249c1020b43dc8573d848f290453853ca8d6..341b85513753e14dc547baaa7c54d46d1d037d8e 100644 (file)
@@ -18,6 +18,7 @@
 #ifndef __CONFIG_ZYNQ_ZC770_H
 #define __CONFIG_ZYNQ_ZC770_H
 
+#define CONFIG_SYS_NO_FLASH
 
 #if defined(CONFIG_ZC770_XM010)
 # define CONFIG_ZYNQ_SERIAL_UART1
@@ -29,6 +30,7 @@
 
 #elif defined(CONFIG_ZC770_XM012)
 # define CONFIG_ZYNQ_SERIAL_UART1
+# undef CONFIG_SYS_NO_FLASH
 
 #elif defined(CONFIG_ZC770_XM013)
 # define CONFIG_ZYNQ_SERIAL_UART0
 # define CONFIG_ZYNQ_SERIAL_UART0
 #endif
 
+
+
+
 #include <configs/zynq_common.h>
 
-#if defined(CONFIG_ZC770_XM012)
-#undef CONFIG_SYS_NO_FLASH
-#else
-#define CONFIG_SYS_NO_FLASH
-#endif
 
 #include <config_cmd_default.h>
-#define CONFIG_CMD_SAVEENV     /* Command to save ENV to Flash */
 #define CONFIG_REGINFO         /* Again, debugging */
 #undef CONFIG_CMD_SETGETDCR    /* README says 4xx only */
 
 #define CONFIG_ZYNQ_XILINX_FLASH_HEADER
 #endif
 
-/*
- * NOR Flash Settings
- */
-#ifndef CONFIG_SYS_NO_FLASH
-
-#define CONFIG_SYS_FLASH_BASE           0xE2000000
-#define CONFIG_SYS_FLASH_SIZE           (16 * 1024 * 1024)
-#define CONFIG_SYS_MAX_FLASH_BANKS      1
-/* max number of sectors/blocks on one chip */
-#define CONFIG_SYS_MAX_FLASH_SECT       512
-#define CONFIG_SYS_FLASH_ERASE_TOUT     1000
-#define CONFIG_SYS_FLASH_WRITE_TOUT     5000
-#define CONFIG_FLASH_SHOW_PROGRESS     10
-
-#define CONFIG_SYS_FLASH_CFI
-#undef CONFIG_SYS_FLASH_EMPTY_INFO
-#define CONFIG_FLASH_CFI_DRIVER
-#undef CONFIG_SYS_FLASH_PROTECTION /* don't use hardware protection */
-#define CONFIG_SYS_FLASH_USE_BUFFER_WRITE /* use buffered writes (20x faster) */
-#define CONFIG_ENV_OFFSET              0xC0000         /*768 KB*/
-#define CONFIG_ENV_SECT_SIZE           0x20000         /*128 KB*/
-#define CONFIG_ENV_IS_IN_FLASH
-#ifdef CONFIG_ZYNQ_XILINX_FLASH_HEADER
-#define CONFIG_ZYNQ_XIP_START CONFIG_SYS_FLASH_BASE
-#endif
-#else
-#define CONFIG_ENV_IS_NOWHERE
-#endif
-
 /*
  * Physical Memory map
  */
index 6a18930c13b94bdc6ab0757140e2946a091e0343..538d65894bdd94e31e5a93835fd46d5dd8dbeb3c 100644 (file)
 #define CONFIG_ZYNQ_GEM0
 #define CONFIG_PHY_ADDR        0
 
+#define CONFIG_SYS_NO_FLASH
+
 #include <configs/zynq_common.h>
 
-/* No NOR Flash available on ZedBoard */
-#define CONFIG_SYS_NO_FLASH
-#define CONFIG_ENV_IS_NOWHERE
+
 
 #undef CONFIG_EXTRA_ENV_SETTINGS
 #define CONFIG_EXTRA_ENV_SETTINGS      \
@@ -52,7 +52,6 @@
 
 #include <config_cmd_default.h>
 #define CONFIG_CMD_PING                /* Might be useful for debugging */
-#define CONFIG_CMD_SAVEENV     /* Command to save ENV to Flash */
 #define CONFIG_REGINFO         /* Again, debugging */
 #undef CONFIG_CMD_SETGETDCR    /* README says 4xx only */