Patchwork [U-Boot,1/4] EXYNOS: change the compile/clean option of spl

login
register
mail settings
Submitter Jeong-Hyeon Kim
Date Aug. 28, 2012, 11:51 a.m.
Message ID <1346154664-5951-1-git-send-email-jhkim@insignal.co.kr>
Download mbox | patch
Permalink /patch/180520/
State Changes Requested
Delegated to: Minkyu Kang
Headers show

Comments

Jeong-Hyeon Kim - Aug. 28, 2012, 11:51 a.m.
From: Jeong-Hyeon Kim <jhkim@insignal.co.kr>

spl tool of exynos5 designed only for smdk5250.
It compiled when defined CONFIG_SMDK5250 and BOARD name is smdk5250.
It means that it's not considered shrink boards with different board name.

So, it changed compile condition to exynos5 family option
not a specific board name for cover the other board.
I also modified clean condition to clear compiled spl.

Otherwise, tools/mk*spl show on untracked files.
It should be ignore in git.

Signed-off-by: Jeong-Hyeon Kim <jhkim@insignal.co.kr>
---
 Makefile                        |    2 +-
 board/samsung/origen/Makefile   |    6 +++---
 board/samsung/smdkv310/Makefile |    6 +++---
 spl/Makefile                    |    2 +-
 tools/.gitignore                |    1 +
 tools/Makefile                  |    6 +++---
 6 files changed, 12 insertions(+), 11 deletions(-)

Patch

diff --git a/Makefile b/Makefile
index e78c2b7..3fb48ae 100644
--- a/Makefile
+++ b/Makefile
@@ -745,7 +745,7 @@  clean:
 	       $(obj)tools/gdb/{astest,gdbcont,gdbsend}			  \
 	       $(obj)tools/gen_eth_addr    $(obj)tools/img2srec		  \
 	       $(obj)tools/mk{env,}image   $(obj)tools/mpc86x_clk	  \
-	       $(obj)tools/mk{smdk5250,}spl				  \
+	       $(obj)tools/mk{$(SOC),$(BOARD),}spl				  \
 	       $(obj)tools/ncb		   $(obj)tools/ubsha1
 	@rm -f $(obj)board/cray/L1/{bootscript.c,bootscript.image}	  \
 	       $(obj)board/matrix_vision/*/bootscript.img		  \
diff --git a/board/samsung/origen/Makefile b/board/samsung/origen/Makefile
index 3a885a5..bb95cc8 100644
--- a/board/samsung/origen/Makefile
+++ b/board/samsung/origen/Makefile
@@ -41,7 +41,7 @@  OBJS	:= $(addprefix $(obj),$(COBJS) $(SOBJS))
 ALL	+=$(obj).depend $(LIB)
 
 ifdef CONFIG_SPL_BUILD
-ALL	+= $(OBJTREE)/tools/mk$(BOARD)spl
+ALL	+= $(OBJTREE)/tools/mk$(SOC)spl
 endif
 
 all:	$(ALL)
@@ -50,8 +50,8 @@  $(LIB):	$(OBJS)
 	$(call cmd_link_o_target, $(OBJS))
 
 ifdef CONFIG_SPL_BUILD
-$(OBJTREE)/tools/mk$(BOARD)spl:	tools/mkv310_image.c
-	$(HOSTCC) tools/mkv310_image.c -o $(OBJTREE)/tools/mk$(BOARD)spl
+$(OBJTREE)/tools/mk$(SOC)spl:	tools/mkv310_image.c
+	$(HOSTCC) tools/mkv310_image.c -o $(OBJTREE)/tools/mk$(SOC)spl
 endif
 
 #########################################################################
diff --git a/board/samsung/smdkv310/Makefile b/board/samsung/smdkv310/Makefile
index 56e0c16..c2f344e 100644
--- a/board/samsung/smdkv310/Makefile
+++ b/board/samsung/smdkv310/Makefile
@@ -40,7 +40,7 @@  OBJS	:= $(addprefix $(obj),$(COBJS) $(SOBJS))
 ALL	:=	 $(obj).depend $(LIB)
 
 ifdef CONFIG_SPL_BUILD
-ALL	+= $(OBJTREE)/tools/mk$(BOARD)spl
+ALL	+= $(OBJTREE)/tools/mk$(SOC)spl
 endif
 
 all:	$(ALL)
@@ -49,8 +49,8 @@  $(LIB):	$(OBJS)
 	$(call cmd_link_o_target, $(OBJS))
 
 ifdef CONFIG_SPL_BUILD
-$(OBJTREE)/tools/mk$(BOARD)spl:	tools/mkv310_image.c
-	$(HOSTCC) tools/mkv310_image.c -o $(OBJTREE)/tools/mk$(BOARD)spl
+$(OBJTREE)/tools/mk$(SOC)spl:	tools/mkv310_image.c
+	$(HOSTCC) tools/mkv310_image.c -o $(OBJTREE)/tools/mk$(SOC)spl
 endif
 
 #########################################################################
diff --git a/spl/Makefile b/spl/Makefile
index 2cf7bda..92f5c70 100644
--- a/spl/Makefile
+++ b/spl/Makefile
@@ -117,7 +117,7 @@  all:	$(ALL-y)
 
 ifdef CONFIG_SAMSUNG
 $(obj)$(BOARD)-spl.bin: $(obj)u-boot-spl.bin
-	$(OBJTREE)/tools/mk$(BOARD)spl \
+	$(OBJTREE)/tools/mk$(SOC)spl \
 		$(obj)u-boot-spl.bin $(obj)$(BOARD)-spl.bin
 endif
 
diff --git a/tools/.gitignore b/tools/.gitignore
index 3557a75..5fcb8d0 100644
--- a/tools/.gitignore
+++ b/tools/.gitignore
@@ -16,3 +16,4 @@ 
 /env/fw_printenv
 /gdb/gdbcont
 /gdb/gdbsend
+/mk*spl
diff --git a/tools/Makefile b/tools/Makefile
index a7d1e18..a478179 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -68,7 +68,7 @@  BIN_FILES-$(CONFIG_CMD_LOADS) += img2srec$(SFX)
 BIN_FILES-$(CONFIG_XWAY_SWAP_BYTES) += xway-swap-bytes$(SFX)
 BIN_FILES-y += mkenvimage$(SFX)
 BIN_FILES-y += mkimage$(SFX)
-BIN_FILES-$(CONFIG_SMDK5250) += mksmdk5250spl$(SFX)
+BIN_FILES-$(CONFIG_EXYNOS5) += mkexynosspl$(SFX)
 BIN_FILES-$(CONFIG_MX28) += mxsboot$(SFX)
 BIN_FILES-$(CONFIG_NETCONSOLE) += ncb$(SFX)
 BIN_FILES-$(CONFIG_SHA1_CHECK_UB_IMG) += ubsha1$(SFX)
@@ -96,7 +96,7 @@  NOPED_OBJ_FILES-y += imximage.o
 NOPED_OBJ_FILES-y += omapimage.o
 NOPED_OBJ_FILES-y += mkenvimage.o
 NOPED_OBJ_FILES-y += mkimage.o
-OBJ_FILES-$(CONFIG_SMDK5250) += mkexynosspl.o
+OBJ_FILES-$(CONFIG_EXYNOS5) += mkexynosspl.o
 OBJ_FILES-$(CONFIG_MX28) += mxsboot.o
 OBJ_FILES-$(CONFIG_NETCONSOLE) += ncb.o
 NOPED_OBJ_FILES-y += os_support.o
@@ -218,7 +218,7 @@  $(obj)mkimage$(SFX):	$(obj)aisimage.o \
 	$(HOSTCC) $(HOSTCFLAGS) $(HOSTLDFLAGS) -o $@ $^
 	$(HOSTSTRIP) $@
 
-$(obj)mk$(BOARD)spl$(SFX):	$(obj)mkexynosspl.o
+$(obj)mk$(SOC)spl$(SFX):	$(obj)mkexynosspl.o
 	$(HOSTCC) $(HOSTCFLAGS) $(HOSTLDFLAGS) -o $@ $^
 	$(HOSTSTRIP) $@