kconfig: move CONFIG_OF_* to Kconfig
authorMasahiro Yamada <yamada.m@jp.panasonic.com>
Mon, 22 Sep 2014 10:59:05 +0000 (19:59 +0900)
committerTom Rini <trini@ti.com>
Thu, 25 Sep 2014 13:27:50 +0000 (09:27 -0400)
This commit moves:
  CONFIG_OF_CONTROL
  CONFIG_OF_SEPARATE
  CONFIG_OF_EMBED
  CONFIG_OF_HOSTFILE

Because these options are currently not supported for SPL,
the "Device Tree Control" menu does not appear in the SPL
configuration.

Note:
zynq-common.h should be adjusted so as not to change the
default value of CONFIG_SPL_FAT_LOAD_PAYLOAD_NAME.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
Cc: Stephen Warren <swarren@nvidia.com>
Cc: Minkyu Kang <mk7.kang@samsung.com>
Acked-by: Michal Simek <michal.simek@xilinx.com>
46 files changed:
Kconfig
arch/Kconfig
arch/arm/Kconfig
arch/arm/cpu/armv7/exynos/Kconfig
configs/am335x_boneblack_vboot_defconfig
configs/coreboot-x86_defconfig
configs/microblaze-generic_defconfig
configs/odroid_defconfig
configs/origen_defconfig
configs/s5pc210_universal_defconfig
configs/sandbox_defconfig
configs/trats2_defconfig
configs/trats_defconfig
configs/zynq_microzed_defconfig
configs/zynq_zc70x_defconfig
configs/zynq_zc770_xm010_defconfig
configs/zynq_zc770_xm012_defconfig
configs/zynq_zc770_xm013_defconfig
configs/zynq_zed_defconfig
dts/Kconfig [new file with mode: 0644]
include/configs/am335x_evm.h
include/configs/arndale.h
include/configs/beaver.h
include/configs/cardhu.h
include/configs/colibri_t20_iris.h
include/configs/colibri_t30.h
include/configs/coreboot.h
include/configs/dalmore.h
include/configs/exynos4-dt.h
include/configs/exynos5-dt.h
include/configs/harmony.h
include/configs/jetson-tk1.h
include/configs/medcom-wide.h
include/configs/microblaze-generic.h
include/configs/paz00.h
include/configs/plutux.h
include/configs/sandbox.h
include/configs/seaboard.h
include/configs/tec-ng.h
include/configs/tec.h
include/configs/tegra-common-post.h
include/configs/trimslice.h
include/configs/venice2.h
include/configs/ventana.h
include/configs/whistler.h
include/configs/zynq-common.h

diff --git a/Kconfig b/Kconfig
index fc5e7cd..e0c8992 100644 (file)
--- a/Kconfig
+++ b/Kconfig
@@ -106,6 +106,8 @@ source "arch/Kconfig"
 
 source "common/Kconfig"
 
+source "dts/Kconfig"
+
 source "net/Kconfig"
 
 source "drivers/Kconfig"
index c9ccb7d..bf26764 100644 (file)
@@ -7,6 +7,7 @@ config ARC
 
 config ARM
        bool "ARM architecture"
+       select SUPPORT_OF_CONTROL
 
 config AVR32
        bool "AVR32 architecture"
@@ -19,6 +20,7 @@ config M68K
 
 config MICROBLAZE
        bool "MicroBlaze architecture"
+       select SUPPORT_OF_CONTROL
 
 config MIPS
        bool "MIPS architecture"
@@ -37,6 +39,7 @@ config PPC
 
 config SANDBOX
        bool "Sandbox"
+       select SUPPORT_OF_CONTROL
 
 config SH
        bool "SuperH architecture"
@@ -46,6 +49,7 @@ config SPARC
 
 config X86
        bool "x86 architecture"
+       select SUPPORT_OF_CONTROL
 
 endchoice
 
index 106aed9..3efede2 100644 (file)
@@ -462,6 +462,7 @@ config ZYNQ
 config TEGRA
        bool "NVIDIA Tegra"
        select SPL
+       select OF_CONTROL if !SPL_BUILD
 
 config TARGET_VEXPRESS_AEMV8A
        bool "Support vexpress_aemv8a"
index d132f03..e7c93d8 100644 (file)
@@ -23,18 +23,23 @@ config TARGET_ODROID
 
 config TARGET_ARNDALE
        bool "Exynos5250 Arndale board"
+       select OF_CONTROL if !SPL_BUILD
 
 config TARGET_SMDK5250
        bool "SMDK5250 board"
+       select OF_CONTROL if !SPL_BUILD
 
 config TARGET_SNOW
        bool "Snow board"
+       select OF_CONTROL if !SPL_BUILD
 
 config TARGET_SMDK5420
        bool "SMDK5420 board"
+       select OF_CONTROL if !SPL_BUILD
 
 config TARGET_PEACH_PIT
        bool "Peach Pi board"
+       select OF_CONTROL if !SPL_BUILD
 
 endchoice
 
index 00317c4..af7ceca 100644 (file)
@@ -2,3 +2,4 @@ CONFIG_SPL=y
 CONFIG_SYS_EXTRA_OPTIONS="SERIAL1,CONS_INDEX=1,EMMC_BOOT,ENABLE_VBOOT"
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_AM335X_EVM=y
+CONFIG_OF_CONTROL=y
index a06c527..3cc034a 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="SYS_TEXT_BASE=0x01110000"
 CONFIG_X86=y
 CONFIG_TARGET_COREBOOT=y
+CONFIG_OF_CONTROL=y
index 7f23786..1dc7441 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SPL=y
 +S:CONFIG_MICROBLAZE=y
 +S:CONFIG_TARGET_MICROBLAZE_GENERIC=y
+CONFIG_OF_CONTROL=y
+CONFIG_OF_EMBED=y
index a1c7ac5..98ca447 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_ARM=y
 CONFIG_ARCH_EXYNOS=y
 CONFIG_TARGET_ODROID=y
+CONFIG_OF_CONTROL=y
index aa92381..1d712e8 100644 (file)
@@ -2,3 +2,4 @@ CONFIG_SPL=y
 +S:CONFIG_ARM=y
 +S:CONFIG_ARCH_EXYNOS=y
 +S:CONFIG_TARGET_ORIGEN=y
+CONFIG_OF_CONTROL=y
index a9a3446..0a3ad0d 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_ARM=y
 CONFIG_ARCH_EXYNOS=y
 CONFIG_TARGET_S5PC210_UNIVERSAL=y
+CONFIG_OF_CONTROL=y
index e69de29..84681db 100644 (file)
@@ -0,0 +1,2 @@
+CONFIG_OF_CONTROL=y
+CONFIG_OF_HOSTFILE=y
index fa82724..666011c 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_ARM=y
 CONFIG_ARCH_EXYNOS=y
 CONFIG_TARGET_TRATS2=y
+CONFIG_OF_CONTROL=y
index f888a51..6ef4b33 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_ARM=y
 CONFIG_ARCH_EXYNOS=y
 CONFIG_TARGET_TRATS=y
+CONFIG_OF_CONTROL=y
index 3aedb35..9767863 100644 (file)
@@ -2,3 +2,4 @@ CONFIG_SPL=y
 +S:CONFIG_ARM=y
 +S:CONFIG_ZYNQ=y
 +S:CONFIG_TARGET_ZYNQ_MICROZED=y
+CONFIG_OF_CONTROL=y
index 04c8def..d303f97 100644 (file)
@@ -2,3 +2,4 @@ CONFIG_SPL=y
 +S:CONFIG_ARM=y
 +S:CONFIG_ZYNQ=y
 +S:CONFIG_TARGET_ZYNQ_ZC70X=y
+CONFIG_OF_CONTROL=y
index 1178b40..4e6660f 100644 (file)
@@ -3,3 +3,4 @@ CONFIG_SYS_EXTRA_OPTIONS="ZC770_XM010"
 +S:CONFIG_ARM=y
 +S:CONFIG_ZYNQ=y
 +S:CONFIG_TARGET_ZYNQ_ZC770=y
+CONFIG_OF_CONTROL=y
index 52c2121..16d62e6 100644 (file)
@@ -3,3 +3,4 @@ CONFIG_SYS_EXTRA_OPTIONS="ZC770_XM012"
 +S:CONFIG_ARM=y
 +S:CONFIG_ZYNQ=y
 +S:CONFIG_TARGET_ZYNQ_ZC770=y
+CONFIG_OF_CONTROL=y
index 836809a..7343a64 100644 (file)
@@ -3,3 +3,4 @@ CONFIG_SYS_EXTRA_OPTIONS="ZC770_XM013"
 +S:CONFIG_ARM=y
 +S:CONFIG_ZYNQ=y
 +S:CONFIG_TARGET_ZYNQ_ZC770=y
+CONFIG_OF_CONTROL=y
index 2337906..38d5fa6 100644 (file)
@@ -2,3 +2,4 @@ CONFIG_SPL=y
 +S:CONFIG_ARM=y
 +S:CONFIG_ZYNQ=y
 +S:CONFIG_TARGET_ZYNQ_ZED=y
+CONFIG_OF_CONTROL=y
diff --git a/dts/Kconfig b/dts/Kconfig
new file mode 100644 (file)
index 0000000..20be556
--- /dev/null
@@ -0,0 +1,48 @@
+#
+# Device Tree Control
+#
+# TODO:
+#   This feature is not currently supported for SPL,
+#    but this restriction should be removed in the future.
+
+config SUPPORT_OF_CONTROL
+       bool
+
+menu "Device Tree Control"
+       depends on !SPL_BUILD
+       depends on SUPPORT_OF_CONTROL
+
+config OF_CONTROL
+       bool "Run-time configuration via Device Tree"
+       help
+         This feature provides for run-time configuration of U-Boot
+         via a flattened device tree.
+
+choice
+       prompt "Provider of DTB for DT control"
+       depends on OF_CONTROL
+
+config OF_SEPARATE
+       bool "Separate DTB for DT control"
+       depends on !SANDBOX
+       help
+         If this option is enabled, the device tree will be built and
+         placed as a separate u-boot.dtb file alongside the U-Boot image.
+
+config OF_EMBED
+       bool "Embedded DTB for DT control"
+       help
+         If this option is enabled, the device tree will be picked up and
+         built into the U-Boot image.
+
+config OF_HOSTFILE
+       bool "Host filed DTB for DT control"
+       depends on SANDBOX
+       help
+         If this option is enabled, DTB will be read from a file on startup.
+         This is only useful for Sandbox.  Use the -d flag to U-Boot to
+         specify the file to read.
+
+endchoice
+
+endmenu
index 8fd71fc..6a9fb34 100644 (file)
@@ -23,8 +23,6 @@
 # define CONFIG_TIMESTAMP
 # define CONFIG_LZO
 # ifdef CONFIG_ENABLE_VBOOT
-#  define CONFIG_OF_CONTROL
-#  define CONFIG_OF_SEPARATE
 #  define CONFIG_DEFAULT_DEVICE_TREE am335x-boneblack
 #  define CONFIG_FIT_SIGNATURE
 #  define CONFIG_RSA
index 75f9933..7f06907 100644 (file)
@@ -22,8 +22,6 @@
 #define CONFIG_DISPLAY_CPUINFO
 #define CONFIG_DISPLAY_BOARDINFO
 
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* Allow tracing to be enabled */
 #define CONFIG_TRACE
index d8ed717..4c7cf5f 100644 (file)
@@ -26,8 +26,6 @@
 
 /* Enable fdt support for Beaver. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra30-beaver
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT               "Tegra30 (Beaver) # "
index 59f429c..1616a54 100644 (file)
@@ -26,8 +26,6 @@
 
 /* Enable fdt support for Cardhu. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra30-cardhu
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT               "Tegra30 (Cardhu) # "
index 6f9e08c..3ce1f9b 100644 (file)
@@ -11,8 +11,6 @@
 
 /* Enable FDT support */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-colibri_t20_iris
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT                   "Tegra20 (Colibri) # "
index eacff5b..d9e2d86 100644 (file)
@@ -12,8 +12,6 @@
 #include "tegra30-common.h"
 
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra30-colibri
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 #define V_PROMPT                       "Colibri T30 # "
 #define CONFIG_TEGRA_BOARD_STRING      "Toradex Colibri T30"
index a1a63a0..915245e 100644 (file)
@@ -28,8 +28,6 @@
 
 #define CONFIG_LMB
 #define CONFIG_OF_LIBFDT
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 #define CONFIG_DEFAULT_DEVICE_TREE     link
 
 #define CONFIG_BOOTSTAGE
index fd774a3..e3bb27f 100644 (file)
@@ -23,8 +23,6 @@
 
 /* Enable fdt support for Dalmore. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra114-dalmore
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT               "Tegra114 (Dalmore) # "
index 7dac1a3..99472ac 100644 (file)
 #define CONFIG_BOARD_COMMON
 #define CONFIG_SYS_GENERIC_BOARD
 
-/* Enable fdt support */
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
-
 #define CONFIG_SYS_CACHELINE_SIZE      32
 
 /* input clock of PLL: EXYNOS4 boards have 24MHz input clock */
index a7c6292..1dc3002 100644 (file)
 #define CONFIG_ARCH_EARLY_INIT_R
 #define CONFIG_EXYNOS_SPL
 
-/* Enable fdt support for Exynos5250 */
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
-
 /* Allow tracing to be enabled */
 #define CONFIG_TRACE
 #define CONFIG_CMD_TRACE
index 3ec0e41..97db202 100644 (file)
@@ -13,8 +13,6 @@
 
 /* Enable fdt support for Harmony. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-harmony
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT               "Tegra20 (Harmony) # "
index d03a66c..dc7e324 100644 (file)
@@ -14,8 +14,6 @@
 
 /* Enable fdt support for Jetson TK1. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra124-jetson-tk1
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT                       "Tegra124 (Jetson TK1) # "
index 40155c3..5e52574 100644 (file)
@@ -14,8 +14,6 @@
 
 /* Enable fdt support for Medcom-Wide. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-medcom-wide
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT                       "Tegra20 (Medcom-Wide) # "
index 1a82a57..f5e83ff 100644 (file)
@@ -15,8 +15,6 @@
 #define        MICROBLAZE_V5           1
 
 /* Open Firmware DTS */
-#define CONFIG_OF_CONTROL      1
-#define CONFIG_OF_EMBED                1
 #define CONFIG_DEFAULT_DEVICE_TREE microblaze-generic
 
 /* linear and spi flash memory */
index dd0abf8..01cb649 100644 (file)
@@ -22,8 +22,6 @@
 
 /* Enable fdt support for Paz00. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-paz00
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT               "Tegra20 (Paz00) MOD # "
index a473f23..719d81a 100644 (file)
@@ -14,8 +14,6 @@
 
 /* Enable fdt support for Plutux. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-plutux
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT                       "Tegra20 (Plutux) # "
index f5fa4b3..31a0ff9 100644 (file)
@@ -38,8 +38,6 @@
 /* Number of bits in a C 'long' on this architecture */
 #define CONFIG_SANDBOX_BITS_PER_LONG   64
 
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_HOSTFILE
 #define CONFIG_OF_LIBFDT
 #define CONFIG_LMB
 #define CONFIG_FIT
index fc4f976..e61811d 100644 (file)
@@ -21,8 +21,6 @@
 
 /* Enable fdt support for Seaboard. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-seaboard
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT               "Tegra20 (SeaBoard) # "
index 13baa76..5b4c255 100644 (file)
@@ -12,8 +12,6 @@
 
 /* Enable fdt support for tec-ng. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra30-tec-ng
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT                       "Tegra30 (TEC-NG) # "
index 90e7b7a..0598d5d 100644 (file)
@@ -14,8 +14,6 @@
 
 /* Enable fdt support for TEC. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-tec
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT                       "Tegra20 (TEC) # "
index c337e30..23e3c8a 100644 (file)
@@ -69,7 +69,6 @@
 
 /* remove devicetree support */
 #ifdef CONFIG_OF_CONTROL
-#undef CONFIG_OF_CONTROL
 #endif
 
 /* remove I2C support */
index f81cfa2..2ef010c 100644 (file)
@@ -13,8 +13,6 @@
 
 /* Enable fdt support for TrimSlice. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-trimslice
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT               "Tegra20 (TrimSlice) # "
index 6d4e999..b516d92 100644 (file)
@@ -14,8 +14,6 @@
 
 /* Enable fdt support for Venice2. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra124-venice2
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT                       "Tegra124 (Venice2) # "
index edf3720..3b9d142 100644 (file)
@@ -13,8 +13,6 @@
 
 /* Enable fdt support for Ventana. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-ventana
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT               "Tegra20 (Ventana) # "
index 9e09f03..f3bf806 100644 (file)
@@ -13,8 +13,6 @@
 
 /* Enable fdt support for Whistler. Flash the image in u-boot-dtb.bin */
 #define CONFIG_DEFAULT_DEVICE_TREE     tegra20-whistler
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 
 /* High-level configuration options */
 #define V_PROMPT               "Tegra20 (Whistler) # "
index 4c7a7b0..0b4dd66 100644 (file)
 #define CONFIG_IMAGE_FORMAT_LEGACY /* enable also legacy image format */
 
 /* FDT support */
-#define CONFIG_OF_CONTROL
-#define CONFIG_OF_SEPARATE
 #define CONFIG_DISPLAY_BOARDINFO_LATE
 
 /* RSA support */
 #define CONFIG_SYS_MMC_SD_FAT_BOOT_PARTITION    1
 #define CONFIG_SPL_LIBDISK_SUPPORT
 #define CONFIG_SPL_FAT_SUPPORT
-#if defined(CONFIG_OF_CONTROL) && defined(CONFIG_OF_SEPARATE)
-# define CONFIG_SPL_FAT_LOAD_PAYLOAD_NAME     "u-boot-dtb.img"
-#else
-# define CONFIG_SPL_FAT_LOAD_PAYLOAD_NAME     "u-boot.img"
-#endif
+#define CONFIG_SPL_FAT_LOAD_PAYLOAD_NAME     "u-boot-dtb.img"
 #endif
 
 /* Disable dcache for SPL just for sure */
 #ifdef CONFIG_SPL_BUILD
 #define CONFIG_SYS_DCACHE_OFF
 #undef CONFIG_FPGA
-#undef CONFIG_OF_CONTROL
 #endif
 
 /* Address in RAM where the parameters must be copied by SPL. */