blob: 9ae1e9ac91c1746701ccb6d5cd8fe9b1432540dd [file] [log] [blame]
Nishanth Menoncd43ddc2015-08-17 19:54:49 +05301# Copyright 2015 Texas Instruments Incorporated, <www.ti.com>
2#
3# Lokesh Vutla <lokeshvutla@ti.com>
4#
5# SPDX-License-Identifier: GPL-2.0+
6#
7
Lokesh Vutla45fe4b42015-08-17 19:54:51 +05308ifndef CONFIG_SPL_BUILD
9ALL-y += MLO
10endif
11
Nishanth Menoncd43ddc2015-08-17 19:54:49 +053012MKIMAGEFLAGS_u-boot-spl.gph = -A $(ARCH) -T gpimage -C none \
13 -a $(CONFIG_SPL_TEXT_BASE) -e $(CONFIG_SPL_TEXT_BASE) -n SPL
14spl/u-boot-spl.gph: spl/u-boot-spl.bin FORCE
15 $(call if_changed,mkimage)
16
17OBJCOPYFLAGS_u-boot-spi.gph = -I binary -O binary --pad-to=$(CONFIG_SPL_PAD_TO) \
18 --gap-fill=0
Lokesh Vutla1985abe2015-09-19 15:00:23 +053019u-boot-spi.gph: spl/u-boot-spl.gph u-boot-dtb.img FORCE
Nishanth Menoncd43ddc2015-08-17 19:54:49 +053020 $(call if_changed,pad_cat)
21
Lokesh Vutla5f586e92015-08-17 19:54:50 +053022ifndef CONFIG_SPL_BUILD
23MKIMAGEFLAGS_MLO = -A $(ARCH) -T gpimage -C none \
Nishanth Menoncd43ddc2015-08-17 19:54:49 +053024 -a $(CONFIG_SYS_TEXT_BASE) -e $(CONFIG_SYS_TEXT_BASE) -n U-Boot
Lokesh Vutla1985abe2015-09-19 15:00:23 +053025MLO: u-boot-dtb.bin FORCE
Nishanth Menoncd43ddc2015-08-17 19:54:49 +053026 $(call if_changed,mkimage)
27 @dd if=/dev/zero bs=8 count=1 2>/dev/null >> $@
Lokesh Vutla5f586e92015-08-17 19:54:50 +053028endif