[root@junk root]# PATH=$PATH:/opt/arm-2005q3-2/bin:/opt/arm-2005q3-2/libexec/gcc/arm-none-linux-gnueabi/3.4.4 [root@junk root]# export PATH [root@junk root]#
[root@junk ls-lgl]# tar zxvf linux-2.6.12_lsp2.1.10.tar.gz ./linux-feroceon_2_1_10/ ./linux-feroceon_2_1_10/buffalo/ ./linux-feroceon_2_1_10/buffalo/config_buffalo_kuro_arm_100.config ./linux-feroceon_2_1_10/buffalo/config_buffalo_lsigl_arm_100.config ./linux-feroceon_2_1_10/buffalo/config_buffalo_lslgl_arm_100.config ./linux-feroceon_2_1_10/buffalo/config_marvell_lsigl_arm_100.config ./linux-feroceon_2_1_10/buffalo/drivers/ : : [root@junk ls-lgl]#linux-feroceon_2_1_10 というディレクトリが展開された。
feroceon って何?
ググってみると、Marvell のチップ? IP? の名前だとか。
[root@junk ls-lgl]# cd linux-feroceon_2_1_10/buffalo/ [root@junk buffalo]# ls -l total 96 -rw-r--r-- 1 root root 24336 Mar 16 2007 config_buffalo_kuro_arm_100.config -rw-r--r-- 1 root root 23337 Mar 16 2007 config_buffalo_lsigl_arm_100.config -rw-r--r-- 1 root root 18441 Jun 13 2007 config_buffalo_lslgl_arm_100.config -rw-r--r-- 1 root root 23865 Mar 16 2007 config_marvell_lsigl_arm_100.config drwxr-xr-x 2 root root 4096 Jun 15 2007 drivers/ [root@junk buffalo]#config_buffalo_lslgl_arm_100.config を使えば良さそう。
lsigl ってなんだろう?
.config にコピーする
[root@junk buffalo]# cp config_buffalo_lslgl_arm_100.config ../.config [root@junk buffalo]#
[root@junk buffalo]# cd .. [root@junk linux-feroceon_2_1_10]# make oldconfig HOSTCC scripts/basic/fixdep : : CRC-CCITT functions (CRC_CCITT) [N/m/y/?] n CRC32 functions (CRC32) [Y/n/m/?] y CRC32c (Castagnoli, et al) Cyclic Redundancy-Check (LIBCRC32C) [Y/n/m/?] y [root@junk linux-feroceon_2_1_10]#
[root@junk linux-feroceon_2_1_10]# make uImage : : Kernel: arch/arm/boot/zImage is ready UIMAGE arch/arm/boot/uImage "mkimage" command not found - U-Boot images will not be built Image arch/arm/boot/uImage is ready [root@junk linux-feroceon_2_1_10]#zImage は無事できたようであるが、、、
[root@junk linux-feroceon_2_1_10]# pushd /usr/local/src /usr/local/src /opt/ls-lgl/linux-feroceon_2_1_10 [root@junk src]# ls [root@junk src]# mkdir u-boot [root@junk src]# cd u-boot/ [root@junk u-boot]# (u-boot-1.1.4.tar.bz2 を取得)
[root@junk u-boot]# tar jxvf u-boot-1.1.4.tar.bz2 u-boot-1.1.4/ u-boot-1.1.4/nios_config.mk u-boot-1.1.4/common/ : [root@junk u-boot]# cd u-boot-1.1.4 [root@junk u-boot-1.1.4]#
[root@junk u-boot-1.1.4]# TOPDIR=`pwd` [root@junk u-boot-1.1.4]# export TOPDIR [root@junk u-boot-1.1.4]# cd tools/ [root@junk tools]# make mkimage ln -s ../common/environment.c environment.c ln -s ../lib_generic/crc32.c crc32.c gcc -M -Wall -pedantic -idirafter ../include -DTEXT_BASE= -DUSE_HOSTCC environment.c img2srec.c mkimage.c crc32.c envcrc.c gen_eth_addr.c bmp_logo.c > .depend environment.c:28:20: config.h: No such file or directory envcrc.c:32:20: config.h: No such file or directory make: *** [.depend] Error 1 [root@junk tools]# make mkimage gcc -g -Wall -pedantic -idirafter ../include -DTEXT_BASE= -DUSE_HOSTCC -O -c mkimage.c gcc -g -Wall -pedantic -idirafter ../include -DTEXT_BASE= -DUSE_HOSTCC -O -c crc32.c gcc -Wall -pedantic -idirafter ../include -DTEXT_BASE= -DUSE_HOSTCC -O -o mkimage mkimage.o crc32.o strip mkimage [root@junk tools]#
[root@junk tools]# make -n install make: *** No rule to make target `install'. Stop.make install でいけるとおもたけどあかんか。
[root@junk tools]# cp mkimage /usr/local/bin [root@junk tools]# ls -l /usr/local/bin/mkimage -rwxr-xr-x 1 root root 12268 Dec 16 18:01 /usr/local/bin/mkimage* [root@junk tools]#できた。
[root@junk tools]# popd /opt/ls-lgl/linux-feroceon_2_1_10 [root@junk linux-feroceon_2_1_10]# make uImage : : Kernel: arch/arm/boot/Image is ready Kernel: arch/arm/boot/zImage is ready UIMAGE arch/arm/boot/uImage Image Name: Linux-2.6.12.6-arm1 Created: Sun Dec 16 18:02:36 2007 Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 1284096 Bytes = 1254.00 kB = 1.22 MB Load Address: 0x00008000 Entry Point: 0x00008000 Image arch/arm/boot/uImage is ready [root@junk linux-feroceon_2_1_10]#できた。
確認する。
[root@junk linux-feroceon_2_1_10]# mkimage -l arch/arm/boot/uImage Image Name: Linux-2.6.12.6-arm1 Created: Sun Dec 16 18:02:36 2007 Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 1284096 Bytes = 1254.00 kB = 1.22 MB Load Address: 0x00008000 Entry Point: 0x00008000 [root@junk linux-feroceon_2_1_10]#ファームウェア 1.03 の uImage.buffalo は、
[root@giga LS_LGL_Fw1.03]# mkimage -l uImage.buffalo Image Name: Linux-2.6.12.6-arm1 Created: Tue Nov 13 11:16:10 2007 Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 1284108 Bytes = 1254.01 kB = 1.22 MB Load Address: 0x00008000 Entry Point: 0x00008000 [root@giga LS_LGL_Fw1.03]#ちょっとサイズが違うが、、、
|
← I'm here |
ハックの記録 LinkStation/玄箱 をハックしよう |
→ コンパイルしたカーネルで起動 |