diff mbox

[U-Boot,2/5] ARM: keystone2: move the custom build rules out to keystone specific makefile

Message ID 1439821492-32615-3-git-send-email-lokeshvutla@ti.com
State Accepted
Delegated to: Tom Rini
Headers show

Commit Message

Lokesh Vutla Aug. 17, 2015, 2:24 p.m. UTC
From: Nishanth Menon <nm@ti.com>

Keystone has build rules introduced by commit ef509b9063fb7 ("k2hk: add
support for k2hk SOC and EVM") and commit 0e7f2dbac6ead ("keystone: add
support for NAND gpheader image").

These are not reused by other platforms for the build, hence there is no
clear benefit is maintaining them in the generic makefile as a build
target. move these to the keystone specific make option

Original idea of using config.mk by Lokesh Vutla <lokeshvutla@ti.com>

Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
---
 Makefile                         | 16 ----------------
 arch/arm/mach-keystone/config.mk | 22 ++++++++++++++++++++++
 2 files changed, 22 insertions(+), 16 deletions(-)
 create mode 100644 arch/arm/mach-keystone/config.mk

Comments

Tom Rini Aug. 28, 2015, 9:02 p.m. UTC | #1
On Mon, Aug 17, 2015 at 07:54:49PM +0530, Lokesh Vutla wrote:

> From: Nishanth Menon <nm@ti.com>
> 
> Keystone has build rules introduced by commit ef509b9063fb7 ("k2hk: add
> support for k2hk SOC and EVM") and commit 0e7f2dbac6ead ("keystone: add
> support for NAND gpheader image").
> 
> These are not reused by other platforms for the build, hence there is no
> clear benefit is maintaining them in the generic makefile as a build
> target. move these to the keystone specific make option
> 
> Original idea of using config.mk by Lokesh Vutla <lokeshvutla@ti.com>
> 
> Signed-off-by: Nishanth Menon <nm@ti.com>
> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>

Applied to u-boot/master, thanks!
diff mbox

Patch

diff --git a/Makefile b/Makefile
index ad51e60..9f44600 100644
--- a/Makefile
+++ b/Makefile
@@ -1004,22 +1004,6 @@  OBJCOPYFLAGS_u-boot.spr = -I binary -O binary --pad-to=$(CONFIG_SPL_PAD_TO) \
 u-boot.spr: spl/u-boot-spl.img u-boot.img FORCE
 	$(call if_changed,pad_cat)
 
-MKIMAGEFLAGS_u-boot-spl.gph = -A $(ARCH) -T gpimage -C none \
-	-a $(CONFIG_SPL_TEXT_BASE) -e $(CONFIG_SPL_TEXT_BASE) -n SPL
-spl/u-boot-spl.gph: spl/u-boot-spl.bin FORCE
-	$(call if_changed,mkimage)
-
-OBJCOPYFLAGS_u-boot-spi.gph = -I binary -O binary --pad-to=$(CONFIG_SPL_PAD_TO) \
-			  --gap-fill=0
-u-boot-spi.gph: spl/u-boot-spl.gph u-boot.img FORCE
-	$(call if_changed,pad_cat)
-
-MKIMAGEFLAGS_u-boot-nand.gph = -A $(ARCH) -T gpimage -C none \
-	-a $(CONFIG_SYS_TEXT_BASE) -e $(CONFIG_SYS_TEXT_BASE) -n U-Boot
-u-boot-nand.gph: u-boot.bin FORCE
-	$(call if_changed,mkimage)
-	@dd if=/dev/zero bs=8 count=1 2>/dev/null >> $@
-
 ifneq ($(CONFIG_ARCH_SOCFPGA),)
 quiet_cmd_socboot = SOCBOOT $@
 cmd_socboot = cat	spl/u-boot-spl-dtb.sfp spl/u-boot-spl-dtb.sfp	\
diff --git a/arch/arm/mach-keystone/config.mk b/arch/arm/mach-keystone/config.mk
new file mode 100644
index 0000000..3fcda92
--- /dev/null
+++ b/arch/arm/mach-keystone/config.mk
@@ -0,0 +1,22 @@ 
+# Copyright 2015 Texas Instruments Incorporated, <www.ti.com>
+#
+# Lokesh Vutla <lokeshvutla@ti.com>
+#
+# SPDX-License-Identifier:     GPL-2.0+
+#
+
+MKIMAGEFLAGS_u-boot-spl.gph = -A $(ARCH) -T gpimage -C none \
+	-a $(CONFIG_SPL_TEXT_BASE) -e $(CONFIG_SPL_TEXT_BASE) -n SPL
+spl/u-boot-spl.gph: spl/u-boot-spl.bin FORCE
+	$(call if_changed,mkimage)
+
+OBJCOPYFLAGS_u-boot-spi.gph = -I binary -O binary --pad-to=$(CONFIG_SPL_PAD_TO) \
+			  --gap-fill=0
+u-boot-spi.gph: spl/u-boot-spl.gph u-boot.img FORCE
+	$(call if_changed,pad_cat)
+
+MKIMAGEFLAGS_u-boot-nand.gph = -A $(ARCH) -T gpimage -C none \
+	-a $(CONFIG_SYS_TEXT_BASE) -e $(CONFIG_SYS_TEXT_BASE) -n U-Boot
+u-boot-nand.gph: u-boot.bin FORCE
+	$(call if_changed,mkimage)
+	@dd if=/dev/zero bs=8 count=1 2>/dev/null >> $@