aboutsummaryrefslogtreecommitdiff
path: root/arch/arm/mach-imx/Makefile
diff options
context:
space:
mode:
authorPeng Fan <peng.fan@nxp.com>2019-08-22 07:42:41 +0000
committerStefano Babic <sbabic@denx.de>2019-10-08 16:35:58 +0200
commit700315c9ac4d44740884ed6a02a5dc56bec92868 (patch)
tree4ec03a3b413042d39acd7038bf040052e1dd6d7c /arch/arm/mach-imx/Makefile
parentdd7d0911e0048e4ddb8a4084d2221242aed8c62b (diff)
downloadu-boot-700315c9ac4d44740884ed6a02a5dc56bec92868.zip
u-boot-700315c9ac4d44740884ed6a02a5dc56bec92868.tar.gz
u-boot-700315c9ac4d44740884ed6a02a5dc56bec92868.tar.bz2
imx: add container target
To support SPL loading container file, add a new Makefile target, and introduce a new Kconfig file to source the cfg file which will be parsed by mkimage. Signed-off-by: Peng Fan <peng.fan@nxp.com>
Diffstat (limited to 'arch/arm/mach-imx/Makefile')
-rw-r--r--arch/arm/mach-imx/Makefile14
1 files changed, 12 insertions, 2 deletions
diff --git a/arch/arm/mach-imx/Makefile b/arch/arm/mach-imx/Makefile
index 08ee52e..17b241a 100644
--- a/arch/arm/mach-imx/Makefile
+++ b/arch/arm/mach-imx/Makefile
@@ -90,6 +90,11 @@ IMX_CONFIG = $(CONFIG_IMX_CONFIG:"%"=%)
$(Q)mkdir -p $(dir $@)
$(call if_changed_dep,cpp_cfg)
+IMX_CONTAINER_CFG = $(CONFIG_IMX_CONTAINER_CFG:"%"=%)
+container.cfg: $(IMX_CONTAINER_CFG) FORCE
+ $(Q)mkdir -p $(dir $@)
+ $(call if_changed_dep,cpp_cfg)
+
ifeq ($(CONFIG_ARCH_IMX8), y)
CNTR_DEPFILES := $(srctree)/tools/imx_cntr_image.sh
IMAGE_TYPE := imx8image
@@ -158,10 +163,15 @@ SPL:
MKIMAGEFLAGS_flash.bin = -n spl/u-boot-spl.cfgout -T $(IMAGE_TYPE) -e 0x100000
flash.bin: MKIMAGEOUTPUT = flash.log
-flash.bin: spl/u-boot-spl.bin u-boot.itb FORCE
-ifeq ($(SPL_DEPFILE_EXISTS),0)
+MKIMAGEFLAGS_u-boot.cnt = -n container.cfg -T $(IMAGE_TYPE) -e 0x100000
+u-boot.cnt: MKIMAGEOUTPUT = u-boot.cnt.log
+
+ifeq ($(CONFIG_SPL_LOAD_IMX_CONTAINER), y)
+u-boot.cnt: u-boot.bin container.cfg FORCE
$(call if_changed,mkimage)
endif
+flash.bin: spl/u-boot-spl.bin FORCE
+ $(call if_changed,mkimage)
endif
else