From 6336584232bc6fe4ae5e14cb0b95f931674b38f3 Mon Sep 17 00:00:00 2001 From: Michal Simek Date: Mon, 24 Sep 2012 15:35:02 +0200 Subject: [PATCH] zynq: Synchronize NAND support Signed-off-by: Michal Simek --- include/configs/zynq_afx.h | 15 ++------------- include/configs/zynq_common.h | 8 ++++++++ include/configs/zynq_ep107.h | 11 +---------- include/configs/zynq_zc770.h | 16 +--------------- 4 files changed, 12 insertions(+), 38 deletions(-) diff --git a/include/configs/zynq_afx.h b/include/configs/zynq_afx.h index d8181f922b6..27c19826d04 100644 --- a/include/configs/zynq_afx.h +++ b/include/configs/zynq_afx.h @@ -27,6 +27,8 @@ # undef CONFIG_SYS_NO_FLASH #elif defined(CONFIG_AFX_QSPI) # define CONFIG_ZYNQ_SPI +#elif defined(CONFIG_AFX_NAND) +# define CONFIG_NAND_ZYNQ #endif @@ -47,17 +49,4 @@ #endif #endif -/* - * NAND Flash settings - */ -#if defined(CONFIG_AFX_NAND) -#define CONFIG_NAND_ZYNQ -#define CONFIG_CMD_NAND -#define CONFIG_CMD_NAND_LOCK_UNLOCK -#define CONFIG_SYS_MAX_NAND_DEVICE 1 -#define CONFIG_SYS_NAND_BASE XPSS_NAND_BASEADDR -#define CONFIG_SYS_NAND_ONFI_DETECTION -#define CONFIG_MTD_DEVICE -#endif - #endif /* __CONFIG_ZYNQ_AFX_H */ diff --git a/include/configs/zynq_common.h b/include/configs/zynq_common.h index e0b722408e5..73f64bc5db4 100644 --- a/include/configs/zynq_common.h +++ b/include/configs/zynq_common.h @@ -146,6 +146,14 @@ # define CONFIG_DOS_PARTITION #endif +#ifdef CONFIG_NAND_ZYNQ +# define CONFIG_CMD_NAND +# define CONFIG_CMD_NAND_LOCK_UNLOCK +# define CONFIG_SYS_MAX_NAND_DEVICE 1 +# define CONFIG_SYS_NAND_BASE XPSS_NAND_BASEADDR +# define CONFIG_SYS_NAND_ONFI_DETECTION +# define CONFIG_MTD_DEVICE +#endif /* For development/debugging */ #ifdef DEBUG diff --git a/include/configs/zynq_ep107.h b/include/configs/zynq_ep107.h index f652e34d4d6..347777e351a 100644 --- a/include/configs/zynq_ep107.h +++ b/include/configs/zynq_ep107.h @@ -30,6 +30,7 @@ #define CONFIG_MMC #define CONFIG_ZYNQ_SPI +#define CONFIG_NAND_ZYNQ #include @@ -73,16 +74,6 @@ #undef CONFIG_FIT #undef CONFIG_FIT_VERBOSE -/* - * NAND Flash settings - */ -#define CONFIG_NAND_ZYNQ -#define CONFIG_CMD_NAND -#define CONFIG_CMD_NAND_LOCK_UNLOCK -#define CONFIG_SYS_MAX_NAND_DEVICE 1 -#define CONFIG_SYS_NAND_BASE XPSS_NAND_BASEADDR -#define CONFIG_SYS_NAND_ONFI_DETECTION -#define CONFIG_MTD_DEVICE /* Place a Xilinx Boot ROM header in u-boot image? */ #define CONFIG_ZYNQ_XILINX_FLASH_HEADER diff --git a/include/configs/zynq_zc770.h b/include/configs/zynq_zc770.h index 8af52ed6cda..f2c07a2c947 100644 --- a/include/configs/zynq_zc770.h +++ b/include/configs/zynq_zc770.h @@ -31,6 +31,7 @@ #elif defined(CONFIG_ZC770_XM011) # define CONFIG_ZYNQ_SERIAL_UART1 +# define CONFIG_NAND_ZYNQ #elif defined(CONFIG_ZC770_XM012) # define CONFIG_ZYNQ_SERIAL_UART1 @@ -64,19 +65,4 @@ #endif #endif - -/* - * NAND Flash settings - */ -#if defined(CONFIG_ZC770_XM011) -#define CONFIG_NAND_ZYNQ -#define CONFIG_CMD_NAND -#define CONFIG_CMD_NAND_LOCK_UNLOCK -#define CONFIG_SYS_MAX_NAND_DEVICE 1 -#define CONFIG_SYS_NAND_BASE XPSS_NAND_BASEADDR -#define CONFIG_SYS_NAND_ONFI_DETECTION -#define CONFIG_MTD_DEVICE -#endif - - #endif /* __CONFIG_ZYNQ_ZC770_H */ -- 2.47.3