OVMF: Difference between revisions

From Xen
Jump to navigationJump to search
mNo edit summary
(Note on debug port)
Line 1: Line 1:
Tianocore / OVMF is integrated into Xen 4.4 release with essential patches upstreamed. However in 4.4 it is not built by default.
Tianocore / OVMF is integrated into Xen 4.4 release with essential patches upstreamed. However in 4.4 it is not built by default.


To build Xen with OVMF support, you would need to have '''--enable-ovmf''' when running '''configure'''.
To build Xen with OVMF support, you would need to have '''--enable-ovmf''' when running '''configure'''. If you would like to have hypervisor log output you will need to manually edit '''OvmfPkg.dec''', change '''PcdDebugIoPort''' to '''0xe9''' (which is the IO port used by Xen hypervisor logging facility) before building OVMF.


One thing to have in mind is Xen supports both its own QEMU fork called qemu-traditional and upstream QEMU called qemu-xen. OVMF only supports the latter. Xen 4.4 has upstream QEMU configured for all HVM guests by default, so it is fine to not specify which QEMU to use in guest config file. But if you have already configured qemu-traditional for your guest you would need to delete / comment out that line.
One thing to have in mind is Xen supports both its own QEMU fork called qemu-traditional and upstream QEMU called qemu-xen. OVMF only supports the latter. Xen 4.4 has upstream QEMU configured for all HVM guests by default, so it is fine to not specify which QEMU to use in guest config file. But if you have already configured qemu-traditional for your guest you would need to delete / comment out that line.

Revision as of 13:51, 28 January 2014

Tianocore / OVMF is integrated into Xen 4.4 release with essential patches upstreamed. However in 4.4 it is not built by default.

To build Xen with OVMF support, you would need to have --enable-ovmf when running configure. If you would like to have hypervisor log output you will need to manually edit OvmfPkg.dec, change PcdDebugIoPort to 0xe9 (which is the IO port used by Xen hypervisor logging facility) before building OVMF.

One thing to have in mind is Xen supports both its own QEMU fork called qemu-traditional and upstream QEMU called qemu-xen. OVMF only supports the latter. Xen 4.4 has upstream QEMU configured for all HVM guests by default, so it is fine to not specify which QEMU to use in guest config file. But if you have already configured qemu-traditional for your guest you would need to delete / comment out that line.

A typical guest config file looks like below. Nothing fancy, just the "bios=" option is important.

builder = 'hvm'
name = 's0-efi'

vcpus = 2

memory = 1024
# memory = 6000

vif = ['bridge=xenbr0']

# This is a disk image with EFI guest installed, you can also use live CD if you prefer.
# You can either specify xvda or hda, QEMU will start with emulated IDE drive in both cases.
# But if you speficy sda then it might not boot as OVMF doesn't have the driver at the moment.
disk = [ '/data/s0-efi.qcow2,qcow2,xvda,w' ]

on_crash = 'preserve'

vnc=1
vnclisten='0.0.0.0'

serial='pty'
bios='ovmf' # if you don't have this line, seabios will be used