RNX-RZG2UL-OSM ARM Trusted Firmware: Difference between revisions

From Ronetix's Wiki
Jump to navigation Jump to search
initial creation
 
Modify to skip Section Level 1 formatting
 
(6 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{#vardefine:HARDWARE_NAME|RNX-RZG2UL-OSM}}
{{#vardefine:HARDWARE_NAME|RNX-RZG2UL-OSM}}
{{#vardefine:ATF_BRANCH|v2.9/rz}}
{{#vardefine:ATF_BRANCH|v2.9/rz}}
= Overview =
[[File:RNX-RZG2UL-OSM_top.png|thumb]]
== Overview ==
Trusted Firmware-A (TF-A) is a reference implementation of secure world software for Arm A-Profile architectures (Armv8-A and Armv7-A), including an Exception Level 3 (EL3) Secure Monitor. It provides a suitable starting point for productization of secure world boot and runtime firmware, in either the AArch32 or AArch64 execution states.
Trusted Firmware-A (TF-A) is a reference implementation of secure world software for Arm A-Profile architectures (Armv8-A and Armv7-A), including an Exception Level 3 (EL3) Secure Monitor. It provides a suitable starting point for productization of secure world boot and runtime firmware, in either the AArch32 or AArch64 execution states.


= Building ARM Truster Firmware for {{#var:HARDWARE_NAME}} =
== Building ARM Truster Firmware for {{#var:HARDWARE_NAME}} ==
This U-BOOT is based on https://github.com/renesas-rz/renesas-u-boot-cip, branch {{#var:UBOOT_BRANCH}}
This U-BOOT is based on https://github.com/renesas-rz/renesas-u-boot-cip, branch {{#var:UBOOT_BRANCH}}


==== Set up the cross-compiler and CPU architecture ====
=== Set up the cross-compiler and CPU architecture ===
  $ export ARCH=arm64
  $ export ARCH=arm64
  $ export CROSS_COMPILE=/opt/cross/aarch64-ronetix-linux-11.1/bin/aarch64-ronetix-linux-gnu-
  $ export CROSS_COMPILE=/opt/cross/aarch64-ronetix-linux-11.1/bin/aarch64-ronetix-linux-gnu-
Line 14: Line 15:
http://download.ronetix.at/toolchains/crosstool-ng
http://download.ronetix.at/toolchains/crosstool-ng


==== Clone the latest revision ====
=== Clone the latest revision ===
  $ git clone https://github.com/ronetix/arm-trusted-firmware.git
  $ git clone https://github.com/ronetix/arm-trusted-firmware.git
  $ cd arm-trusted-firmware
  $ cd arm-trusted-firmware
  $ git checkout remotes/origin/{{#var:ATF_BRANCH}} -b {{#var:ATF_BRANCH}}
  $ git checkout remotes/origin/{{#var:ATF_BRANCH}} -b {{#var:ATF_BRANCH}}


==== Build ====
=== Build ===
  $ make PLAT=g2ul BOARD=g2ul_smarc SOC_TYPE=1 SPI_FLASH=AT25QL128A
  $ make PLAT=g2ul BOARD=g2ul_smarc SOC_TYPE=1 SPI_FLASH=AT25QL128A
  $ make fiptool
  $ make fiptool


= Build Results =
=== Build Results ===
{| class="wikitable"
{| class="wikitable"
|-
|-
Line 38: Line 39:
| style="padding: 5px;"| FIP tool
| style="padding: 5px;"| FIP tool
|}
|}
=== Add boot parameters to bl2.bin ===
In order to boot bl2.bin, the Renesas RZ/G2UL internal bootloaders needs a boot parameters block.
The boot parameters block is 512 bytes long, and the bl2.bin is located immediately after it.
$ tools/renesas/bootparameters/bootparameters.sh build/g2ul/release/bl2.bin
The result is '''''bl2_bp.bin''''', which should be programmed at address 0x0 in the QSPI Flash.
<!-- use template -->
{{SeeAlso}}
* [https://renesas.info/wiki/RZ-G/RZ-G2%20BSP%20Porting%20ATF https://renesas.info/wiki/RZ-G/RZ-G2 BSP Porting ATF]

Latest revision as of 15:46, 16 November 2023


Overview

Trusted Firmware-A (TF-A) is a reference implementation of secure world software for Arm A-Profile architectures (Armv8-A and Armv7-A), including an Exception Level 3 (EL3) Secure Monitor. It provides a suitable starting point for productization of secure world boot and runtime firmware, in either the AArch32 or AArch64 execution states.

Building ARM Truster Firmware for RNX-RZG2UL-OSM

This U-BOOT is based on https://github.com/renesas-rz/renesas-u-boot-cip, branch

Set up the cross-compiler and CPU architecture

$ export ARCH=arm64
$ export CROSS_COMPILE=/opt/cross/aarch64-ronetix-linux-11.1/bin/aarch64-ronetix-linux-gnu-

Cross-compiler can be downloaded from here: http://download.ronetix.at/toolchains/crosstool-ng

Clone the latest revision

$ git clone https://github.com/ronetix/arm-trusted-firmware.git
$ cd arm-trusted-firmware
$ git checkout remotes/origin/v2.9/rz -b v2.9/rz

Build

$ make PLAT=g2ul BOARD=g2ul_smarc SOC_TYPE=1 SPI_FLASH=AT25QL128A
$ make fiptool

Build Results

File Name Description
build/g2ul/release/bl2.bin BL2 bootloader
build/g2ul/release/bl31.bin BL3 bootloader
tools/fiptool/fiptool FIP tool

Add boot parameters to bl2.bin

In order to boot bl2.bin, the Renesas RZ/G2UL internal bootloaders needs a boot parameters block. The boot parameters block is 512 bytes long, and the bl2.bin is located immediately after it.

$ tools/renesas/bootparameters/bootparameters.sh build/g2ul/release/bl2.bin

The result is bl2_bp.bin, which should be programmed at address 0x0 in the QSPI Flash.

See also