grub-devel
[Top][All Lists]
Advanced

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

[multiboot] command-line format


From: Grégoire Sutre
Subject: [multiboot] command-line format
Date: Thu, 14 Jan 2010 17:53:25 +0100
User-agent: Thunderbird 2.0.0.23 (X11/20091027)

Hi,

Vladimir just sent a patch regarding this issue, but I had this long (sorry!) email almost finished already, so here it is. And this might give more context for Vladimir's email.
As mentioned in a previous thread, I had some problems getting multiboot 
options recognized by the NetBSD kernel, and this was actually due to 
the fact that GRUB Legacy implicitly passes the booted file as first 
argument whereas GRUB 2 doesn't [1].
I started a thread on NetBSD's port-i386 mailing list [2] on the format 
of the multiboot command-line, and the discussion moved towards the 
change in GRUB regarding the first argument (booted kernel in GRUB 
Legacy, removed in GRUB 2).  I ended up doing tests with Xen, which is 
also multiboot-compliant, and Xen also skips the first argument in its 
command-line parsing code (well, it's a bit more complex, see [3] for 
details if you're interested).
In the end, it may be the case that most multiboot-compliant kernels out 
there still assume that the first argument is the booted file name, and 
skip it without even looking at it.  Do you know of any kernel that does 
not make this assumption?
There are also other multiboot-compliant boot loaders (e.g. NetBSD's 
boot loader).  Apart from GRUB 2, do you know of another boot-loader 
that does not put the booted file name as first argument?
I understand that the specification does not enforce the boot loader to 
follow a specific command-line format.  And, in a perfect world, 
developers should follow the specification, disregarding any particular 
implementation of the specification.  But I guess we don't live in a 
perfect world ;-)
The reference implementation (GRUB legacy) for the specification led 
kernel developers to assume a specific command-line format.  And for the 
sake of backward compatibility, all multiboot command-lines for those 
kernels should contain the booted file name as first argument.  So why 
not change the specification in this way, i.e. require that the 
command-line starts with the booted file name?  I believe that this 
would merely amount to writing down what most users of the specification 
had already in mind...
Grégoire

p.s. I guess that there are not many GRUB developers on the NetBSD
mailing lists, and, for my part, this topic is new...  Feel free to
intervene :-)

[1] http://lists.gnu.org/archive/html/grub-devel/2010-01/msg00146.html
[2] http://mail-index.netbsd.org/port-i386/2010/01/09/msg001747.html
[3] http://mail-index.netbsd.org/port-i386/2010/01/14/msg001768.html





reply via email to

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