[U-Boot] [PATCH 1/6] km: modify Kconfig file organization for KM boards

Pascal Linder pascal.linder at edu.hefr.ch
Tue Jun 18 06:41:00 UTC 2019


As preparation for the upcoming transferring of configurations from header
files to Kconfig, a common Kconfig file for all KM boards was created. For
the moment, it only sources the other three, more specific, Kconfig files.
Therefore, the architecture Kconfig files now include the common Kconfig
file. Also, the configuration selection for KM boards was moved from the
architecture Kconfig files to the board specific Kconfig files.

Signed-off-by: Pascal Linder <pascal.linder at edu.hefr.ch>
Signed-off-by: Holger Brunck <holger.brunck at ch.abb.com>
Cc: Mario Six <mario.six at gdsys.cc>
Cc: Prabhakar Kushwaha <prabhakar.kushwaha at nxp.com>
---
 arch/arm/mach-kirkwood/Kconfig   |  9 +++------
 arch/powerpc/cpu/mpc83xx/Kconfig | 12 ++++--------
 arch/powerpc/cpu/mpc85xx/Kconfig |  8 ++------
 board/keymile/Kconfig            | 16 ++++++++++++++++
 board/keymile/km83xx/Kconfig     | 16 ++++++++++++++++
 board/keymile/km_arm/Kconfig     |  7 +++++++
 board/keymile/kmp204x/Kconfig    |  8 ++++++++
 7 files changed, 56 insertions(+), 20 deletions(-)
 create mode 100644 board/keymile/Kconfig

diff --git a/arch/arm/mach-kirkwood/Kconfig b/arch/arm/mach-kirkwood/Kconfig
index 3b860c4f55..8495aabc97 100644
--- a/arch/arm/mach-kirkwood/Kconfig
+++ b/arch/arm/mach-kirkwood/Kconfig
@@ -32,11 +32,8 @@ config TARGET_ICONNECT
 	bool "iconnect Board"
 
 config TARGET_KM_KIRKWOOD
-	bool "KM_KIRKWOOD Board"
-	select BOARD_LATE_INIT
-	imply CMD_CRAMFS
-	imply CMD_DIAG
-	imply FS_CRAMFS
+	bool "KM Kirkwood Board"
+	select VENDOR_KM
 
 config TARGET_NET2BIG_V2
 	bool "LaCie 2Big Network v2 NAS Board"
@@ -79,7 +76,7 @@ source "board/buffalo/lsxl/Kconfig"
 source "board/cloudengines/pogo_e02/Kconfig"
 source "board/d-link/dns325/Kconfig"
 source "board/iomega/iconnect/Kconfig"
-source "board/keymile/km_arm/Kconfig"
+source "board/keymile/Kconfig"
 source "board/LaCie/net2big_v2/Kconfig"
 source "board/LaCie/netspace_v2/Kconfig"
 source "board/raidsonic/ib62x0/Kconfig"
diff --git a/arch/powerpc/cpu/mpc83xx/Kconfig b/arch/powerpc/cpu/mpc83xx/Kconfig
index 571cf8fc2e..9c96b8afc9 100644
--- a/arch/powerpc/cpu/mpc83xx/Kconfig
+++ b/arch/powerpc/cpu/mpc83xx/Kconfig
@@ -68,19 +68,15 @@ config TARGET_IDS8313
 
 config TARGET_KM8360
 	bool "Support km8360"
-	imply CMD_CRAMFS
-	imply CMD_DIAG
-	imply FS_CRAMFS
+	select VENDOR_KM
 
 config TARGET_SUVD3
 	bool "Support suvd3"
-	imply CMD_CRAMFS
-	imply FS_CRAMFS
+	select VENDOR_KM
 
 config TARGET_TUXX1
 	bool "Support tuxx1"
-	imply CMD_CRAMFS
-	imply FS_CRAMFS
+	select VENDOR_KM
 
 config TARGET_TQM834X
 	bool "Support TQM834x"
@@ -107,7 +103,7 @@ source "board/freescale/mpc8349itx/Kconfig"
 source "board/freescale/mpc837xemds/Kconfig"
 source "board/freescale/mpc837xerdb/Kconfig"
 source "board/ids/ids8313/Kconfig"
-source "board/keymile/km83xx/Kconfig"
+source "board/keymile/Kconfig"
 source "board/mpc8308_p1m/Kconfig"
 source "board/sbc8349/Kconfig"
 source "board/tqc/tqm834x/Kconfig"
diff --git a/arch/powerpc/cpu/mpc85xx/Kconfig b/arch/powerpc/cpu/mpc85xx/Kconfig
index 0057f195b3..d2b64328a2 100644
--- a/arch/powerpc/cpu/mpc85xx/Kconfig
+++ b/arch/powerpc/cpu/mpc85xx/Kconfig
@@ -412,11 +412,7 @@ config TARGET_CONTROLCENTERD
 
 config TARGET_KMP204X
 	bool "Support kmp204x"
-	select ARCH_P2041
-	select PHYS_64BIT
-	select FSL_DDR_INTERACTIVE
-	imply CMD_CRAMFS
-	imply FS_CRAMFS
+	select VENDOR_KM
 
 config TARGET_XPEDITE520X
 	bool "Support xpedite520x"
@@ -1593,7 +1589,7 @@ source "board/freescale/t208xrdb/Kconfig"
 source "board/freescale/t4qds/Kconfig"
 source "board/freescale/t4rdb/Kconfig"
 source "board/gdsys/p1022/Kconfig"
-source "board/keymile/kmp204x/Kconfig"
+source "board/keymile/Kconfig"
 source "board/sbc8548/Kconfig"
 source "board/socrates/Kconfig"
 source "board/varisys/cyrus/Kconfig"
diff --git a/board/keymile/Kconfig b/board/keymile/Kconfig
new file mode 100644
index 0000000000..e30d64818c
--- /dev/null
+++ b/board/keymile/Kconfig
@@ -0,0 +1,16 @@
+# SPDX-License-Identifier: GPL-2.0+
+#
+# Copyright (C) 2019, Pascal Linder <pascal.linder at edu.hefr.ch>
+
+config VENDOR_KM
+	bool
+	help
+	  Selected by any KM board to have additional configurations.
+
+if VENDOR_KM
+
+source "board/keymile/km83xx/Kconfig"
+source "board/keymile/kmp204x/Kconfig"
+source "board/keymile/km_arm/Kconfig"
+
+endif
diff --git a/board/keymile/km83xx/Kconfig b/board/keymile/km83xx/Kconfig
index d6c594c96a..9bb1a74ddd 100644
--- a/board/keymile/km83xx/Kconfig
+++ b/board/keymile/km83xx/Kconfig
@@ -9,6 +9,12 @@ config SYS_VENDOR
 config SYS_CONFIG_NAME
 	default "km8360"
 
+config BOARD_SPECIFIC_OPTIONS # dummy
+	def_bool y
+	imply CMD_CRAMFS
+	imply CMD_DIAG
+	imply FS_CRAMFS
+
 endif
 
 if TARGET_SUVD3
@@ -22,6 +28,11 @@ config SYS_VENDOR
 config SYS_CONFIG_NAME
 	default "suvd3"
 
+config BOARD_SPECIFIC_OPTIONS # dummy
+	def_bool y
+	imply CMD_CRAMFS
+	imply FS_CRAMFS
+
 endif
 
 if TARGET_TUXX1
@@ -35,4 +46,9 @@ config SYS_VENDOR
 config SYS_CONFIG_NAME
 	default "tuxx1"
 
+config BOARD_SPECIFIC_OPTIONS # dummy
+	def_bool y
+	imply CMD_CRAMFS
+	imply FS_CRAMFS
+
 endif
diff --git a/board/keymile/km_arm/Kconfig b/board/keymile/km_arm/Kconfig
index 3476780847..2542f1ea8f 100644
--- a/board/keymile/km_arm/Kconfig
+++ b/board/keymile/km_arm/Kconfig
@@ -9,4 +9,11 @@ config SYS_VENDOR
 config SYS_CONFIG_NAME
 	default "km_kirkwood"
 
+config BOARD_SPECIFIC_OPTIONS # dummy
+	def_bool y
+	select BOARD_LATE_INIT
+	imply CMD_CRAMFS
+	imply CMD_DIAG
+	imply FS_CRAMFS
+
 endif
diff --git a/board/keymile/kmp204x/Kconfig b/board/keymile/kmp204x/Kconfig
index 7b45a13cfb..f74d4295c7 100644
--- a/board/keymile/kmp204x/Kconfig
+++ b/board/keymile/kmp204x/Kconfig
@@ -9,4 +9,12 @@ config SYS_VENDOR
 config SYS_CONFIG_NAME
 	default "kmp204x"
 
+config BOARD_SPECIFIC_OPTIONS # dummy
+	def_bool y
+	select ARCH_P2041
+	select FSL_DDR_INTERACTIVE
+	select PHYS_64BIT
+	imply CMD_CRAMFS
+	imply FS_CRAMFS
+
 endif
-- 
2.21.0



More information about the U-Boot mailing list