summaryrefslogtreecommitdiffstats
path: root/patches/linux-3.7/0149-ARM-CUSTOM-Build-a-uImage-with-dtb-already-appended.patch
blob: ebca33b364bab5e2c4bf3cc301af7a8e677c22f9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
From: Grant Likely <grant.likely@secretlab.ca>
Date: Tue, 2 Aug 2011 15:30:09 +0100
Subject: [PATCH] ARM: CUSTOM: Build a uImage with dtb already appended

Do not commit to mainline; this is a useful hack only for now.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>

Conflicts:

	arch/arm/Makefile
---
 arch/arm/Makefile      |    3 +++
 arch/arm/boot/Makefile |    7 +++++++
 2 files changed, 10 insertions(+)

diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 5f914fc..05df486 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -291,6 +291,9 @@ zImage Image xipImage bootpImage uImage: vmlinux
 zinstall uinstall install: vmlinux
 	$(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) $@
 
+uImage-dtb.%:
+	$(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) $(boot)/$@
+
 %.dtb: scripts
 	$(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) $(boot)/$@
 
diff --git a/arch/arm/boot/Makefile b/arch/arm/boot/Makefile
index 9137df5..416fbe9 100644
--- a/arch/arm/boot/Makefile
+++ b/arch/arm/boot/Makefile
@@ -57,6 +57,9 @@ $(obj)/zImage:	$(obj)/compressed/vmlinux FORCE
 	$(call if_changed,objcopy)
 	@$(kecho) '  Kernel: $@ is ready'
 
+$(obj)/zImage-dtb.%:	$(obj)/%.dtb $(obj)/zImage
+	cat $(obj)/zImage $< > $@
+
 endif
 
 targets += $(dtb-y)
@@ -92,6 +95,10 @@ $(obj)/uImage:	$(obj)/zImage FORCE
 	$(call if_changed,uimage)
 	@$(kecho) '  Image $@ is ready'
 
+$(obj)/uImage-dtb.%:	$(obj)/zImage-dtb.% FORCE
+	$(call if_changed,uimage)
+	@echo '  Image $@ is ready'
+
 $(obj)/bootp/bootp: $(obj)/zImage initrd FORCE
 	$(Q)$(MAKE) $(build)=$(obj)/bootp $@
 	@: