diff options
author | Catalin Marinas <catalin.marinas@arm.com> | 2009-12-08 18:05:18 +0000 |
---|---|---|
committer | Catalin Marinas <catalin.marinas@arm.com> | 2009-12-08 18:05:18 +0000 |
commit | 9c403f063823510017ceed6579900559456969d9 (patch) | |
tree | 659087b816b82c38bb042304b8b5d34cfbc18a28 | |
parent | ed347494514c314cb4efd12c245aa595303c7ae9 (diff) |
Add some ifdefs in boot.S for easy changing between NFS and INITRD
configurations.
-rw-r--r-- | Makefile | 4 | ||||
-rw-r--r-- | boot.S | 13 |
2 files changed, 14 insertions, 3 deletions
@@ -9,7 +9,7 @@ LD_SCRIPT = model.lds CROSS_COMPILE = arm-none-linux-gnueabi- -AS = $(CROSS_COMPILE)as +CC = $(CROSS_COMPILE)gcc LD = $(CROSS_COMPILE)ld all: $(IMAGE) @@ -21,4 +21,4 @@ $(IMAGE): boot.o $(LD_SCRIPT) $(KERNEL) $(FILESYSTEM) $(LD) -o $@ --script=$(LD_SCRIPT) boot.o: $(BOOTLOADER) - $(AS) -o $@ $< + $(CC) -c -o $@ $< @@ -17,6 +17,9 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ +#define USE_INITRD +#undef THUMB2_KERNEL + .text .globl _start @@ -61,7 +64,9 @@ _start: adr r2, atags mov r3, #0 ldr lr, =kernel -@ orr lr, lr, #1 @ Thumb-2 kernel +#ifdef THUMB2_KERNEL + orr lr, lr, #1 @ Thumb-2 kernel +#endif mov pc, lr @ jump to the kernel .org 0x100 @@ -73,15 +78,21 @@ atags: @ ATAG_CMDLINE .long (1f - .) >> 2 .long 0x54410009 +#ifdef USE_INITRD .asciz "console=ttyAMA0 mem=256M earlyprintk" +#else + .asciz "root=/dev/nfs nfsroot=10.1.68.81:/work/nfsroot ip=dhcp console=ttyAMA0 mem=256M earlyprintk" +#endif .align 2 1: +#ifdef USE_INITRD @ ATAG_INITRD2 .long 4 .long 0x54420005 .long filesystem .long fs_size +#endif @ ATAG_NONE .long 0 |