[U-Boot] [PATCH 2/4] zynqmp: Define ep config for ZynqMP

Siva Durga Prasad Paladugu siva.durga.paladugu at xilinx.com
Wed Jun 10 12:20:57 CEST 2015


Define a new config "zynqmp_ep" for ZynqMP instead
of xilinx_zynqmp. This defconfig supports all emulation
platforms of ZynqMP. Also renamed TARGET_XILINX_ZYNQMP
to ARCH_ZYNQMP.

Signed-off-by: Siva Durga Prasad Paladugu <sivadur at xilinx.com>
---
 arch/arm/Kconfig                                   |    2 +-
 arch/arm/cpu/armv8/Makefile                        |    2 +-
 arch/arm/cpu/armv8/zynqmp/Kconfig                  |   12 +++++++-
 ...xilinx_zynqmp_defconfig => zynqmp_ep_defconfig} |    5 ++-
 include/configs/xilinx_zynqmp.h                    |    8 -----
 include/configs/zynqmp_ep.h                        |   29 ++++++++++++++++++++
 6 files changed, 44 insertions(+), 14 deletions(-)
 rename configs/{xilinx_zynqmp_defconfig => zynqmp_ep_defconfig} (71%)
 create mode 100644 include/configs/zynqmp_ep.h

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index ca2c410..ab2f211 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -659,7 +659,7 @@ config ARCH_ZYNQ
 	select SUPPORT_SPL
 	select DM
 
-config TARGET_XILINX_ZYNQMP
+config ARCH_ZYNQMP
 	bool "Support Xilinx ZynqMP Platform"
 	select ARM64
 
diff --git a/arch/arm/cpu/armv8/Makefile b/arch/arm/cpu/armv8/Makefile
index dee5e25..6466ebb 100644
--- a/arch/arm/cpu/armv8/Makefile
+++ b/arch/arm/cpu/armv8/Makefile
@@ -16,4 +16,4 @@ obj-y	+= tlb.o
 obj-y	+= transition.o
 
 obj-$(CONFIG_FSL_LSCH3) += fsl-lsch3/
-obj-$(CONFIG_TARGET_XILINX_ZYNQMP) += zynqmp/
+obj-$(CONFIG_ARCH_ZYNQMP) += zynqmp/
diff --git a/arch/arm/cpu/armv8/zynqmp/Kconfig b/arch/arm/cpu/armv8/zynqmp/Kconfig
index b07932e..cf80b08 100644
--- a/arch/arm/cpu/armv8/zynqmp/Kconfig
+++ b/arch/arm/cpu/armv8/zynqmp/Kconfig
@@ -1,4 +1,12 @@
-if TARGET_XILINX_ZYNQMP
+if ARCH_ZYNQMP
+
+choice
+	prompt "Xilinx ZynqMP board select"
+
+config TARGET_ZYNQMP_EP
+	bool "ZynqMP EP Board"
+
+endchoice
 
 config SYS_BOARD
 	default "zynqmp"
@@ -10,6 +18,6 @@ config SYS_SOC
 	default "zynqmp"
 
 config SYS_CONFIG_NAME
-	default "xilinx_zynqmp"
+	default "zynqmp_ep" if TARGET_ZYNQMP_EP
 
 endif
diff --git a/configs/xilinx_zynqmp_defconfig b/configs/zynqmp_ep_defconfig
similarity index 71%
rename from configs/xilinx_zynqmp_defconfig
rename to configs/zynqmp_ep_defconfig
index c512e9c..6b29eca 100644
--- a/configs/xilinx_zynqmp_defconfig
+++ b/configs/zynqmp_ep_defconfig
@@ -1,6 +1,7 @@
 CONFIG_ARM=y
-CONFIG_TARGET_XILINX_ZYNQMP=y
-CONFIG_DEFAULT_DEVICE_TREE="zynqmp"
+CONFIG_ARCH_ZYNQMP=y
+CONFIG_TARGET_ZYNQMP_EP=y
+CONFIG_DEFAULT_DEVICE_TREE="zynqmp-ep"
 CONFIG_CMD_BDI=y
 CONFIG_CMD_BOOTD=y
 CONFIG_CMD_RUN=y
diff --git a/include/configs/xilinx_zynqmp.h b/include/configs/xilinx_zynqmp.h
index 880d29c..18cd15b 100644
--- a/include/configs/xilinx_zynqmp.h
+++ b/include/configs/xilinx_zynqmp.h
@@ -53,7 +53,6 @@
 #define CONFIG_SYS_MALLOC_LEN		(CONFIG_ENV_SIZE + 0x400000)
 
 /* Serial setup */
-#define CONFIG_ZYNQ_SERIAL_UART0
 #define CONFIG_ZYNQ_SERIAL
 
 #define CONFIG_CONS_INDEX		0
@@ -61,8 +60,6 @@
 #define CONFIG_SYS_BAUDRATE_TABLE \
 	{ 4800, 9600, 19200, 38400, 57600, 115200 }
 
-#define CONFIG_ZYNQ_SDHCI0
-
 /* Command line configuration */
 #define CONFIG_CMD_ENV
 #define CONFIG_CMD_EXT2
@@ -129,9 +126,6 @@
 #define CONFIG_CMDLINE_EDITING
 #define CONFIG_SYS_MAXARGS		64
 
-#define CONFIG_ZYNQ_I2C0
-#define CONFIG_SYS_I2C_ZYNQ
-
 /* I2C */
 #if defined(CONFIG_SYS_I2C_ZYNQ)
 # define CONFIG_CMD_I2C
@@ -140,8 +134,6 @@
 # define CONFIG_SYS_I2C_ZYNQ_SLAVE		0
 #endif
 
-#define CONFIG_ZYNQMP_EEPROM
-
 /* EEPROM */
 #ifdef CONFIG_ZYNQMP_EEPROM
 # define CONFIG_CMD_EEPROM
diff --git a/include/configs/zynqmp_ep.h b/include/configs/zynqmp_ep.h
new file mode 100644
index 0000000..26dd300
--- /dev/null
+++ b/include/configs/zynqmp_ep.h
@@ -0,0 +1,29 @@
+/*
+ * Configuration for Xilinx ZynqMP emulation
+ * platforms. See zynqmp-common.h for ZynqMP
+ * common configs
+ *
+ * (C) Copyright 2014 - 2015 Xilinx, Inc.
+ * Michal Simek <michal.simek at xilinx.com>
+ * Siva Durga Prasad Paladugu <sivadur at xilinx.com>
+ *
+ * Based on Configuration for Versatile Express
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __CONFIG_ZYNQMP_EP_H
+#define __CONFIG_ZYNQMP_EP_H
+
+#define CONFIG_ZYNQ_GEM0
+#define CONFIG_ZYNQ_GEM_PHY_ADDR0	7
+
+#define CONFIG_ZYNQ_SERIAL_UART0
+#define CONFIG_ZYNQ_SDHCI0
+#define CONFIG_ZYNQ_I2C0
+#define CONFIG_SYS_I2C_ZYNQ
+#define CONFIG_ZYNQ_EEPROM
+
+#include <configs/xilinx_zynqmp.h>
+
+#endif /* __CONFIG_ZYNQMP_EP_H */
-- 
1.7.1



More information about the U-Boot mailing list