The Gigaboot boot loader is a UEFI boot shim for Zircon that can load images via chaining from iPXE, from a UEFI-accessible filesystem, or from local disk partitions.
Arguments are taken from the kernel command line, or additionally from the EFI command line for Gigaboot itself.
bootloader.zircon-a: Sets the fallback filename to use for loading the Zircon-A image (default:
bootloader.zircon-b: Sets the fallback filename to use for loading the Zircon-B image (default:
bootloader.zircon-r: Sets the fallback filename to use for loading the Zircon-R (recovery) image (default: none).
bootloader.fbres: Sets the framebuffer resolution (e.g.
1024x768; default: automatic).
bootloader.default: Sets the default boot choice in the boot menu; default is the first in the list. Possible values are
Gigaboot supports fastboot over UDP. You can enter fastboot mode by pressing
f during boot, or by invoking
dm reboot-bootloader from Fuchsia.
Gigaboot implements the fastboot over UDP protocol described here.
# Replace the IP with your device's IP, which is printed to serial and the # display on boot. fastboot -s udp:fe80::aaaa:bbbb:cccc:dddd getvar all # Depending on your host network setup, you may need to specify a particular # network interface as well. fastboot -s udp:fe80::aaaa:bbbb:cccc:dddd%enx123 getvar all
|Reboots the device into the current active partition, as determined by ABR.|
|Reboots the device into R.|
|Reboots the device into Fastboot mode.|
|Flashes the given image onto the given partition.|
|Erases a partition by writing 0xff to it.|
|Gets the value of the given variable.|
The partitions available for flashing/erasing are listed here.
|A meta-variable that lists all variables stored in the bootloader.|
|The maximum image size that can be sent over|
|The number of slots that can be set active on the device.|
|The minimum required version of the bootloader.|
|The slot currently marked active by ABR.|
|The fastboot protocol version.|
Here is an example iPXE script showing how to chain Gigaboot. In this example, the files are loaded from a web server running on 192.168.42.128; we chain from Gigaboot into Zedboot.
#!ipxe echo Chain loader :loop2 prompt --key 0x02 --timeout 3000 Chain Loader: Press Ctrl-B for the iPXE command line... && shell || kernel http://192.168.42.128/gigaboot.efi bootloader.default=local bootloader.zircon-a=zedboot.zbi || goto loop2 :zedboot initrd http://192.168.42.128/zedboot.zbi || goto loop2 :boot boot || goto loop2
Since UEFI images are in PE32+ file format, we require that our binaries be position independent executables with no relocations. For the most part this does not require any extra effort on x86-64, but it does mean that you cannot statically initialize any variables that hold an address. (These addresses may be assigned at runtime however.)
qemu-system-x86_64 is needed to test in emulation; gnu parted and mtools are needed to generate the disk.img for Qemu.
ACPI & UEFI Specifications: http://www.uefi.org/specifications
Intel 64 and IA-32 Architecture Manuals: http://www.intel.com/content/www/us/en/processors/architectures-software-developer-manuals.html