blob: fcb0bb8f3592b67154bf637e2e9977f3839106ef [file] [log] [blame]
Jimmy Brissonff08d3e2020-04-02 15:19:27 -05001Running Tests
2=============
Jimmy Brisson0862f012020-04-02 15:19:12 -05003
4Refer to the sections `Running the software on FVP`_ and `Running the software
5on Juno`_ in `TF-A User Guide`_. The same instructions mostly apply to run the
6TF-A Tests on those 2 platforms. The difference is that the following images are
7not needed here:
8
9- Normal World bootloader. The TFTF replaces it in the boot flow;
10
11- Linux Kernel;
12
13- Device tree;
14
15- Filesystem.
16
17In other words, only the following software images are needed:
18
19- ``BL1`` firmware image;
20
21- ``FIP`` image containing the following images:
22
23 - ``BL2``;
24 - ``SCP_BL2`` if required by the platform (e.g. Juno);
25 - ``BL31``;
26 - ``BL32`` (optional);
27 - ``tftf.bin`` (standing as the BL33 image).
28
Jimmy Brissonff08d3e2020-04-02 15:19:27 -050029Running Manual Tests on FVP
30---------------------------
31
Jimmy Brisson0862f012020-04-02 15:19:12 -050032The manual tests rely on storing state in non-volatile memory (NVM) across
33reboot. On FVP the NVM is not persistent across reboots, so the following
34flag must be used to write the NVM to a file when the model exits.
35
36::
37
38 -C bp.flashloader0.fnameWrite=[filename]
39
40To ensure the model exits on shutdown the following flag must be used:
41
42::
43
44 -C bp.ve_sysregs.exit_on_shutdown=1
45
46After the model has been shutdown, this file must be fed back in to continue
47the test. Note this flash file includes the FIP image, so the original fip.bin
48does not need to be passed in. The following flag is used:
49
50::
51
52 -C bp.flashloader0.fname=[filename]
53
Jimmy Brissonff08d3e2020-04-02 15:19:27 -050054Running Firmware Update (FWU) Tests
55-----------------------------------
Jimmy Brisson0862f012020-04-02 15:19:12 -050056
57As previously mentioned in section `Putting it all together`_, there are a
58couple of extra images involved when running the FWU tests. They need to be
59loaded at the right addresses, which depend on the platform.
60
Jimmy Brissonff08d3e2020-04-02 15:19:27 -050061On FVP
62^^^^^^
Jimmy Brisson0862f012020-04-02 15:19:12 -050063
64In addition to the usual BL1 and FIP images, the following extra images must be
65loaded:
66
67- ``NS_BL1U`` image at address ``0x0BEB8000`` (i.e. NS_BL1U_BASE macro in TF-A)
68- ``FWU_FIP`` image at address ``0x08400000`` (i.e. NS_BL2U_BASE macro in TF-A)
69- ``Backup FIP`` image at address ``0x09000000`` (i.e. FIP_BKP_ADDRESS macro in
70 TF-A tests).
71
72An example script is provided in `scripts/run_fwu_fvp.sh`_.
73
Jimmy Brissonff08d3e2020-04-02 15:19:27 -050074On Juno
75^^^^^^^
Jimmy Brisson0862f012020-04-02 15:19:12 -050076
77The same set of extra images and load addresses apply for Juno as for FVP.
78
79The new images must be programmed in flash memory by adding some entries in the
80``SITE1/HBI0262x/images.txt`` configuration file on the Juno SD card (where
81``x`` depends on the revision of the Juno board). Refer to the `Juno Getting
82Started Guide`_, section 2.3 "Flash memory programming" for more
83information. Users should ensure these do not overlap with any other entries in
84the file.
85
86Addresses in this file are expressed as an offset from the base address of the
87flash (that is, ``0x08000000``).
88
89::
90
91 NOR10UPDATE: AUTO ; Image Update:NONE/AUTO/FORCE
92 NOR10ADDRESS: 0x00400000 ; Image Flash Address
93 NOR10FILE: \SOFTWARE\fwu_fip.bin ; Image File Name
94 NOR10LOAD: 00000000 ; Image Load Address
95 NOR10ENTRY: 00000000 ; Image Entry Point
96
97 NOR11UPDATE: AUTO ; Image Update:NONE/AUTO/FORCE
98 NOR11ADDRESS: 0x03EB8000 ; Image Flash Address
99 NOR11FILE: \SOFTWARE\ns_bl1u.bin ; Image File Name
100 NOR11LOAD: 00000000 ; Image Load Address
101 NOR11ENTRY: 00000000 ; Image Load Address
102
103 NOR12UPDATE: AUTO ; Image Update:NONE/AUTO/FORCE
104 NOR12ADDRESS: 0x01000000 ; Image Flash Address
105 NOR12FILE: \SOFTWARE\backup_fip.bin ; Image File Name
106 NOR12LOAD: 00000000 ; Image Load Address
107 NOR12ENTRY: 00000000 ; Image Entry Point
108
109--------------
110
111*Copyright (c) 2019, Arm Limited. All rights reserved.*
112
113.. _scripts/run_fwu_fvp.sh: ../scripts/run_fwu_fvp.sh
114.. _Juno Getting Started Guide: http://infocenter.arm.com/help/topic/com.arm.doc.dui0928e/DUI0928E_juno_arm_development_platform_gsg.pdf
115.. _Running the software on FVP: https://git.trustedfirmware.org/TF-A/trusted-firmware-a.git/about/docs/user-guide.rst#running-the-software-on-fvp
116.. _Running the software on Juno: https://git.trustedfirmware.org/TF-A/trusted-firmware-a.git/about/docs/user-guide.rst#running-the-software-on-juno