Sunday, November 7, 2010

MeeGo 1.1 for NexusOne status part2 and how to work(Using microSD and No fastboot! You can also dualboot both of MeeGo and Android).

As you see, Here is about MeeGo 1.1 can boot on NexusOne from microSD via fastboot.


As I referred at LinuxCon Japan, Next step is standalone boot. So it's complete replacement. Android => MeeGo. BTW, The slide of LinuxCon Japan is the following.


I replaced boot.img the Android to MeeGo. But boot partition(/dev/mtdblock2) is too small. This block only can write data about 2.5MB. So It can't put fully rootfs or intelligent initrd. then boot.img(recover.img) is required zImage and initrd. But zImage only booting has already been proven. So It's ok that we prepare zImage and *empty* initrd.

1. Prepare a zImage(CONFIG_BLK_DEV_INITRD is not set). How to make a kernel is written at part1.
2. Prepare an empty inird.
$ echo -n | sudo cpio -o -H newc | sudo gzip > boot.img-ramdisk-meego.cpio.gz
3. Run mkbootimg. cmdline is same as fastboot -c args. then "--base 0x20000000" needs for NexusOne.
$ mkbootimg --cmdline 'init=/sbin/init rootwait root=/dev/mmcblk0p2 rootfstype=ext3 rw noinitrd' --kernel zImage --ramdisk boot.img-ramdisk-meego.cpio.gz --base 0x20000000 -o boot.img-meego
4. Power on and switch fastboot mode
5. Writing boot.img-meego to boot partition.
$ fastboot flash boot boot.img-meego
6. Reboot. Enjoy!

If you want to boot both of MeeGo and Android, you can use recovery partition. In my case, Default boot was MeeGo and Recovery boot was Android. Both worked successfully! :)

$ fastboot flash boot boot.img-meego
$ fastboot flash recovery boot.img (Original Android boot.img)

BTW, There were no place on where all of rootfs can put. Rootfs should be reduced more.
sh-4.0# df -h
Filesystem            Size  Used Avail Use% Mounted on
rootfs                3.0G  1.2G  1.7G  42% / (/dev/mmcblk0p2)
/dev/root             3.0G  1.2G  1.7G  42% /
none                  193M  104K  193M   1% /dev
tmpfs                 4.0M     0  4.0M   0% /var/lock
tmpfs                 4.0M   36K  4.0M   1% /var/run
tmpfs                 193M     0  193M   0% /dev/shm
tmpfs                  20M     0   20M   0% /home/meego/.mozilla
/dev/mmcblk0p1        492M  389M  104M  79% /mnt/sdcard
/dev/mtdblock3        145M  122M   24M  84% /mnt/system
/dev/mtdblock4         95M  1.2M   94M   2% /mnt/cache
/dev/mtdblock5        197M  144M   54M  73% /mnt/userdata

Thank you.