Hi Daniel,
> agree. But at first we should introduce Kconfig files in all arch, > CPU, SOC, SOC common, board vendor, board and driver directories where > we put all CONFIG_SYS_ symbols. We also need to convert the current > config options for CPU, SOC, vendor and board. For example: > > CONFIG_SYS_CPU="armv7" > CONFIG_SOC_DIR=y > CONFIG_SYS_SOC="tegra30" > CONFIG_SYS_BOARD="beaver" > CONFIG_VENDOR_DIR=y > CONFIG_SYS_VENDOR="nvidia" > CONFIG_SYS_CONFIG_NAME="beaver" > > should be converted to something like this: > > CONFIG_CPU_ARMV7=y > CONFIG_SOC_TEGRA30=y > CONFIG_VENDOR_NVIDIA=y > CONFIG_BOARD_BEAVER=y > > Then we can use the Kconfig symbol dependencies to create a minimal > working board config. For example: > > board/nvidia/beaver/Kconfig: > config BOARD_BEAVER > bool "board description" > select VENDOR_NVIDIA > select SOC_TEGRA30 > select SPL > ... > > arch/arm/cpu/armv7/tegra30/Kconfig: > config SOC_TEGRA30 > bool > select ARMV7 > ... > > The beaver_defconfig file could reduced then to > "CONFIG_BOARD_BEAVER=y" and some default user-editable options. Basicly I think it's a good idea, but I am afraid there are some problems. [1] First, in this case, how can we select the target board? Like this? choice prompt "Board select" default BOARD_SANDBOX config BOARD_VEXPRESS_AEMV8A bool "vexpress_aemv8a board" config BOARD_ARCANGEL4 bool "arcangel4 board" [ Snip: a thousand of boards ] endchoice If we run "make config", a bunch of board choices would be displayed and be gone away quickly. For "make menuconfig", it would be hard to select the board you are aiming at. Maybe we should choose it in the top-down order? Like this? (1) 1st Level : Architecture select choice prompt "Architecture select" config ARM bool "ARM architecture" ..... (2) 2rd Level: CPU select choice prompt "CPU select" depends on ARM config CPU_ARMV7 bool "ARM v7" .... (3) 3rd level: SoC select choice prompt "SoC select" depends on CPU_ARMV7 config SOC_TEGRA bool "Tegra SoC" ..... (4) 4th level: Board select choice prompt "Board select" depends on SOC_TEGRA config BOARD_BEAVER bool "Tegra SoC" [2] CONFIG_CPU_ CONFIG_SOC_ CONFIG_VENDOR_ CONFIG_BOARD_ are systematic prefixes and easy to understand. But there are already some macros bound to specific CPUs, SoCs. For example, CONFIG_SOC_TEGRA30 would be the same as existing CONFIG_TEGRA30. We will have to merge macros with the same meaning. [3] How to select board directoy by using boolean macros. If we try to emulate arch/arm/Makefile of Linux, board-$(CONFIG_BOARD_VEXPRESS_AEMV8A) := vexpress_aemv8a board-$(CONFIG_BOARD_AXS101) := axs101 board-$(CONFIG_BOARD_ARCANGEL4) := arcangel4 Like this? Best Regards Masahiro Yamada _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot