Difference between revisions of "ATF"
From Rockchip open source Document
Line 11: | Line 11: | ||
[http://10.10.10.12:8444/index.php?title=RK3399 RK3399] | [http://10.10.10.12:8444/index.php?title=RK3399 RK3399] | ||
+ | | ||
= Build ATF = | = Build ATF = | ||
Line 28: | Line 29: | ||
<pre>sudo apt-get install gcc-arm-none-eabi</pre> | <pre>sudo apt-get install gcc-arm-none-eabi</pre> | ||
− | We can get bl31.bin when build | + | We can get bl31.bin when build completed. |
| | ||
= Install ATF = | = Install ATF = | ||
− | |||
== Using U-Boot SPL FIT image == | == Using U-Boot SPL FIT image == | ||
Line 43: | Line 43: | ||
Alternatively, you can use Rockchip miniloader and U-Boot instead which do not need SPL. | Alternatively, you can use Rockchip miniloader and U-Boot instead which do not need SPL. | ||
− | The ATF is | + | The ATF is loaded by miniloader, so it should be package to know format for miniloader |
<pre>trust_merger rk_tools/RKTRUST/RK3399TRUST.ini atf.img</pre> | <pre>trust_merger rk_tools/RKTRUST/RK3399TRUST.ini atf.img</pre> | ||
According to the [http://10.10.10.12:8444/index.php?title=Partitions partitions] definition, write to atf.img offset 0x6000. | According to the [http://10.10.10.12:8444/index.php?title=Partitions partitions] definition, write to atf.img offset 0x6000. |
Revision as of 09:54, 29 March 2017
Contents
Download ARM Trusted Firmware
Get the source code from github:
git clone https://github.com/ARM-software/arm-trusted-firmware.git
Supported Devices[edit]
Upstream ARM Trusted Firmware support Rockchip SoCs:
Build ATF
Here is a mk-atf.sh script to build ATF.
$ cat mk-atf.sh #!/bin/bash make realclean CFLAGS='-gdwarf-2' \ CROSS_COMPILE=aarch64-linux-gnu- \ make PLAT=rk3399 DEBUG=1 ERROR_DEPRECATED=1 bl31
Because there is a blob of code for cortex-M0 in rk3399 ATF, so you need a compiler for it. Install it by:
sudo apt-get install gcc-arm-none-eabi
We can get bl31.bin when build completed.
Install ATF
Using U-Boot SPL FIT image
Upstream U-Boot SPL support for ATF still WIP.
Using Rockchip miniloader
Alternatively, you can use Rockchip miniloader and U-Boot instead which do not need SPL.
The ATF is loaded by miniloader, so it should be package to know format for miniloader
trust_merger rk_tools/RKTRUST/RK3399TRUST.ini atf.img
According to the partitions definition, write to atf.img offset 0x6000.