diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1997-06-01 03:16:17 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 1997-06-01 03:16:17 +0000 |
commit | d8d9b8f76f22b7a16a83e261e64f89ee611f49df (patch) | |
tree | 3067bc130b80d52808e6390c9fc7fc087ec1e33c /arch/mips/boot | |
parent | 19c9bba94152148523ba0f7ef7cffe3d45656b11 (diff) |
Initial revision
Diffstat (limited to 'arch/mips/boot')
-rw-r--r-- | arch/mips/boot/Makefile | 6 | ||||
-rw-r--r-- | arch/mips/boot/mkboot.c | 8 |
2 files changed, 9 insertions, 5 deletions
diff --git a/arch/mips/boot/Makefile b/arch/mips/boot/Makefile index fd445c865..dd834efd9 100644 --- a/arch/mips/boot/Makefile +++ b/arch/mips/boot/Makefile @@ -34,7 +34,11 @@ mkboot: mkboot.c $(HOSTCC) -o $@ $^ zdisk: zImage - mcopy -o zImage a:vmlinux + if [ -f /etc/remote-mcopy ]; then \ + ssh rio mcopy -o - a:vmlinux <zImage; \ + else \ + mcopy -o zImage a:vmlinux; \ + fi dep: $(CPP) -M *.[cS] > .depend diff --git a/arch/mips/boot/mkboot.c b/arch/mips/boot/mkboot.c index 48f27113e..35612d248 100644 --- a/arch/mips/boot/mkboot.c +++ b/arch/mips/boot/mkboot.c @@ -355,7 +355,7 @@ main(argc, argv) char *infile, *outfile; struct stat ifstat; off_t ifsize; - void *image; + char *image; int ifd, ofd, i, symtabix, strtabix; Elf32_Ehdr eh; Elf32_Phdr *ph; @@ -421,7 +421,7 @@ main(argc, argv) * we're reading might have different type sizes, byteorder * or alignment than the host. */ - memcpy(eh.e_ident, image, sizeof(eh.e_ident)); + memcpy(eh.e_ident, (void *)image, sizeof(eh.e_ident)); if(memcmp(eh.e_ident, ELFMAG, SELFMAG)) { fprintf(stderr, "Input file isn't a ELF file\n"); exit(1); @@ -476,7 +476,7 @@ main(argc, argv) exit(1); } for(i = 0;i < eh.e_phnum; i++) - get_elfph(image + eh.e_phoff + i * 32, ph + i); + get_elfph((void *)(image + eh.e_phoff + i * 32), ph + i); /* * ... and then the section headers. @@ -487,7 +487,7 @@ main(argc, argv) exit(1); } for(i = 0;i < eh.e_shnum; i++) - get_elfsh(image + eh.e_shoff + (i * 40), sh + i); + get_elfsh((void *)(image + eh.e_shoff + (i * 40)), sh + i); /* * Find the symboltable and the stringtable in the file. |