Difference between revisions of "SeaBIOS"

From coreboot
Jump to: navigation, search
m (LegacyBIOS moved to SeaBIOS: The project was renamed)
m
Line 1: Line 1:
'''LegacyBIOS''' is an open-source legacy BIOS implementation, which can also be used as coreboot payload.
+
'''SeaBIOS''' (previously known as '''LegacyBIOS''') is an open-source legacy BIOS implementation, which can also be used as coreboot payload.
  
 
== Building ==
 
== Building ==
  
=== LegacyBIOS ===
+
=== SeaBIOS ===
  
You can download the latest version of LegacyBIOS through a git repository:
+
You can download the latest version of SeaBIOS through a git repository:
  
 
<source lang="bash">
 
<source lang="bash">
$ mkdir foo
+
$ git clone git://git.linuxtogo.org/home/kevin/legacybios.git seabios
$ cd foo
+
$ cd seabios
$ git clone git://git.linuxtogo.org/home/kevin/legacybios.git legacybios
 
$ cd legacybios
 
 
</source>
 
</source>
  
Alternatively, the released versions of LegacyBIOS can be found at http://linuxtogo.org/~kevin/legacybios/.  
+
Alternatively, the released versions of SeaBIOS can be found at http://linuxtogo.org/~kevin/legacybios/.  
  
 
Edit '''src/config.h''' and set the following values:
 
Edit '''src/config.h''' and set the following values:
Line 30: Line 28:
 
</source>
 
</source>
  
The final LegacyBIOS payload file is '''out/bios.bin.elf''', which can be used with coreboot v2 or v3.
+
The final SeaBIOS payload file is '''out/bios.bin.elf''', which can be used with coreboot v2 or v3.
  
 
=== coreboot ===
 
=== coreboot ===
  
Finally, you have to build coreboot (v3 in this example) with LegacyBIOS as payload:
+
Finally, you have to build coreboot (v3 in this example) with SeaBIOS as payload:
  
$ cd ..
+
<source lang="bash">
$ svn co svn://coreboot.org/repository/coreboot-v3
+
$ cd ..
$ cp legacybios/out/bios.bin.elf coreboot-v3/payload.elf
+
$ svn co svn://coreboot.org/repository/coreboot-v3
$ cd coreboot-v3
+
$ cp seabios/out/bios.bin.elf coreboot-v3/payload.elf
$ make menuconfig
+
$ cd coreboot-v3
 +
$ make menuconfig
 +
</source>
  
 
Now enter the '''Payload''' menu and select '''Payload type''' and then '''An ELF executable payload file'''. Now exit the menu, save your settings, and build coreboot:
 
Now enter the '''Payload''' menu and select '''Payload type''' and then '''An ELF executable payload file'''. Now exit the menu, save your settings, and build coreboot:
  
$ make
+
<source lang="bash">
 +
$ make
 +
</source>
  
The file '''build/coreboot.rom''' (or '''build/bios.bin''') is your final coreboot v3 image, which also contains the LegacyBIOS payload.
+
The file '''build/coreboot.rom''' (or '''build/bios.bin''') is your final coreboot v3 image, which also contains the SeaBIOS payload.
  
== Running LegacyBIOS in QEMU ==
+
== Running SeaBIOS in QEMU ==
  
For running coreboot+LegacyBIOS in QEMU, you need a patched version of '''vgabios-cirrus.bin''' in your '''build''' directory first:
+
For running coreboot+SeaBIOS in QEMU, you need a patched version of '''vgabios-cirrus.bin''' in your '''build''' directory first:
  
$ cd build
+
<source lang="bash">
$ wget http://www.coreboot.org/images/0/0d/Vgabios-cirrus.zip
+
$ cd build
$ unzip Vgabios-cirrus.zip
+
$ wget http://www.coreboot.org/images/0/0d/Vgabios-cirrus.zip
$ cd ..
+
$ unzip Vgabios-cirrus.zip
 +
$ cd ..
 +
</source>
  
 
You can now run LegacyBIOS in QEMU:
 
You can now run LegacyBIOS in QEMU:
  
$ qemu -L build -hda /dev/zero -serial stdio
+
<source lang="bash">
 +
$ qemu -L build -hda /dev/zero -serial stdio
 +
</source>
  
 
== Ready-made LegacyBIOS QEMU image ==
 
== Ready-made LegacyBIOS QEMU image ==

Revision as of 00:10, 4 July 2008

SeaBIOS (previously known as LegacyBIOS) is an open-source legacy BIOS implementation, which can also be used as coreboot payload.

Building

SeaBIOS

You can download the latest version of SeaBIOS through a git repository:

$ git clone git://git.linuxtogo.org/home/kevin/legacybios.git seabios
$ cd seabios

Alternatively, the released versions of SeaBIOS can be found at http://linuxtogo.org/~kevin/legacybios/.

Edit src/config.h and set the following values:

#define CONFIG_COREBOOT 1
#define CONFIG_DEBUG_SERIAL 1
#define CONFIG_PCIBIOS 0

Then:

$ make AVOIDCOMBINE=1

The final SeaBIOS payload file is out/bios.bin.elf, which can be used with coreboot v2 or v3.

coreboot

Finally, you have to build coreboot (v3 in this example) with SeaBIOS as payload:

$ cd ..
$ svn co svn://coreboot.org/repository/coreboot-v3
$ cp seabios/out/bios.bin.elf coreboot-v3/payload.elf
$ cd coreboot-v3
$ make menuconfig

Now enter the Payload menu and select Payload type and then An ELF executable payload file. Now exit the menu, save your settings, and build coreboot:

$ make

The file build/coreboot.rom (or build/bios.bin) is your final coreboot v3 image, which also contains the SeaBIOS payload.

Running SeaBIOS in QEMU

For running coreboot+SeaBIOS in QEMU, you need a patched version of vgabios-cirrus.bin in your build directory first:

$ cd build
$ wget http://www.coreboot.org/images/0/0d/Vgabios-cirrus.zip
$ unzip Vgabios-cirrus.zip
$ cd ..

You can now run LegacyBIOS in QEMU:

$ qemu -L build -hda /dev/zero -serial stdio

Ready-made LegacyBIOS QEMU image

TODO

Public domain I, the copyright holder of this work, hereby release it into the public domain. This applies worldwide.

In case this is not legally possible:
I grant anyone the right to use this work for any purpose, without any conditions, unless such conditions are required by law.