# Boot flow and architecture overview

A cold boot refers to the process of starting the system from a power-off state. The cold boot process involves the following steps:

1. Cold boot starts the execution from the primary boot loader (PBL) that sets up the initial system for the eXtensible Boot Loader (XBL).
2. The XBL performs wider system initialization including DDR initialization and loads a UEFI image.
3. UEFI provides a rich firmware interface that loads systemd-boot as a boot manager on Qualcomm Linux to manage the OS images.

For more information about the complete cold boot flow, see [Cold boot
architecture](https://docs.qualcomm.com/bundle/publicresource/topics/80-70020-4/bootloader-architecture.html).

## UEFI boot managers

Qualcomm Linux supports systemd-boot as the Universal extensible firmware interface (UEFI) boot manager to load and boot the Linux kernel. The Qualcomm Linux kernel, in this case, is built as an EFI stub.

## Systemd-boot

Systemd-boot is a UEFI boot manager that executes EFI images, provides
boot entries, and supports unified kernel images (UKI). Systemd-boot supports
the following components:

- Boot entries: The type 1 boot loader specification entries are in the
`loader/entries/` directory on the ESP. These files describe the Qualcomm^®^ Linux
kernel images with the associated initrd images and other EFI
executables.
- UKI: The type 2 boot loader
specification EFI unified kernel images are executable EFI binaries located in the `/EFI/Linux/` directory on the ESP.

    For more information about the boot entries and unified kernel images, see
[The Boot Loader Specification](https://uapi-group.org/specifications/specs/boot_loader_specification/).

Systemd-boot is a part of the systemd package of the meta
Yocto layer. The Yocto recipe uses the
`systemd-boot_254.4.bb` recipe file to build systemd-boot and the `uki.bbclass` recipe
file to handle the ESP image generation.

For more information about systemd-boot, see
[Configure and secure boot with systemd-boot and UKI](https://docs.qualcomm.com/bundle/publicresource/topics/80-70020-27/qualcomm_linux_software_components.html#configure-and-secure-boot-with-systemd-boot-and-uki).

## Qualcomm Linux kernel as the EFI stub

The EFI boot stub allows booting the Qualcomm Linux kernel directly without a
conventional EFI boot loader.

The boot firmware can load the EFI image as an executable file when the
Qualcomm Linux kernel is compiled with the `CONFIG_EFI_STUB` kernel
configuration option. In this case, the firmware loader navigates to the
`EFI boot stub` location in the EFI image
`drivers/firmware/efi/libstub/` to boot the kernel.

For Arm^®^ (Arm64), where compressed kernel support is not available, the
kernel image functions as a portable executable (PE) file format or common
object file format (COFF) image, and the EFI stub is linked into the
kernel.

For more information about booting the Linux kernel as an EFI image, see
[The EFI Boot
Stub](https://docs.kernel.org/admin-guide/efi-stub.html).

## Boot images and ESP or boot partition

The ESP or boot partition serves as a storage location for the `efi.bin` image that packages
systemd-boot and UKI. The UKI includes kernel image, initramfs,
and kernel command-line arguments.

The UEFI firmware launches the UEFI boot loader and loads the kernel
boot images. The ESP is formatted with the file allocation table (FAT)
file system supported in the UEFI specification. For more information about the
UKI image format and the corresponding support in base Qualcomm Linux meta layers, see
[Configure and secure boot with systemd-boot and UKI](https://docs.qualcomm.com/bundle/publicresource/topics/80-70020-27/configure_and_secure_boot_with_systemd_boot_and_uki.html).

## Device tree blob selection

All the device tree blobs are packaged as part of `dtb.bin`. The UEFI selects and loads the right DTB for the Qualcomm Linux kernel.

To understand the boot time DTB selection, see [Platform device tree](https://docs.qualcomm.com/doc/80-70020-3/topic/kernel-development.html#device-tree).

Last Published: Jul 02, 2025

[Previous Topic
Get started with the Qualcomm Linux kernel](https://docs.qualcomm.com/bundle/publicresource/80-70020-3/topics/getting_started_chapter2.md) [Next Topic
Configure the postboot settings](https://docs.qualcomm.com/bundle/publicresource/80-70020-3/topics/post-boot-settings.md)