[Gta04-owner] rationale behind having uImage on the first partition?

Johannes Schauer j.schauer at email.de
Mon Oct 24 08:41:10 CEST 2011


Hi Nik,

your argument is of course valid as well, so let me just skip those
parts.

On Mon, Oct 24, 2011 at 07:01:21AM +0200, Dr. H. Nikolaus Schaller wrote:
> I think the same topic was discussed on the beagle board lists but I
> don't remember the reasons why a small FAT partition does not work.

I found it neither :(

> I think the problem is not X-Loader (MLO) itself but the Boot ROM. The
> Boot ROM assumes that it can find a sector with a "MLO" signature at a
> specific offset from the beginning of the "disk". Maybe, specifying
> less than 7 cylinders for a FAT filesystem places the MLO file at the
> wrong absolute position. But this is only a rough guess. One would
> have to study the 3500 pages OMAP3 technical manual (there is one
> chapter about the Boot ROM) to find out the details.

No. That's what I explained further below in my email. Just changing the
partition table (not touching the content of the FAT - i checked with a
binary diff) makes it unbootable. So the boot rom also reads the
partition table and makes some assumptions about it.

are those docs public?

> > But even if there is a good reason for putting uImage on the first
> > partition, how about implementing a fallback mechanism in boot.scr
> > so that the kernel is loaded from the ext2/3 fs on the second
> > partition if it is not found on the first. Or the other way round,
> > that the kernel is loaded from the first fat partition if not found
> > in the ext2/3 one. If
> This is a good idea! The boot script already tries to load the Kernel
> from NAND or SD wherever it is successfull.

Now that I could see that there are reasons for having uImage on the
first partition, I would be very happy if you could add two lines to the
current boot.scr which would fall back to loading uImage from /boot on
the second ext2/3 partition if not found on the first. As it wouldnt
influence boot time or anything with the current setup I guess this is
an acceptable change?

> But we are free and open source - and therefore you are free to spin
> your own variant(s) - even a different boot.scr. Distributions (SHR,
> QtMoko etc.) can adopt either method they like. It may also be better
> to distribute images as dd files instead of a makesd script (although
> they are tied to a specific SD card size).

dd images have the problem of fixed partition size for many differently
sized sd cards. This is why I thought that an (in my eyes) optimal setup
would look like: you guys have the makesd (or whatever) script which
makes the sdcard bootable by creating those two partitions and filling
the first with uboot stuff and the distribution guys distribute a
tarball that the user just extracts to the second.

sure everybody is free to do his own "makesd" (or whatever) script but i
also like it when there is consensus and unity over how to do things as
this introduces less confusion. but as you said - people who want to
invest time into diversity are of course still and always welcome to do
so.

cheers, josch


More information about the Gta04-owner mailing list