diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1999-07-05 23:09:37 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 1999-07-05 23:09:37 +0000 |
commit | aba344fdfed81b2c03d6114c54cfd73a486aa10b (patch) | |
tree | d032d8430bf1234c3ecc6f6330d6de6e887e5963 /arch/ppc/chrpboot | |
parent | 40c138bfc6d37dbff5339f84575db1e3cec6e34e (diff) |
Merge with Linux 2.3.9.
Diffstat (limited to 'arch/ppc/chrpboot')
-rw-r--r-- | arch/ppc/chrpboot/Makefile | 3 | ||||
-rw-r--r-- | arch/ppc/chrpboot/main.c | 8 |
2 files changed, 7 insertions, 4 deletions
diff --git a/arch/ppc/chrpboot/Makefile b/arch/ppc/chrpboot/Makefile index 53e30d65d..eb4720927 100644 --- a/arch/ppc/chrpboot/Makefile +++ b/arch/ppc/chrpboot/Makefile @@ -70,6 +70,9 @@ zImage: $(OBJS) no_initrd.o mknote ./mknote > note $(OBJCOPY) $@ $@ --add-section=.note=note -R .comment +mknote: mknote.c + $(HOSTCC) $(HOSTCFLAGS) -o $@ mknote.c + zImage.initrd: $(OBJS) initrd.o $(LD) $(LD_ARGS) -o $@ $(OBJS) initrd.o $(LIBS) diff --git a/arch/ppc/chrpboot/main.c b/arch/ppc/chrpboot/main.c index 7d141d5c3..210dd43ad 100644 --- a/arch/ppc/chrpboot/main.c +++ b/arch/ppc/chrpboot/main.c @@ -19,12 +19,13 @@ void gunzip(void *, int, unsigned char *, int *); #define RAM_START 0x00000000 #define RAM_END (8<<20) -#define RAM_FREE (6<<20) /* after image of chrpboot */ +#define RAM_FREE ((unsigned long)(_end+0x1000)&~0xFFF) #define PROG_START 0x00010000 char *avail_ram; char *end_avail; +extern char _end[]; extern char image_data[]; extern int image_len; extern char initrd_data[]; @@ -47,8 +48,8 @@ chrpboot(int a1, int a2, void *prom) initrd_start = (RAM_END - initrd_size) & ~0xFFF; a1 = initrd_start; a2 = initrd_size; - printf("initial ramdisk at 0x%x (%u bytes)\n\r", initrd_start, - initrd_size); + printf("initial ramdisk moving 0x%x <- 0x%x (%x bytes)\n\r", initrd_start, + initrd_data,initrd_size); memcpy((char *)initrd_start, initrd_data, initrd_size); end_avail = (char *)initrd_start; } else @@ -56,7 +57,6 @@ chrpboot(int a1, int a2, void *prom) im = image_data; len = image_len; dst = (void *) PROG_START; - if (im[0] == 0x1f && im[1] == 0x8b) { avail_ram = (char *)RAM_FREE; printf("gunzipping (0x%x <- 0x%x:0x%0x)...", dst, im, im+len); |