summaryrefslogtreecommitdiff
path: root/include/configs
diff options
context:
space:
mode:
authorStefan Roese <sr@denx.de>2010-01-21 11:37:31 +0100
committerStefan Roese <sr@denx.de>2010-01-23 09:27:28 +0100
commit9998b1366e7e42089c3f579b4d1d790d3c295387 (patch)
treee751933f22c96238c5eec1a2b4dbb255b22e1b5e /include/configs
parent97c9f29008579f56c3fb86785f29f04dd4f47f94 (diff)
downloadu-boot-imx-9998b1366e7e42089c3f579b4d1d790d3c295387.zip
u-boot-imx-9998b1366e7e42089c3f579b4d1d790d3c295387.tar.gz
u-boot-imx-9998b1366e7e42089c3f579b4d1d790d3c295387.tar.bz2
ppc4xx: Kilauea: Add CPLD version detection and EBC reconfiguration
A newer CPLD version on the 405EX evaluation board requires a different EBC controller setup for the CPLD register access. This patch adds a CPLD version detection for Kilauea and code to reconfigure the EBC controller (chip select 2) for the old CPLD if no new version is found. Additionally the CPLD version is printed upon bootup: Board: Kilauea - AMCC PPC405EX Evaluation Board (CPLD rev. 0) Signed-off-by: Stefan Roese <sr@denx.de> Acked-by: Wolfgang Denk <wd@denx.de> Cc: Zhang Bao Quan <bqzhang@udtech.com.cn>
Diffstat (limited to 'include/configs')
-rw-r--r--include/configs/kilauea.h26
1 files changed, 22 insertions, 4 deletions
diff --git a/include/configs/kilauea.h b/include/configs/kilauea.h
index 8d4ce8d..a79feec 100644
--- a/include/configs/kilauea.h
+++ b/include/configs/kilauea.h
@@ -47,6 +47,7 @@
#define CONFIG_BOARD_EARLY_INIT_F 1 /* Call board_early_init_f */
#define CONFIG_MISC_INIT_R 1 /* Call misc_init_r */
+#define CONFIG_BOARD_TYPES
#define CONFIG_BOARD_EMAC_COUNT
/*-----------------------------------------------------------------------
@@ -520,9 +521,22 @@
#define CONFIG_SYS_EBC_PB1CR (CONFIG_SYS_NAND_ADDR | 0x1e000)
#endif
-/* Memory Bank 2 (FPGA) initialization */
-#define CONFIG_SYS_EBC_PB2AP 0x9400C800
-#define CONFIG_SYS_EBC_PB2CR (CONFIG_SYS_FPGA_BASE | 0x18000)
+/* Memory Bank 2 (FPGA) initialization */
+#define CONFIG_SYS_EBC_PB2AP (EBC_BXAP_BME_ENABLED | \
+ EBC_BXAP_FWT_ENCODE(6) | \
+ EBC_BXAP_BWT_ENCODE(1) | \
+ EBC_BXAP_BCE_DISABLE | \
+ EBC_BXAP_BCT_2TRANS | \
+ EBC_BXAP_CSN_ENCODE(0) | \
+ EBC_BXAP_OEN_ENCODE(0) | \
+ EBC_BXAP_WBN_ENCODE(3) | \
+ EBC_BXAP_WBF_ENCODE(1) | \
+ EBC_BXAP_TH_ENCODE(4) | \
+ EBC_BXAP_RE_DISABLED | \
+ EBC_BXAP_SOR_DELAYED | \
+ EBC_BXAP_BEM_WRITEONLY | \
+ EBC_BXAP_PEN_DISABLED)
+#define CONFIG_SYS_EBC_PB2CR (CONFIG_SYS_FPGA_BASE | 0x18000)
#define CONFIG_SYS_EBC_CFG 0x7FC00000 /* EBC0_CFG */
@@ -571,7 +585,7 @@
* Some Kilauea stuff..., mainly fpga registers
*/
#define CONFIG_SYS_FPGA_REG_BASE CONFIG_SYS_FPGA_BASE
-#define CONFIG_SYS_FPGA_FIFO_BASE (in32(CONFIG_SYS_FPGA_BASE) | (1 << 10))
+#define CONFIG_SYS_FPGA_FIFO_BASE (CONFIG_SYS_FPGA_BASE | (1 << 10))
/* interrupt */
#define CONFIG_SYS_FPGA_SLIC0_R_DPRAM_INT 0x80000000
@@ -602,4 +616,8 @@
#define CONFIG_SYS_FPGA_USER_LED0 0x00000200
#define CONFIG_SYS_FPGA_USER_LED1 0x00000100
+#define CONFIG_SYS_FPGA_MAGIC_MASK 0xffff0000
+#define CONFIG_SYS_FPGA_MAGIC 0xabcd0000
+#define CONFIG_SYS_FPGA_VER_MASK 0x0000ff00
+
#endif /* __CONFIG_H */