Boot Process

From linux-sunxi.org
Jump to: navigation, search

Our SoCs have a very specific boot process. First it executes a tiny on chip rom (BROM) which then checks the buttons for FEL mode and then starts checking the various storage options for a valid boot signature at the right location.

Generally, the BROM first check SD-card boot availability, then in second, NAND one. The BROM will try to load the SPL from U-Boot in each of these devices, which in turn loads the kernel.

Contents

NAND and SD-card

There is no real difference between NAND and an SD-card apart from the fact that directly attached flash use the Sunxi NAND controller directly while SD-Cards come with a standard interface and an embedded controller. The sunxi nand controller is harder to implement than the sunxi sd-card controller, and the sample code provided by allwinner is rather large (and shared between U-boot and the kernel).

  • "Bootable SD card" article contains more informations about SD card boot process and explains how to make a bootable SD card.
  • "NAND" article contains more informations about NAND boot process
  • "Installing to NAND" article contains informations to make a bootable NAND.

Other

That's also possible to boot system on other devices (SATA, USB, network using TFTP/NFS,...) but U-boot standing on NAND or SD card is needed as first boot step.

Network

The kernel can be loaded using TFTP, that is supported by U-boot and system can be booted using NFS. In network boot process, each of this choice are not mandatory for the other one.

SATA

A10 and A20 SoCs, support SATA controler. U-boot also support SATA boot process. That's so possible to boot on SATA device (hard disc drive, solid state device, ...).

In this case, initial Ramdisk is needed.

USB

Most devices with Allwinner SoC have USB ports. U-boot also support USB Boot but U-boot needs to be built specifically for booting over USB

  • FEL/USBBoot explains how to prepare U-boot for USB boot.

A10 Boot overview

While the Allwinner series of SoC's are quite open, there is an unmodifiable ROM called BROM or Boot ROM that is in charge of booting the SoC. The BROM will try to load the SPL from U-Boot, which in turn loads the kernel.

It should be noted, that if using Allwinner bootloaders (especially true when booting from nand storage), the order is slightly different. BROM loads boot0 as its SPL and that chainloads boot1. These all reside in unaccessable (not easily anyway) nand flash, before the partition table. boot1 loads boot.axf from the first fat partition which in turn chainloads (in our case) u-boot and then the kernel. It is in theory possible to directly boot the kernel, or some other OS. Also boot.axf has the ability to display images on the framebuffer.

Personal tools
Namespaces

Variants
Actions
Navigation
Tools