atom feed6 messages in org.openmoko.lists.device-ownersRe: Booting from SD Card using FreeRu...
FromSent OnAttachments
Simon MooreJul 3, 2008 11:30 pm 
Christian KuesterJul 4, 2008 12:48 am 
Christian KuesterJul 4, 2008 12:58 am 
Neng-Yu Tu (Tony Tu)Jul 4, 2008 7:48 pm.new
jlu...@escomposlinux.orgJul 5, 2008 5:13 am 
Simon MooreJul 5, 2008 10:30 am 
Subject:Re: Booting from SD Card using FreeRunner (as shipped)?
From:Simon Moore (sim@snmoore.net)
Date:Jul 5, 2008 10:30:00 am
List:org.openmoko.lists.device-owners

jlu@escomposlinux.org wrote:

Simon,

I'm generally running into two problems:

1. Nothing I've tried allows it to successfully mount the rootfs e.g. from /dev/mmcblk0p2 (using FAT+ext2 partitions on the SD Card)

That is easy change the format of the ext2 partition to ext3, the kernels have ext2 in a module and ext3 is built in.

2. 'savenv' appears to fail - it does an Erase, then drops back to the uBoot prompt; I've only ever had it once do an Erase...Write cycle

That as Tony tu says may be caused from using the NOR u-boot

Thanks to all for the information and advice - I've now got a successful SD card boot.

Observations ========= 1a. The default boot environment settings do not work e.g. a boot from NOR (or NAND with the default settings) results in:

VFS: Cannot open root device "mmcblk0p2" or unknown-block(179,2) Please append a correct "root=" boot option; here are the available partitions: <snip> Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(179,2)

This can be fixed by applying Tony's 'env.new' fix, which does work ok!

1a. FAT + ext2 does not work, but FAT + ext3 does work e.g. booting from NAND after applying Tony's 'env.new' fix using FAT + ext2 results in:

No filesystem could mount root, tried: ext3, cramfs, msdos, vfat, ramfs Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(179,2)

2. The 'saveenv' problem was due to me being stupid and mixing NOR and NAND boots - it works quite correctly from a NAND boot

Conclusions ========= To achieve a successful boot from SD Card using a FreeRunner as shipped:

A. Format the SD Card as FAT + ext3, not FAT + ext2 B. Adjust the NAND boot environment settings (e.g. by applying Tony's suggested 'env.new' fix) and boot from NAND

Which is going to make life challenging for non-Linux users (e.g. OS X and Windows), as the above is only really practical on a Linux machine with a working dfu-util and ext3 support. One (slightly difficult) way might be to set-up the USB networking first, perform the SD Card formatting on the FreeRunner itself via SSH, then use 'screen' etc to hand edit the NAND boot environment settings.

Cheers, Simon