grub-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GRUB header magic numbers


From: Hollis Blanchard
Subject: Re: GRUB header magic numbers
Date: Wed, 28 Feb 2007 19:13:27 -0600

On Tue, 2007-02-27 at 16:46 -0800, Daniel Weaver wrote:
> Hello,
> 
> I have created a proprietary loader that serves much the same function as 
> GRUB.
> It is used to load a proprietary operating system.  One of the things I need
> in my system is the load length of the operating system.  Rather than
> reinvent the wheel I wish to use a GRUB style header to provide this
> information.  Some day in the future we may decide to change either the
> loader or the operating system and the use of a standard loader header
> will make the transition much easier.
> 
> My web searches have turned up two very similar multiboot headers.
> One with a magic number of 0x1BAD002 and another with a magic
> number of 0xe85250d6.
> 
> First off, why are there two numbers?

They are from different versions of the Multiboot specification:

http://www.gnu.org/software/grub/manual/multiboot/html_node/Header-magic-fields.html#Header-magic-fields

http://grub.enbug.org/MultibootDraft

It's not just the numbers; the formats are completely different.

> And which is more likely to be used in the long run?

The multiboot2 format, though multiboot1 will likely not go away in the
near term. multiboot1 was written without any thought for portability,
and since it's a large data structure it is very brittle.

The multiboot2 format is portable and much more flexible and extensible,
since it is based on a list of small structures. That said, it is not
yet in use by any major project (much like grub2 itself). There is no
multiboot2 loader for grub 0.9x (which is the version currently in use
by all Linux distributions).

If you're looking for a format to support, I would recommend multiboot2,
especially since you don't depend on interoperability with the current
generation of Linux software.

If you do choose to use multiboot2 and have any comments, questions, or
suggestions about the format, we'd love to hear about them here.

-Hollis





reply via email to

[Prev in Thread] Current Thread [Next in Thread]