Skip to content

96boards-poplar/l-loader

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

52 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Copyright (c) 2017 Linaro Limited

The l-loader is a 32 bit executable that transitions the default processor state to 64 bit mode and boots the ARM Trusted Firmware.

It complies with platform's BootROM requirements to support booting the Poplar board

This is achieved via encoding values as well as binaries at pre-defined locations in the program file.

Requirements:

  1. BootROM shall receive the PLL/DDR/regulator settings from l-loader

  1. BootROM shall receive the size of the binary to boot as well as the expected RAM location to boot it from.

BootROM platform initialization

The basic platform initialization is encoded in a number of pre-compiled binaries included at certain locations in l-loader

  • AUXCODE.img
  • BOOT_[0..2].reg

The location (i.e., offset relative to the base of the TEXT segment) of the AUXCODE is defined by the address stored at offset CONFIG_AUXCODE_AREA_POS.
The location of BOOT_[0..2].reg blocks are defined by the address stored at offset CONFIG_PARAM_START_ADDR_POS.

The boot process.

Once the BootROM has executed the AUXCODE initialization binary, it loads the rest of the file in DDR for execution.

The location in DDR where the binary shall be placed is written at CONFIG_BOOT_STORE_ADDR_POS and its value defined by CONFIG_BOOT_STORE_ADDR_VAL.

The size of the binary that shall be copied to DDR needs to be placed at CONFIG_TOTAL_BOOT_AREA_LEN_POS.

ROM then jumps to the offset specified in CONFIG_BOOT_ENTRY_POS, which contains the instruction to branch to; l-loader then executes a warm reboot into 64bit mode to start.S in the atf.

Compilation

  • pull and build the ATF:

    $ git clone https://github.com/96boards-poplar/arm-trusted-firmware.git
    $ cd arm-trusted-firmware
    $ make CROSS_COMPILE=aarch64-linux-gnu- all fip
    SPD=none BL33=~/poplar/bin/u-boot.bin DEBUG=1 PLAT=poplar <br>

  • copy the ATF (bl1.bin, fip.bin) to l-loader/atf/

  • build l-loader:

    $ cd l-loader
    $ make clean
    $ make

Releases

No releases published

Packages

No packages published

Languages

  • Assembly 78.6%
  • Makefile 21.4%