summaryrefslogtreecommitdiff
path: root/arch/sh/boot/romimage/Makefile
diff options
context:
space:
mode:
authorMagnus Damm <damm@igel.co.jp>2009-07-29 15:04:05 +0000
committerPaul Mundt <lethal@linux-sh.org>2009-07-30 00:24:03 +0900
commit3c928320b2254cb6c8d8a7919a1fcf94ca7cae66 (patch)
treeee2682b83916592c63202cb8749e1e35cfc5728a /arch/sh/boot/romimage/Makefile
parentfd78a76aefb5bf28a11d6960d29e03a11db62320 (diff)
sh: romImage support V2
This patch contains support for the romImage build target V2. The resulting romImage file should be burned to rom or flash and could be used as small boot loader. Board code should keep their setup code in the file romimage.h located in their mach include directory. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/boot/romimage/Makefile')
-rw-r--r--arch/sh/boot/romimage/Makefile19
1 files changed, 19 insertions, 0 deletions
diff --git a/arch/sh/boot/romimage/Makefile b/arch/sh/boot/romimage/Makefile
new file mode 100644
index 000000000000..5806eee84f6f
--- /dev/null
+++ b/arch/sh/boot/romimage/Makefile
@@ -0,0 +1,19 @@
+#
+# linux/arch/sh/boot/romimage/Makefile
+#
+# create an image suitable for burning to flash from zImage
+#
+
+targets := vmlinux head.o
+
+OBJECTS = $(obj)/head.o
+LDFLAGS_vmlinux := --oformat $(ld-bfd) -Ttext 0 -e romstart
+
+$(obj)/vmlinux: $(OBJECTS) $(obj)/piggy.o FORCE
+ $(call if_changed,ld)
+ @:
+
+LDFLAGS_piggy.o := -r --format binary --oformat $(ld-bfd) -T
+
+$(obj)/piggy.o: $(obj)/vmlinux.scr arch/sh/boot/zImage FORCE
+ $(call if_changed,ld)