Commit 7af4d2b6 authored by Douglas Raillard's avatar Douglas Raillard
Browse files

Fix various small issues in the documentation



Change some hard-to-convert constructs to cleaner ones.
Fix a broken link.

Change-Id: Ida70aa1da0af7a107b0e05eb20b8d46669a0380b
Signed-off-by: default avatarDouglas Raillard <douglas.raillard@arm.com>
parent aa5b843f
...@@ -64,8 +64,7 @@ Making Changes ...@@ -64,8 +64,7 @@ Making Changes
changes (and nothing else) in the last commit of the series. Otherwise, changes (and nothing else) in the last commit of the series. Otherwise,
include the documentation changes within the single commit. include the documentation changes within the single commit.
* Please test your changes. As a minimum, ensure UEFI boots to the shell on * Please test your changes. As a minimum, ensure UEFI boots to the shell on
the Foundation FVP. See the "[Running the software]" section of the the Foundation FVP. See [Running the software on FVP] for more information.
[User Guide] for more information.
Submitting Changes Submitting Changes
...@@ -105,7 +104,7 @@ _Copyright (c) 2013-2017, ARM Limited and Contributors. All rights reserved._ ...@@ -105,7 +104,7 @@ _Copyright (c) 2013-2017, ARM Limited and Contributors. All rights reserved._
[User Guide]: ./docs/user-guide.md [User Guide]: ./docs/user-guide.md
[Running the software]: ./docs/user-guide.md#6--running-the-software [Running the software on FVP]: ./docs/user-guide.md#8--running-the-software-on-fvp
[Porting Guide]: ./docs/porting-guide.md [Porting Guide]: ./docs/porting-guide.md
[Firmware Design]: ./docs/firmware-design.md [Firmware Design]: ./docs/firmware-design.md
[Acknowledgements]: ./acknowledgements.md "Contributor acknowledgements" [Acknowledgements]: ./acknowledgements.md "Contributor acknowledgements"
......
...@@ -87,5 +87,7 @@ respectively. ...@@ -87,5 +87,7 @@ respectively.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
_Copyright (c) 2017, ARM Limited and Contributors. All rights reserved._
[Firmware Design]: ./firmware-design.md [Firmware Design]: ./firmware-design.md
[SMCCC]: http://infocenter.arm.com/help/topic/com.arm.doc.den0028a/index.html "SMC Calling Convention PDD (ARM DEN 0028A)" [SMCCC]: http://infocenter.arm.com/help/topic/com.arm.doc.den0028a/index.html "SMC Calling Convention PDD (ARM DEN 0028A)"
...@@ -31,17 +31,16 @@ to the stage where it hands-off control to firmware running in the normal ...@@ -31,17 +31,16 @@ to the stage where it hands-off control to firmware running in the normal
world in DRAM. This is the cold boot path. world in DRAM. This is the cold boot path.
The ARM Trusted Firmware also implements the Power State Coordination Interface The ARM Trusted Firmware also implements the Power State Coordination Interface
([PSCI]) PDD [2] as a runtime service. PSCI is the interface from normal world PDD [2] as a runtime service. PSCI is the interface from normal world software
software to firmware implementing power management use-cases (for example, to firmware implementing power management use-cases (for example, secondary CPU
secondary CPU boot, hotplug and idle). Normal world software can access ARM boot, hotplug and idle). Normal world software can access ARM Trusted Firmware
Trusted Firmware runtime services via the ARM SMC (Secure Monitor Call) runtime services via the ARM SMC (Secure Monitor Call) instruction. The SMC
instruction. The SMC instruction must be used as mandated by the [SMC Calling instruction must be used as mandated by the SMC Calling Convention [3].
Convention PDD][SMCCC] [3].
The ARM Trusted Firmware implements a framework for configuring and managing The ARM Trusted Firmware implements a framework for configuring and managing
interrupts generated in either security state. The details of the interrupt interrupts generated in either security state. The details of the interrupt
management framework and its design can be found in [ARM Trusted management framework and its design can be found in ARM Trusted Firmware
Firmware Interrupt Management Design guide][INTRG] [4]. Interrupt Management Design guide [4].
The ARM Trusted Firmware can be built to support either AArch64 or AArch32 The ARM Trusted Firmware can be built to support either AArch64 or AArch32
execution state. execution state.
...@@ -390,8 +389,8 @@ BL2 relies on EL3 Runtime Software to pass control to BL33 once secure state ...@@ -390,8 +389,8 @@ BL2 relies on EL3 Runtime Software to pass control to BL33 once secure state
initialization is complete. Hence, BL2 populates a platform-specific area of initialization is complete. Hence, BL2 populates a platform-specific area of
memory with the entrypoint and Saved Program Status Register (`SPSR`) of the memory with the entrypoint and Saved Program Status Register (`SPSR`) of the
normal world software image. The entrypoint is the load address of the BL33 normal world software image. The entrypoint is the load address of the BL33
image. The `SPSR` is determined as specified in Section 5.13 of the [PSCI PDD] image. The `SPSR` is determined as specified in Section 5.13 of the
[PSCI]. This information is passed to the EL3 Runtime Software. [PSCI PDD][PSCI]. This information is passed to the EL3 Runtime Software.
#### AArch64 BL31 (EL3 Runtime Software) execution #### AArch64 BL31 (EL3 Runtime Software) execution
...@@ -2303,9 +2302,9 @@ kernel at boot time. These can be found in the `fdts` directory. ...@@ -2303,9 +2302,9 @@ kernel at boot time. These can be found in the `fdts` directory.
1. Trusted Board Boot Requirements CLIENT PDD (ARM DEN 0006B-5). Available 1. Trusted Board Boot Requirements CLIENT PDD (ARM DEN 0006B-5). Available
under NDA through your ARM account representative. under NDA through your ARM account representative.
2. [Power State Coordination Interface PDD (ARM DEN 0022B.b)][PSCI]. 2. [Power State Coordination Interface PDD][PSCI]
3. [SMC Calling Convention PDD (ARM DEN 0028A)][SMCCC]. 3. [SMC Calling Convention PDD][SMCCC]
4. [ARM Trusted Firmware Interrupt Management Design guide][INTRG]. 4. [ARM Trusted Firmware Interrupt Management Design guide][INTRG].
...@@ -2314,8 +2313,8 @@ kernel at boot time. These can be found in the `fdts` directory. ...@@ -2314,8 +2313,8 @@ kernel at boot time. These can be found in the `fdts` directory.
_Copyright (c) 2013-2016, ARM Limited and Contributors. All rights reserved._ _Copyright (c) 2013-2016, ARM Limited and Contributors. All rights reserved._
[ARM ARM]: http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.ddi0487a.e/index.html "ARMv8-A Reference Manual (ARM DDI0487A.E)" [ARM ARM]: http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.ddi0487a.e/index.html "ARMv8-A Reference Manual (ARM DDI0487A.E)"
[PSCI]: http://infocenter.arm.com/help/topic/com.arm.doc.den0022c/DEN0022C_Power_State_Coordination_Interface.pdf "Power State Coordination Interface PDD (ARM DEN 0022C)" [PSCI]: http://infocenter.arm.com/help/topic/com.arm.doc.den0022d/Power_State_Coordination_Interface_PDD_v1_1_DEN0022D.pdf "Power State Coordination Interface PDD (ARM DEN 0022D)"
[SMCCC]: http://infocenter.arm.com/help/topic/com.arm.doc.den0028a/index.html "SMC Calling Convention PDD (ARM DEN 0028A)" [SMCCC]: http://infocenter.arm.com/help/topic/com.arm.doc.den0028b/ARM_DEN0028B_SMC_Calling_Convention.pdf "SMC Calling Convention PDD (ARM DEN 0028B)"
[UUID]: https://tools.ietf.org/rfc/rfc4122.txt "A Universally Unique IDentifier (UUID) URN Namespace" [UUID]: https://tools.ietf.org/rfc/rfc4122.txt "A Universally Unique IDentifier (UUID) URN Namespace"
[User Guide]: ./user-guide.md [User Guide]: ./user-guide.md
[Porting Guide]: ./porting-guide.md [Porting Guide]: ./porting-guide.md
......
Description Description
==================== ====================
HiKey is one of 96boards. Hisilicon Kirin6220 processor is installed on HiKey. HiKey is one of 96boards. Hisilicon Kirin6220 processor is installed on HiKey.
More information are listed in [link](https://github.com/96boards/documentation/blob/master/ConsumerEdition/HiKey/Quickstart/README.md). More information are listed in [link](https://github.com/96boards/documentation/blob/master/ConsumerEdition/HiKey/Quickstart/README.md).
How to build How to build
...@@ -38,61 +38,79 @@ How to build ...@@ -38,61 +38,79 @@ How to build
Make all the repositories in the same ${BUILD_PATH}. Make all the repositories in the same ${BUILD_PATH}.
* Create the symbol link to OpenPlatformPkg in edk2. * Create the symbol link to OpenPlatformPkg in edk2.
<br>`$cd ${BUILD_PATH}/edk2`</br> ```shell
<br>`$ln -sf ../OpenPlatformPkg`</br> $cd ${BUILD_PATH}/edk2
$ln -sf ../OpenPlatformPkg
```
* Prepare AARCH64 && AARCH32 toolchain. Prepare python. * Prepare AARCH64 && AARCH32 toolchain. Prepare python.
* If your hikey hardware is built by CircuitCo, update _uefi-tools/platform.config_ first. _(optional)_ * If your hikey hardware is built by CircuitCo, update _uefi-tools/platform.config_ first. _(optional)_
<br>__Uncomment the below sentence. Otherwise, UEFI can't output messages on serial __Uncomment the below sentence. Otherwise, UEFI can't output messages on serial
console on hikey.__</br> console on hikey.__
<br>`BUILDFLAGS=-DSERIAL_BASE=0xF8015000`</br> ```shell
<br>If your hikey hardware is built by LeMarker, nothing to do.</br> BUILDFLAGS=-DSERIAL_BASE=0xF8015000
```
If your hikey hardware is built by LeMarker, nothing to do.
* Build it as debug mode. Create your own build script file or you could refer to __build_uefi.sh__ in l-loader git repository. * Build it as debug mode. Create your own build script file or you could refer to __build_uefi.sh__ in l-loader git repository.
<br>`BUILD_OPTION=DEBUG`</br> ```shell
<br>`export AARCH64_TOOLCHAIN=GCC5`</br> BUILD_OPTION=DEBUG
<br>`export UEFI_TOOLS_DIR=${BUILD_PATH}/uefi-tools`<br> export AARCH64_TOOLCHAIN=GCC5
<br>`export EDK2_DIR=${BUILD_PATH}/edk2`</br> export UEFI_TOOLS_DIR=${BUILD_PATH}/uefi-tools
<br>`EDK2_OUTPUT_DIR=${EDK2_DIR}/Build/HiKey/${BUILD_OPTION}_${AARCH64_TOOLCHAIN}`</br> export EDK2_DIR=${BUILD_PATH}/edk2
<br>`# Build fastboot for ARM Trust Firmware. It's used for recovery mode.`</br> EDK2_OUTPUT_DIR=${EDK2_DIR}/Build/HiKey/${BUILD_OPTION}_${AARCH64_TOOLCHAIN}
<br>`cd ${BUILD_PATH}/atf-fastboot`</br> # Build fastboot for ARM Trust Firmware. It's used for recovery mode.
<br>`CROSS_COMPILE=aarch64-linux-gnu- make PLAT=hikey DEBUG=1`</br> cd ${BUILD_PATH}/atf-fastboot
<br>`# Convert DEBUG/RELEASE to debug/release`</br> CROSS_COMPILE=aarch64-linux-gnu- make PLAT=hikey DEBUG=1
<br>`FASTBOOT_BUILD_OPTION=$(echo ${BUILD_OPTION} | tr '[A-Z]' '[a-z]')`</br> # Convert DEBUG/RELEASE to debug/release
<br>`cd ${EDK2_DIR}`</br> FASTBOOT_BUILD_OPTION=$(echo ${BUILD_OPTION} | tr '[A-Z]' '[a-z]')
<br>`# Build UEFI & ARM Trust Firmware`</br> cd ${EDK2_DIR}
<br>`${UEFI_TOOLS_DIR}/uefi-build.sh -b ${BUILD_OPTION} -a ../arm-trusted-firmware hikey`</br> # Build UEFI & ARM Trust Firmware
<br>`# Generate l-loader.bin`</br> ${UEFI_TOOLS_DIR}/uefi-build.sh -b ${BUILD_OPTION} -a ../arm-trusted-firmware hikey
<br>`cd ${BUILD_PATH}/l-loader`</br> # Generate l-loader.bin
<br>`ln -sf ${EDK2_OUTPUT_DIR}/FV/bl1.bin`</br> cd ${BUILD_PATH}/l-loader
<br>`ln -sf ${EDK2_OUTPUT_DIR}/FV/fip.bin`</br> ln -sf ${EDK2_OUTPUT_DIR}/FV/bl1.bin
<br>`ln -sf ${BUILD_PATH}/atf-fastboot/build/hikey/${FASTBOOT_BUILD_OPTION}/bl1.bin fastboot.bin`</br> ln -sf ${EDK2_OUTPUT_DIR}/FV/fip.bin
<br>`python gen_loader.py -o l-loader.bin --img_bl1=bl1.bin --img_ns_bl1u=BL33_AP_UEFI.fd`</br> ln -sf ${BUILD_PATH}/atf-fastboot/build/hikey/${FASTBOOT_BUILD_OPTION}/bl1.bin fastboot.bin
<br>`arm-linux-gnueabihf-gcc -c -o start.o start.S`</br> python gen_loader.py -o l-loader.bin --img_bl1=bl1.bin --img_ns_bl1u=BL33_AP_UEFI.fd
<br>`arm-linux-gnueabihf-ld -Bstatic -Tl-loader.lds -Ttext 0xf9800800 start.o -o loader`</br> arm-linux-gnueabihf-gcc -c -o start.o start.S
<br>`arm-linux-gnueabihf-objcopy -O binary loader temp`</br> arm-linux-gnueabihf-ld -Bstatic -Tl-loader.lds -Ttext 0xf9800800 start.o -o loader
<br>`python gen_loader_hikey.py -o l-loader.bin --img_loader=temp --img_bl1=bl1.bin --img_ns_bl1u=fastboot.bin`</br> arm-linux-gnueabihf-objcopy -O binary loader temp
python gen_loader_hikey.py -o l-loader.bin --img_loader=temp --img_bl1=bl1.bin --img_ns_bl1u=fastboot.bin
```
* Generate partition table for aosp. The eMMC capacity is either 4GB or 8GB. Just change "aosp-4g" to "linux-4g" for debian. * Generate partition table for aosp. The eMMC capacity is either 4GB or 8GB. Just change "aosp-4g" to "linux-4g" for debian.
<br>`$PTABLE=aosp-4g SECTOR_SIZE=512 bash -x generate_ptable.sh`</br> ```shell
$PTABLE=aosp-4g SECTOR_SIZE=512 bash -x generate_ptable.sh
```
3. Setup Console 3. Setup Console
---------------- ----------------
* Install ser2net. Use telnet as the console since UEFI fails to display Boot Manager GUI in minicom. __If you don't need Boot Manager GUI, just ignore this section.__ * Install ser2net. Use telnet as the console since UEFI fails to display Boot Manager GUI in minicom. __If you don't need Boot Manager GUI, just ignore this section.__
<br>`$sudo apt-get install ser2net`</br> ```shell
$sudo apt-get install ser2net
```
* Configure ser2net. * Configure ser2net.
<br>`$sudo vi /etc/ser2net.conf`</br> ```shell
<br>Append one line for serial-over-USB in below.</br> $sudo vi /etc/ser2net.conf
<br>_#ser2net.conf_</br> ```
<br>`2004:telnet:0:/dev/ttyUSB0:115200 8DATABITS NONE 1STOPBIT banner`</br>
Append one line for serial-over-USB in below.
_#ser2net.conf_
```shell
2004:telnet:0:/dev/ttyUSB0:115200 8DATABITS NONE 1STOPBIT banner
```
* Open the console. * Open the console.
<br>`$telnet localhost 2004`</br> ```shell
<br>And you could open the console remotely, too.</br> $telnet localhost 2004
```
And you could open the console remotely, too.
4. Flush images in recovery mode 4. Flush images in recovery mode
...@@ -101,18 +119,24 @@ How to build ...@@ -101,18 +119,24 @@ How to build
* Make sure Pin3-Pin4 on J15 are connected for recovery mode. Then power on HiKey. * Make sure Pin3-Pin4 on J15 are connected for recovery mode. Then power on HiKey.
* Remove the modemmanager package. This package may cause the idt tool failure. * Remove the modemmanager package. This package may cause the idt tool failure.
<br>`$sudo apt-get purge modemmanager`</br> ```shell
$sudo apt-get purge modemmanager
```
* Run the command to download l-loader.bin into HiKey. * Run the command to download l-loader.bin into HiKey.
<br>`$sudo python hisi-idt.py -d /dev/ttyUSB1 --img1 l-loader.bin`</br> ```shell
$sudo python hisi-idt.py -d /dev/ttyUSB1 --img1 l-loader.bin
```
* Update images. All aosp or debian images could be fetched from [link](https://builds.96boards.org/). * Update images. All aosp or debian images could be fetched from [link](https://builds.96boards.org/).
<br>`$sudo fastboot flash ptable prm_ptable.img`</br> ```shell
<br>`$sudo fastboot flash fastboot fip.bin`</br> $sudo fastboot flash ptable prm_ptable.img
<br>`$sudo fastboot flash boot boot.img`</br> $sudo fastboot flash fastboot fip.bin
<br>`$sudo fastboot flash cache cache.img`</br> $sudo fastboot flash boot boot.img
<br>`$sudo fastboot flash system system.img`</br> $sudo fastboot flash cache cache.img
<br>`$sudo fastboot flash userdata userdata.img`</br> $sudo fastboot flash system system.img
$sudo fastboot flash userdata userdata.img
```
5. Boot UEFI in normal mode 5. Boot UEFI in normal mode
......
Description Description
==================== ====================
HiKey960 is one of 96boards. Hisilicon Hi3660 processor is installed on HiKey960. HiKey960 is one of 96boards. Hisilicon Hi3660 processor is installed on HiKey960.
More information are listed in [link](http://www.96boards.org/documentation/ConsumerEdition/HiKey960/README.md). More information are listed in [link](http://www.96boards.org/documentation/ConsumerEdition/HiKey960/README.md).
How to build How to build
...@@ -35,36 +35,44 @@ How to build ...@@ -35,36 +35,44 @@ How to build
Make all the repositories in the same ${BUILD_PATH}. Make all the repositories in the same ${BUILD_PATH}.
* Create the symbol link to OpenPlatformPkg in edk2. * Create the symbol link to OpenPlatformPkg in edk2.
<br>`$cd ${BUILD_PATH}/edk2`</br> ```shell
<br>`$ln -sf ../OpenPlatformPkg`</br> $cd ${BUILD_PATH}/edk2
$ln -sf ../OpenPlatformPkg
```
* Prepare AARCH64 toolchain. * Prepare AARCH64 toolchain.
* If your hikey960 hardware is v1, update _uefi-tools/platform.config_ first. _(optional)_ * If your hikey960 hardware is v1, update _uefi-tools/platform.config_ first. _(optional)_
<br>__Uncomment the below sentence. Otherwise, UEFI can't output messages on serial __Uncomment the below sentence. Otherwise, UEFI can't output messages on serial
console on hikey960 v1.__</br> console on hikey960 v1.__
<br>`BUILDFLAGS=-DSERIAL_BASE=0xFDF05000`</br> ```shell
<br>If your hikey960 hardware is v2 or newer, nothing to do.</br> BUILDFLAGS=-DSERIAL_BASE=0xFDF05000
```
If your hikey960 hardware is v2 or newer, nothing to do.
* Build it as debug mode. Create script file for build. * Build it as debug mode. Create script file for build.
<br>`BUILD_OPTION=DEBUG`</br> ```shell
<br>`export AARCH64_TOOLCHAIN=GCC48`</br> BUILD_OPTION=DEBUG
<br>`export UEFI_TOOLS_DIR=${BUILD_PATH}/uefi-tools`<br> export AARCH64_TOOLCHAIN=GCC48
<br>`export EDK2_DIR=${BUILD_PATH}/edk2`</br> export UEFI_TOOLS_DIR=${BUILD_PATH}/uefi-tools
<br>`EDK2_OUTPUT_DIR=${EDK2_DIR}/Build/HiKey960/${BUILD_OPTION}_${AARCH64_TOOLCHAIN}`</br> export EDK2_DIR=${BUILD_PATH}/edk2
<br>`cd ${EDK2_DIR}`</br> EDK2_OUTPUT_DIR=${EDK2_DIR}/Build/HiKey960/${BUILD_OPTION}_${AARCH64_TOOLCHAIN}
<br>`# Build UEFI & ARM Trust Firmware`</br> cd ${EDK2_DIR}
<br>`${UEFI_TOOLS_DIR}/uefi-build.sh -b ${BUILD_OPTION} -a ../arm-trusted-firmware hikey960`</br> # Build UEFI & ARM Trust Firmware
<br>`# Generate l-loader.bin`</br> ${UEFI_TOOLS_DIR}/uefi-build.sh -b ${BUILD_OPTION} -a ../arm-trusted-firmware hikey960
<br>`cd ${BUILD_PATH}/l-loader`</br> # Generate l-loader.bin
<br>`ln -sf ${EDK2_OUTPUT_DIR}/FV/bl1.bin`</br> cd ${BUILD_PATH}/l-loader
<br>`ln -sf ${EDK2_OUTPUT_DIR}/FV/fip.bin`</br> ln -sf ${EDK2_OUTPUT_DIR}/FV/bl1.bin
<br>`ln -sf ${EDK2_OUTPUT_DIR}/FV/BL33_AP_UEFI.fd`</br> ln -sf ${EDK2_OUTPUT_DIR}/FV/fip.bin
<br>`python gen_loader.py -o l-loader.bin --img_bl1=bl1.bin --img_ns_bl1u=BL33_AP_UEFI.fd`</br> ln -sf ${EDK2_OUTPUT_DIR}/FV/BL33_AP_UEFI.fd
python gen_loader.py -o l-loader.bin --img_bl1=bl1.bin --img_ns_bl1u=BL33_AP_UEFI.fd
```
* Generate partition table. * Generate partition table.
<br>_Make sure that you're using the sgdisk in the l-loader directory._</br> _Make sure that you're using the sgdisk in the l-loader directory._
<br>`$PTABLE=aosp-32g SECTOR_SIZE=4096 SGDISK=./sgdisk bash -x generate_ptable.sh`</br> ```shell
$PTABLE=aosp-32g SECTOR_SIZE=4096 SGDISK=./sgdisk bash -x generate_ptable.sh
```
3. Setup Console 3. Setup Console
...@@ -72,17 +80,24 @@ How to build ...@@ -72,17 +80,24 @@ How to build
* Install ser2net. Use telnet as the console since UEFI will output window * Install ser2net. Use telnet as the console since UEFI will output window
that fails to display in minicom. that fails to display in minicom.
<br>`$sudo apt-get install ser2net`</br> ```shell
$sudo apt-get install ser2net
```
* Configure ser2net. * Configure ser2net.
<br>`$sudo vi /etc/ser2net.conf`</br> ```shell
<br>Append one line for serial-over-USB in below.</br> $sudo vi /etc/ser2net.conf
<br>_#ser2net.conf_</br> ```
<br>`2004:telnet:0:/dev/ttyUSB0:115200 8DATABITS NONE 1STOPBIT banner`</br> Append one line for serial-over-USB in _#ser2net.conf_
```
2004:telnet:0:/dev/ttyUSB0:115200 8DATABITS NONE 1STOPBIT banner
```
* Open the console. * Open the console.
<br>`$telnet localhost 2004`</br> ```shell
<br>And you could open the console remotely, too.</br> $telnet localhost 2004
```
And you could open the console remotely, too.
4. Boot UEFI in recovery mode 4. Boot UEFI in recovery mode
...@@ -92,35 +107,45 @@ How to build ...@@ -92,35 +107,45 @@ How to build
[link](https://github.com/96boards-hikey/tools-images-hikey960) [link](https://github.com/96boards-hikey/tools-images-hikey960)
* Generate l-loader.bin. * Generate l-loader.bin.
<br>`$cd tools-images-hikey960`</br> ```shell
<br>`$ln -sf ${BUILD_PATH}/l-loader/l-loader.bin`</br> $cd tools-images-hikey960
$ln -sf ${BUILD_PATH}/l-loader/l-loader.bin
```
* Prepare config file. * Prepare config file.
<br>_$vi config_</br> ```shell
<br>_# The content of config file_</br> $vi config
<br>`./sec_user_xloader.img 0x00020000`</br> # The content of config file
<br>`./sec_uce_boot.img 0x6A908000`</br> ./sec_user_xloader.img 0x00020000
<br>`./l-loader.bin 0x1AC00000`</br> ./sec_uce_boot.img 0x6A908000
./l-loader.bin 0x1AC00000
```
* Remove the modemmanager package. This package may causes hikey_idt tool failure. * Remove the modemmanager package. This package may causes hikey_idt tool failure.
<br>`$sudo apt-get purge modemmanager`</br> ```shell
$sudo apt-get purge modemmanager
```
* Run the command to download l-loader.bin into HiKey960. * Run the command to download l-loader.bin into HiKey960.
<br>`$sudo ./hikey_idt -c config -p /dev/ttyUSB1`</br> ```shell
$sudo ./hikey_idt -c config -p /dev/ttyUSB1
```
* UEFI running in recovery mode. * UEFI running in recovery mode.
<br>When prompt '.' is displayed on console, press hotkey 'f' in keyboard. Then Android fastboot app is running.</br> When prompt '.' is displayed on console, press hotkey 'f' in keyboard. Then Android fastboot app is running.
<br>The timeout of prompt '.' is 10 seconds.</br> The timeout of prompt '.' is 10 seconds.
* Update images. * Update images.
<br>`$sudo fastboot flash ptable prm_ptable.img`</br> ```shell
<br>`$sudo fastboot flash xloader sec_xloader.img`</br> $sudo fastboot flash ptable prm_ptable.img
<br>`$sudo fastboot flash fastboot l-loader.bin`</br> $sudo fastboot flash xloader sec_xloader.img
<br>`$sudo fastboot flash fip fip.bin`</br> $sudo fastboot flash fastboot l-loader.bin
<br>`$sudo fastboot flash boot boot.img`</br> $sudo fastboot flash fip fip.bin
<br>`$sudo fastboot flash cache cache.img`</br> $sudo fastboot flash boot boot.img
<br>`$sudo fastboot flash system system.img`</br> $sudo fastboot flash cache cache.img
<br>`$sudo fastboot flash userdata userdata.img`</br> $sudo fastboot flash system system.img
$sudo fastboot flash userdata userdata.img
```
* Notice: UEFI could also boot kernel in recovery mode, but BL31 isn't loaded in * Notice: UEFI could also boot kernel in recovery mode, but BL31 isn't loaded in
recovery mode. recovery mode.
......
...@@ -56,10 +56,12 @@ without changing any makefiles. ...@@ -56,10 +56,12 @@ without changing any makefiles.
Preparing the BL31 image to run on Tegra SoCs Preparing the BL31 image to run on Tegra SoCs
=================================================== ===================================================
'CROSS_COMPILE=<path-to-aarch64-gcc>/bin/aarch64-none-elf- make PLAT=tegra \ ```shell
TARGET_SOC=<target-soc e.g. t210|t132> SPD=<dispatcher e.g. tlkd> bl31' CROSS_COMPILE=<path-to-aarch64-gcc>/bin/aarch64-none-elf- make PLAT=tegra \
TARGET_SOC=<target-soc e.g. t210|t132> SPD=<dispatcher e.g. tlkd> bl31
```
Platforms wanting to use different TZDRAM_BASE, can add 'TZDRAM_BASE=<value>' Platforms wanting to use different TZDRAM_BASE, can add `TZDRAM_BASE=<value>`
to the build command line. to the build command line.
The Tegra platform code expects a pointer to the following platform specific The Tegra platform code expects a pointer to the following platform specific
......
...@@ -2,7 +2,6 @@ PSCI Library Integration guide for ARMv8-A AArch32 systems ...@@ -2,7 +2,6 @@ PSCI Library Integration guide for ARMv8-A AArch32 systems
========================================================== ==========================================================
Contents Contents
--------
1. [Introduction](#1-introduction) 1. [Introduction](#1-introduction)
2. [Generic call sequence for PSCI Library interface (AArch32)](#2-generic-call-sequence-for-psci-library-interface-aarch32) 2. [Generic call sequence for PSCI Library interface (AArch32)](#2-generic-call-sequence-for-psci-library-interface-aarch32)
...@@ -31,8 +30,8 @@ with EL3 Runtime Software in this document is targeted towards AArch32 systems. ...@@ -31,8 +30,8 @@ with EL3 Runtime Software in this document is targeted towards AArch32 systems.
2. Generic call sequence for PSCI Library interface (AArch32) 2. Generic call sequence for PSCI Library interface (AArch32)
------------------------------------------------------------- -------------------------------------------------------------
The generic call sequence of PSCI Library interfaces The generic call sequence of PSCI Library interfaces (see
[(see section 4)](#4-psci-library-interface) during cold boot in AArch32 [section 4](#4-psci-library-interface)) during cold boot in AArch32
system is described below: system is described below:
1. After cold reset, the EL3 Runtime Software performs its cold boot 1. After cold reset, the EL3 Runtime Software performs its cold boot
......
PSCI Library Integration guide for ARMv8-A AArch32 systems
==========================================================
Contents
--------
1. [Requirements](#requirements)
2. [Design](#design)
------------ ------------
Requirements Requirements
------------ ------------
...@@ -293,3 +302,7 @@ Each core can find its node in the `psci_cpu_pd_nodes` array using the ...@@ -293,3 +302,7 @@ Each core can find its node in the `psci_cpu_pd_nodes` array using the
provides an MPIDR. The `plat_core_pos_by_mpidr()` function is used to validate provides an MPIDR. The `plat_core_pos_by_mpidr()` function is used to validate
the MPIDR before using it to find the corresponding core node. The non-core power the MPIDR before using it to find the corresponding core node. The non-core power
domain nodes do not need to be identified. domain nodes do not need to be identified.
- - - - - - - - - - - - - - - - - - - - - - - - - -
_Copyright (c) 2017, ARM Limited and Contributors. All rights reserved._
...@@ -3,11 +3,11 @@ OP-TEE Dispatcher ...@@ -3,11 +3,11 @@ OP-TEE Dispatcher
[OP-TEE OS] is a Trusted OS running as Secure EL1. [OP-TEE OS] is a Trusted OS running as Secure EL1.
To build and execute [OP-TEE OS] follow the instructions at To build and execute OP-TEE follow the instructions at
[ARM Trusted Firmware with OP-TEE] [OP-TEE OS] [OP-TEE build.git][OP-TEE OS]
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
_Copyright (c) 2014, ARM Limited and Contributors. All rights reserved._ _Copyright (c) 2014-2017, ARM Limited and Contributors. All rights reserved._
[OP-TEE OS]: http://github.com/OP-TEE/optee_os/tree/master/documentation/arm_trusted_firmware.md [OP-TEE OS]: https://github.com/OP-TEE/build
...@@ -143,7 +143,7 @@ Download the Trusted Firmware source code from Github: ...@@ -143,7 +143,7 @@ Download the Trusted Firmware source code from Github:
Notes: Notes:
* If `PLAT` is not specified, `fvp` is assumed by default. See the * If `PLAT` is not specified, `fvp` is assumed by default. See the
"Summary of build options" for more information on available build [Summary of build options](#summary-of-build-options) for more information on available build
options. options.
* (AArch32 only) Currently only `PLAT=fvp` is supported. * (AArch32 only) Currently only `PLAT=fvp` is supported.
...@@ -157,8 +157,8 @@ Download the Trusted Firmware source code from Github: ...@@ -157,8 +157,8 @@ Download the Trusted Firmware source code from Github:
EL3 Runtime Software can be found [here][PSCI Lib Integration]. EL3 Runtime Software can be found [here][PSCI Lib Integration].
* (AArch64 only) The TSP (Test Secure Payload), corresponding to the BL32 * (AArch64 only) The TSP (Test Secure Payload), corresponding to the BL32
image, is not compiled in by default. Refer to the "Building the Test image, is not compiled in by default. Refer to the [Building the Test
Secure Payload" section below. Secure Payload](#building-the-test-secure-payload) section below.
* By default this produces a release version of the build. To produce a * By default this produces a release version of the build. To produce a
debug version instead, refer to the "Debugging options" section below. debug version instead, refer to the "Debugging options" section below.
...@@ -213,7 +213,7 @@ performed. ...@@ -213,7 +213,7 @@ performed.
* `ARM_ARCH_MAJOR`: The major version of ARM Architecture to target when * `ARM_ARCH_MAJOR`: The major version of ARM Architecture to target when
compiling ARM Trusted Firmware. Its value must be numeric, and defaults to compiling ARM Trusted Firmware. Its value must be numeric, and defaults to
8. See also, _ARMv8 Architecture Extensions_ in [Firmware Design]. 8 . See also, _ARMv8 Architecture Extensions_ in [Firmware Design].
* `ARM_ARCH_MINOR`: The minor version of ARM Architecture to target when * `ARM_ARCH_MINOR`: The minor version of ARM Architecture to target when
compiling ARM Trusted Firmware. Its value must be a numeric, and defaults compiling ARM Trusted Firmware. Its value must be a numeric, and defaults
...@@ -575,9 +575,9 @@ performed. ...@@ -575,9 +575,9 @@ performed.
optimise memory usage need to set this flag to 1 and must override the optimise memory usage need to set this flag to 1 and must override the
related macros. related macros.
* `ARM_CONFIG_CNTACR`: boolean option to unlock access to the CNTBase<N> * `ARM_CONFIG_CNTACR`: boolean option to unlock access to the `CNTBase<N>`
frame registers by setting the CNTCTLBase.CNTACR<N> register bits. The frame registers by setting the `CNTCTLBase.CNTACR<N>` register bits. The
frame number <N> is defined by `PLAT_ARM_NSTIMER_FRAME_ID`, which should frame number `<N>` is defined by `PLAT_ARM_NSTIMER_FRAME_ID`, which should
match the frame used by the Non-Secure image (normally the Linux kernel). match the frame used by the Non-Secure image (normally the Linux kernel).
Default is true (access to the frame is allowed). Default is true (access to the frame is allowed).
...@@ -730,7 +730,7 @@ commands can be used: ...@@ -730,7 +730,7 @@ commands can be used:
The TSP is coupled with a companion runtime service in the BL31 firmware, The TSP is coupled with a companion runtime service in the BL31 firmware,
called the TSPD. Therefore, if you intend to use the TSP, the BL31 image called the TSPD. Therefore, if you intend to use the TSP, the BL31 image
must be recompiled as well. For more information on SPs and SPDs, see the must be recompiled as well. For more information on SPs and SPDs, see the
"Secure-EL1 Payloads and Dispatchers" section in the [Firmware Design]. [Secure-EL1 Payloads and Dispatchers](firmware-design.rst#secure-el1-payloads-and-dispatchers) section in the [Firmware Design].
First clean the Trusted Firmware build directory to get rid of any previous First clean the Trusted Firmware build directory to get rid of any previous
BL31 binary. Then to build the TSP image use: BL31 binary. Then to build the TSP image use:
...@@ -848,8 +848,7 @@ remove operations will automatically overwrite it. ...@@ -848,8 +848,7 @@ remove operations will automatically overwrite it.
The unpack operation will fail if the images already exist at the The unpack operation will fail if the images already exist at the
destination. In that case, use -f or --force to continue. destination. In that case, use -f or --force to continue.
More information about FIP can be found in the [Firmware Design document] More information about FIP can be found in the [Firmware Design] document.
[Firmware Design].
#### Migrating from fip_create to fiptool #### Migrating from fip_create to fiptool
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment