[coreboot] Time for a new project
Philip Schulz
philip.s.schulz at googlemail.com
Sun Apr 13 15:44:56 CEST 2008
Hi Jordan,
please don't take my comments as criticism, I'm merely trying to
learn something from this discussion.
2008/4/13, Jordan Crouse <jordan.crouse at amd.com>:
> On 11/04/08 16:43 -0700, ron minnich wrote:
> > So, ignore me if you will, but how about
> > 'CODE'
> > 'DATA'
> > 'BSS '
> > 'NAME'
> > 'NOTE'
> > 'ENTR'
>
> I dig this. We will make it so. I think we should also force all the
> header members to be little endian to avoid issues later on with
> PowerPC.
>
I wonder what issues with PowerPC you're expecting? Shouldn't you have
the header members stored in the endianness of the target
architecture? I.e. if you construct a SELF file for i386, then of
course the header fields should be little endian, even if you chose to
construct the file on a PowerPC machine. But not if you want to use
the SELF file on a big endian architecture - then the headers should
be big endian.
In a later email in this thread, you say this:
2008/4/13, Jordan Crouse <jordan.crouse at amd.com>:
[...]
> We already know what endianism, word size and architecture we're going to
> run on - SELF is not intended to be portable. It is constructed when
> the LAR is, and is married to that LAR and that LAR only. And before
> somebody says something, yes - this is not fool-proof. Somebody will
> no doubt manage to screw it up and get the wrong SELF on the wrong
> architecture. But I don't like over-architecting to protect fools.
> Worrying about specifying the architecture here is the computer science
> equivalent of the "Caution, coffee is hot" warning.
I interpreted the above like this: When constructing a SELF file you
will always know what architecture the SELF file will be used on and
you therefore don't need an explicit endianness flag. You don't need
it b/c you implicitly assume the byte order of the target
architecture.
So I may have misunderstood your emails, but please don't force the
SELF headers to a specific endianness. I don't think it's necessary
and doing so will cause unnecessary work as soon as you're trying to
use the format on an architecture w/ different endianness. See EFI and
especially TianoCore.
Regards,
Phil
More information about the coreboot
mailing list