zImage.initrd: zvmlinux.initrd bootcode $(SETSUM) ../../../../firminfo.txt ../images/vmlinux.gz -r ../images/ramdisk.image.gz -o ../images/firmimg.bin mv zvmlinux.initrd ../images/$@.sandpoint mv bootcode.bin ../images/bootcode.bin rm ../images/vmlinux.gz rm ./bootcodeという記述があることを見つけた。
つまり、firmimg.bin は、
kurobako# cat /dev/fl1 > fl1
[yasunari@ls tmp]$ od -xc fl1 | less
0000000 0000 0001 0000 1001 4b55 524f 2d42 4f58
         \0  \0  \0 001  \0  \0 020 001   K   U   R   O   -   B   O   X
0000020 2849 4554 5355 4e41 2900 0000 0000 0000
          (   I   E   T   S   U   N   A   )  \0  \0  \0  \0  \0  \0  \0
0000040 0000 0000 0000 0000 464c 4153 4820 312e
         \0  \0  \0  \0  \0  \0  \0  \0   F   L   A   S   H       1   .
0000060 3100 0000 0000 0000 0000 0000 0000 0000
          1  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
0000100 0000 0000 0000 0000 0001 0000 0000 6802
         \0  \0  \0  \0  \0  \0  \0  \0  \0 001  \0  \0  \0  \0   h 002
0000120 0910 1e2a 002d a21b 320d 8c9f 0000 006c
         \t 020 036   *  \0   - 242 033   2  \r 214 237  \0  \0  \0   l
0000140 000a f8b5 000a f921 0022 a8fa 1f8b 0808
         \0  \n 370 265  \0  \n 371   !  \0   " 250 372 037 213  \b  \b
0000160 2037 2740 0203 766d 6c69 6e75 7800 ec5c
              7   '   @ 002 003   v   m   l   i   n   u   x  \0 354   \
OK。
-rwxr-xr-x 1 yasunari root 653164 Mar 23 20:56 vmlinux.gz*で 000a f8b5 (719029) に近い。 ということは、これはカーネルのサイズか?
仮定をまとめてみると、
| offset (0 orig.) | data(hex) | data(dec) | 意味(予想) | 
| 92 | 0000 006c | 108 | カーネルの始まるオフセット | 
| 96 | 000a f8b5 | 719029 | カーネルのサイズ | 
| 100 | 000a f921 | 719137 | ramdisk.image.gz の始まるオフセット? | 
| 104 | 0022 a8fa | 2271482 | ramdisk.image.gz のサイズ | 
linkstationVine# tail -c 2426591 fl1 > ramdisk.image.gz
linkstationVine# od -xc ramdisk.image.gz |head
0000000 1f8b 0808 b634 2740 0203 6c6f 6f70 6669
        037 213  \b  \b 266   4   '   @ 002 003   l   o   o   p   f   i
0000020 6c65 00ec 9d09 7c54 d5bd c7ef cc64 9dac
          l   e  \0 354 235  \t   |   T 325 275 307 357 314   d 235 254
0000040 8488 6cc2 0888 8898 65b2 1052 8c43 206c
        204 210   l 302  \b 210 210 230   e 262 020   R 214   C       l
0000060 b209 48dd 2a66 9998 91c9 4ccc 4c08 2268
        262  \t   H 335   *   f 231 230 221 311   L 314   L  \b   "   h
0000100 c005 5111 1117 5444 a5d6 bed6 be96 56aa
        300 005   Q 021 021 027   T   D 245 326 276 326 276 226   V 252
見事、gzip のマジックナンバ 1f8b である。\^_^/linkstationVine# tar ztvf ramdisk.image.gz |less gzip: stdin: decompression OK, trailing garbage ignored tar: 子プロセスがステータス 2 を返してきました tar: 処理中にエラーが起きましたが、最後まで処理してからエラー終了させましたあれ?だめ?
linkstationVine# gunzip ramdisk.image.gz gunzip: ramdisk.image.gz: decompression OK, trailing garbage ignored linkstationVine# file ramdisk.image ramdisk.image: Linux rev 1.0 ext2 filesystem data linkstationVine# mkdir /tmp/ramdisk/ linkstationVine# mount -o loop ramdisk.image /tmp/ramdisk linkstationVine# ls /tmp/ramdisk/ bin dev etc lib lost+found mnt mnt2 proc root sbin tmp usr var wwwやったぁ!ついに見つけたぞ、ramdisk image!
今日はここまで。