GRUB2: Difference between revisions

From coreboot
Jump to navigation Jump to search
No edit summary
Line 3: Line 3:
GRUB2 gives an ideal payload for coreboot. It's modular, extensible, supports booting off filesystems, and it has a scriptable shell. Our goal is to replace the common coreboot payload [[FILO]] with a coreboot-capable version of GRUB2.
GRUB2 gives an ideal payload for coreboot. It's modular, extensible, supports booting off filesystems, and it has a scriptable shell. Our goal is to replace the common coreboot payload [[FILO]] with a coreboot-capable version of GRUB2.


== Status ==
== History ==


Patrick Georgi has been working on GRUB2 for coreboot during the Google Summer of Code 2007. He made an [http://coreboot.org/~oxygene/lbgrub2-20070820-1.tar.bz2 original code submission] on August 20th 2007. Please read [http://coreboot.org/~oxygene/lbgrub2-instructions.txt GRUB2 on coreboot instructions] for information on how to use it.
Patrick Georgi has been working on GRUB2 for coreboot during the Google Summer of Code 2007. He made an [http://coreboot.org/~oxygene/lbgrub2-20070820-1.tar.bz2 original code submission] on August 20th 2007. Please read [http://coreboot.org/~oxygene/lbgrub2-instructions.txt GRUB2 on coreboot instructions] for information on how to use it.


This work was subsequently rejected by the GRUB project, and was eventually re-implemented by Robert Millan, one of the GRUB project members. The re-implementation lacks a couple of fundamental features. As of the time of this writing, it can not be loaded in coreboot v2.  
This work was subsequently rejected by the GRUB project, and was eventually re-implemented by Robert Millan, one of the GRUB project members. The re-implementation lacks a couple of fundamental features. From this new base, more work was done.
 
== Status ==
 
As of the time of this writing, the official GRUB2 can not be loaded in coreboot v2 without a small patch. It works fine with coreboot v3.


* A significant amount of work has been put into GRUB2 in our [http://www.coreboot.org:8889/ GRUB2 monotone repository]. A current snapshot of GRUB2 for coreboot can be downloaded via monotone or via the web frontend.
* A significant amount of work has been put into GRUB2 in our [[MonotoneRepository]], which also provides snapshots.
* The mainline version of GRUB2 has a [http://grub.enbug.org/CoreBoot wiki page on the coreboot port]
* The mainline version of GRUB2 has a [http://grub.enbug.org/CoreBoot wiki page on the coreboot port]


Line 25: Line 29:
  $ $PWD/installed/bin/grub-mkimage -o core.img normal fat iso9660 ext2 pc atadisk rom lar ls cat cmp hello help serial terminal test configfile multiboot boot loopback
  $ $PWD/installed/bin/grub-mkimage -o core.img normal fat iso9660 ext2 pc atadisk rom lar ls cat cmp hello help serial terminal test configfile multiboot boot loopback


NOTE: newer versions of GRUB2 replaced the rom module by memdisk and the atadisk module by ata.
NOTE: newer versions of GRUB2 replaced the rom module by memdisk (our changes needed for that) and the atadisk module by ata.


== How to help? ==
== How to help? ==


Contact [mailto:stepan@coresystems.de Stefan Reinauer], [mailto:oxygene@coresystems.de Patrick Georgi] or the [[Mailinglist|LinuxBIOS mailing list]] for more information.
Contact [mailto:stepan@coresystems.de Stefan Reinauer], [mailto:oxygene@coresystems.de Patrick Georgi] or the [[Mailinglist|coreboot mailing list]] for more information.

Revision as of 08:14, 17 March 2008

Introduction

GRUB2 gives an ideal payload for coreboot. It's modular, extensible, supports booting off filesystems, and it has a scriptable shell. Our goal is to replace the common coreboot payload FILO with a coreboot-capable version of GRUB2.

History

Patrick Georgi has been working on GRUB2 for coreboot during the Google Summer of Code 2007. He made an original code submission on August 20th 2007. Please read GRUB2 on coreboot instructions for information on how to use it.

This work was subsequently rejected by the GRUB project, and was eventually re-implemented by Robert Millan, one of the GRUB project members. The re-implementation lacks a couple of fundamental features. From this new base, more work was done.

Status

As of the time of this writing, the official GRUB2 can not be loaded in coreboot v2 without a small patch. It works fine with coreboot v3.

Todo

  • Mainstream GRUB2's grub-mkimage needs to put the program headers right after the elf header (Fix available).
  • USB stack integration (in progress)
  • See more information in the "Porting GRUB2 to coreboot" milestone in the coreboot issue tracker.

How to build GRUB2 as a payload

$ # build lbgrub2:
$ # target/target_alias assume that you use i386-elf-gcc
$ configure --with-platform=linuxbios --prefix=$PWD/installed 
$ make && make install
$ $PWD/installed/bin/grub-mkimage -o core.img normal fat iso9660 ext2 pc atadisk rom lar ls cat cmp hello help serial terminal test configfile multiboot boot loopback

NOTE: newer versions of GRUB2 replaced the rom module by memdisk (our changes needed for that) and the atadisk module by ata.

How to help?

Contact Stefan Reinauer, Patrick Georgi or the coreboot mailing list for more information.