Pogoplug Mobile

Debian化

# killall hbwd
# cd /tmp
# wget http://download.doozan.com/uboot/nanddump
# wget http://download.doozan.com/uboot/nandwrite
# wget http://download.doozan.com/uboot/flash_erase
# wget http://download.doozan.com/uboot/fw_printenv
# chmod +x flash_erase fw_printenv nanddump nandwrite
# cp fw_printenv fw_setenv
# mount -o remount,rw /
# echo "/dev/mtd0 0xc0000 0x20000 0x20000" > /etc/fw_env.config
# mkdir /tmp/usb
# mount /dev/sda1 /tmp/usb
# /tmp/nanddump -nf /tmp/usb/mtd0.oob /dev/mtd0
# /tmp/nanddump -nf /tmp/usb/mtd1.oob /dev/mtd1
# /tmp/nanddump -nf /tmp/usb/mtd2.oob /dev/mtd2
# /tmp/nanddump -nof /tmp/usb/mtd0 /dev/mtd0
# /tmp/nanddump -nof /tmp/usb/mtd1 /dev/mtd1
# /tmp/nanddump -nof /tmp/usb/mtd2 /dev/mtd2
# /tmp/flash_erase /dev/mtd0 0 4
# /tmp/nandwrite /dev/mtd0 /tmp/usb/uboot.2014.07-tld-2.pogo_v4.mtd0.kwb
# /tmp/flash_erase /dev/mtd0 0xc0000 1
# /tmp/nandwrite -s 786432 /dev/mtd0 usb/uboot.2014.07-tld-2.environment.img
# /tmp/fw_setenv arcNumber 3960
# /tmp/fw_setenv machid f78
# /tmp/fw_setenv usb_rootfstype ext3
# /tmp/fw_setenv mtdparts 'mtdparts=orion_nand:2M(u-boot),3M(uImage),3M(uImage2),8M(failsafe),112M(root)'
# /tmp/fw_setenv ethaddr "$(cat /sys/class/net/eth0/address)"
# /tmp/fw_setenv preboot 'run if_netconsole start_netconsole'
# /tmp/fw_setenv serverip 192.168.30.200
# /tmp/fw_setenv ipaddr 192.168.30.199
# /tmp/fw_setenv if_netconsole 'ping $serverip'
# /tmp/fw_setenv start_netconsole 'setenv ncip $serverip; setenv bootdelay 10;
setenv stdin nc; setenv stdout nc; setenv stderr nc; version;'
# /tmp/fw_setenv bootcmd 'run bootcmd_uenv; run bootcmd_mmc; run bootcmd_usb; run bootcmd_sata; run bootcmd_pogo; reset'
# /tmp/fw_setenv bootcmd_pogo 'if ubi part root 2048 && ubifsmount ubi:rootfs && ubifsload 0x800000 uboot.mtd0.dockstar.original.kwb ; then go 0x800200; fi'
# mknod /tmp/mmcblk0 b 179 0
# /sbin/fdisk -l /tmp/mmcblk0
# mknod /tmp/mmcblk0p1 b 179 1
# wget http://archlinuxarm.org/os/pogoplug/mke2fs
# chmod +x mke2fs
# /tmp/mke2fs -L rootfs -j /tmp/mmcblk0p1
# mkdir /tmp/mnt
# mount /tmp/mmcblk0p1 /tmp/mnt/
# cd /tmp/mnt
# tar -xjf ../usb/Debian-3.17.0-kirkwood-tld-1-rootfs-bodhi.tar.bz2
# cd /tmp/mnt/boot
# cp -a zImage-3.17.0-kirkwood-tld-1 zImage.fdt
# cat dts/kirkwood-goflexnet.dtb  >> zImage.fdt
# mv uImage uImage.orig
# mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-3.17.0-kirkwood-tld-1 -d /tmp/mnt/boot/zImage.fdt /tmp/mnt/boot/uImage
# sync
# /sbin/reboot

参考

Last edited by n13i, 2014-12-29 22:36:26