x86: provide CONFIG_BUILD_ROM

Up to now we depended on an exported variable to build u-boot.rom.
We should be able to specify it in the configuration file, too.

With this patch this becomes possible using the new Kconfig option
CONFIG_BUILD_ROM.

This option depends on CONFIG_X86 and is selected in
qemu-x86_defconfig and qemu-x86_64_defconfig.

Cc: Simon Glass <sjg@chromium.org>
Cc: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
master
Heinrich Schuchardt 7 years ago committed by Bin Meng
parent 83262f99cd
commit 871aa41d4c
  1. 9
      Kconfig
  2. 2
      Makefile
  3. 1
      configs/qemu-x86_64_defconfig
  4. 1
      configs/qemu-x86_defconfig
  5. 10
      doc/README.x86

@ -158,6 +158,15 @@ config PHYS_64BIT
This can be used not only for 64bit SoCs, but also for This can be used not only for 64bit SoCs, but also for
large physical address extention on 32bit SoCs. large physical address extention on 32bit SoCs.
config BUILD_ROM
bool "Build U-Boot as BIOS replacement"
depends on X86
help
This option allows to build a ROM version of U-Boot.
The build process generally requires several binary blobs
which are not shipped in the U-Boot source tree.
Please, see doc/README.x86 for details.
endmenu # General setup endmenu # General setup
menu "Boot images" menu "Boot images"

@ -796,7 +796,7 @@ ALL-$(CONFIG_REMAKE_ELF) += u-boot.elf
ALL-$(CONFIG_EFI_APP) += u-boot-app.efi ALL-$(CONFIG_EFI_APP) += u-boot-app.efi
ALL-$(CONFIG_EFI_STUB) += u-boot-payload.efi ALL-$(CONFIG_EFI_STUB) += u-boot-payload.efi
ifneq ($(BUILD_ROM),) ifneq ($(BUILD_ROM)$(CONFIG_BUILD_ROM),)
ALL-$(CONFIG_X86_RESET_VECTOR) += u-boot.rom ALL-$(CONFIG_X86_RESET_VECTOR) += u-boot.rom
endif endif

@ -14,6 +14,7 @@ CONFIG_SMP=y
CONFIG_GENERATE_PIRQ_TABLE=y CONFIG_GENERATE_PIRQ_TABLE=y
CONFIG_GENERATE_MP_TABLE=y CONFIG_GENERATE_MP_TABLE=y
CONFIG_GENERATE_ACPI_TABLE=y CONFIG_GENERATE_ACPI_TABLE=y
CONFIG_BUILD_ROM=y
CONFIG_FIT=y CONFIG_FIT=y
CONFIG_SPL_LOAD_FIT=y CONFIG_SPL_LOAD_FIT=y
CONFIG_BOOTSTAGE=y CONFIG_BOOTSTAGE=y

@ -5,6 +5,7 @@ CONFIG_SMP=y
CONFIG_GENERATE_PIRQ_TABLE=y CONFIG_GENERATE_PIRQ_TABLE=y
CONFIG_GENERATE_MP_TABLE=y CONFIG_GENERATE_MP_TABLE=y
CONFIG_GENERATE_ACPI_TABLE=y CONFIG_GENERATE_ACPI_TABLE=y
CONFIG_BUILD_ROM=y
CONFIG_FIT=y CONFIG_FIT=y
CONFIG_BOOTSTAGE=y CONFIG_BOOTSTAGE=y
CONFIG_BOOTSTAGE_REPORT=y CONFIG_BOOTSTAGE_REPORT=y

@ -80,11 +80,15 @@ Building a ROM version of U-Boot (hereafter referred to as u-boot.rom) is a
little bit tricky, as generally it requires several binary blobs which are not little bit tricky, as generally it requires several binary blobs which are not
shipped in the U-Boot source tree. Due to this reason, the u-boot.rom build is shipped in the U-Boot source tree. Due to this reason, the u-boot.rom build is
not turned on by default in the U-Boot source tree. Firstly, you need turn it not turned on by default in the U-Boot source tree. Firstly, you need turn it
on by enabling the ROM build: on by enabling the ROM build either via an environment variable
$ export BUILD_ROM=y $ export BUILD_ROM=y
This tells the Makefile to build u-boot.rom as a target. or via configuration
CONFIG_BUILD_ROM=y
Both tell the Makefile to build u-boot.rom as a target.
--- ---

Loading…
Cancel
Save