kconfig: switch to Kconfig

This commit enables Kconfig.
Going forward, we use Kconfig for board configuration.
mkconfig will never be used. Nor will include/config.mk be generated.

Kconfig must be adjusted for U-Boot because our situation is
a little more complicated than Linux Kernel.
We have to generate multiple binary images (Full U-Boot, SPL, TPL)
from one source tree.
Each image needs each configuration input.

In order to keep this scheme in Kconfig, some files must be modified.
But the modification should be minimum.

The location of Kconfig related files is as follows:

 [1] Full U-Boot image
   - configs/<board>_defconfig        (default configuration)
   - .config                          (saved config list)
   - include/config/auto.conf         (for use in makefiles)
   - include/generated/autoconf.h     (for use in C sources)
   - include/config/*                 (for if_changed_dep)

 [2] SPL
   - configs/spl/<board>_defconfig    (default configuration)
   - spl/.config                      (saved config list)
   - spl/include/config/auto.conf     (for use in makefiles)
   - spl/include/generated/autoconf.h (for use in C sources)
   - spl/include/config/*             (for if_changed_dep)

 [3] TPL
   - configs/tpl/<board>_defconfig    (default configuration)
   - tpl/.config                      (saved config list)
   - tpl/include/config/auto.conf     (for use in makefiles)
   - tpl/include/generated/autoconf.h (for use in C sources)
   - tpl/include/config/*             (for if_changed_dep)

Usage:

Execute "make <board>_defconfig" to configure board and then run "make".
Or "make <board>_defconfig all" to configure and build in one time.

You can use "make config", "make menuconfig" etc. to create
a new .config or modify the existing one.

In Kconfig for U-boot, the configuration is done on three levels at most.

By the way, there is another item worth remarking here:
coexistence of Kconfig and board herder files.

Prior to Kconfig, we used C headers to define define a set of configs.

We expect a very long term to move existing config macros to Kconfig.
Two different infractructure must coexist in the interim.

In our former configuration scheme, include/autoconf.mk was generated
for the use in makefiles.
It is still generated under include/, spl/include/, tpl/include/ directory
for the full, SPL, TPL image, respectively.

Series-changes: 2
  - Put dirty build rule into scripts/multiple_config.sh and
    scripts/Makefile.autoconf
  - Fix dependency tracking.
    In v1, any change to Kconfig triggered re-complile of all objects.
    In this version, re-compile is kept at a minimum.
  - Fix a clean-source check
    In v1, clean source tree check did not work correctly for
    out-of-tree build.
Don't send: do not clean scripts/kconfig/* by make mrproper
MAKEALL: adjust for Kconfig

Use "make <board>_defconfig" instead of "make <board>_config".

FIXME!
This fixup is bad because it spends still depends on boards.cfg
to support options such as -a <ARCH>, -c <CPU> etc.
We want to delete it when switching to Kconfig.

We have to invent another method without using boards.cfg.
buildman: adjust for Kconfig

Use "make <board>_defconfig" instead of "make <board>_config".

FIXME!
This fixup is bad because it spends still depends on boards.cfg
to support options such as -a <ARCH>, -c <CPU> etc.
We want to delete it when switching to Kconfig.

We have to invent another method without using boards.cfg.
MAKEALL: Show configuration
kconfig: delete redundant CONFIG_${ARCH} definition

CONFIG_${ARCH} is defined by Kconfig.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
kbuild: remove CONFIG_SPL/CONFIG_TPL definition in config headers

CONFIG_SPL and CONFIG_TPL are defined in Kconfig.

Remove the redundant definition in config headers.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
kconfig: remove old script

mkconfig is no longer used in Kconfig.
kconfig: add CONFIG_CROSS_COMPILE

Copy from Linux Kernel (with a few adjustments in comments).
kconfig: Add CONFIG_CC_OPTIMIZE_FOR_SIZE
Do not apply: tools: add updatedefconfig
Do not apply: tools: move_config
build: split CONFIG_SPL_TEXT_BASE into two different macros

We are about to move CONFIG_SPL_TEXT_BASE from header files to defconfig.
But we cannot move them as they are.

The problem is that #ifdef statements are used in board headers with
TPL support. Like this:

  #ifdef CONFIG_TPL_BUILD
  #define CONFIG_SPL_TEXT_BASE    0xD0001000
  #elif defined(CONFIG_SPL_BUILD)
  #define CONFIG_SPL_TEXT_BASE    0xff800000
  #endif

We cannot describe conditinal statments in defconfig.
One possible solution is to add CONFIG_TPL_TEXT_BASE.

This commit modifies the code as follow:

  #ifdef CONFIG_TPL_BUILD
  #define CONFIG_TPL_TEXT_BASE    0xD0001000
  #elif defined(CONFIG_SPL_BUILD)
  #define CONFIG_SPL_TEXT_BASE    0xff800000
  #endif

(include/config_fallbakcs.h should also be tweaked because some other
parts still reference to CONFIG_SPL_TEXT_BASE)

In the next commit, it will be converted into defconfig like this:

  CONFIG_SPL_TEXT_BASE=0xff800000
  CONFIG_TPL_TEXT_BASE=0xd0001000
kconfig: move CONFIG_{SPL,TPL}_TEXT_BASE to Kconfig

This commit was automatically generated by a conversion tool.
remove CONFIG_{SPL,TPL}_TEXT_BASE from config headers