Skip to content

Commit 3ad0946

Browse files
JordanYatesjhedberg
authored andcommitted
doc: tfm: document output files
Document the useful output files that exist, which files they are constructed from, and what they can be used for. Update other sections that are no longer correct with changes. Signed-off-by: Jordan Yates <jordan@embeint.com>
1 parent 74a23ea commit 3ad0946

File tree

1 file changed

+16
-8
lines changed

1 file changed

+16
-8
lines changed

doc/services/tfm/build.rst

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,6 @@ When :kconfig:option:`CONFIG_TFM_BL2` is set to ``y``, TF-M uses a secure bootlo
6161
is validated by the bootloader during updates using the corresponding public
6262
key, which is stored inside the secure bootloader firmware image.
6363

64-
During the signing procedure, all HEX files are marked as ``confirmed``,
65-
whereas all BIN files remain ``unconfirmed``. This guarantees that any image
66-
flashed into a device possesses the required properties for compatibility
67-
with the `PSA Certified Firmware Update API`_. The corresponding BIN file
68-
can then be used as the payload in the Firmware Update procedure.
69-
7064
By default, ``<tfm-dir>/bl2/ext/mcuboot/root-rsa-3072.pem`` is used to sign secure
7165
images, and ``<tfm-dir>/bl2/ext/mcuboot/root-rsa-3072_1.pem`` is used to sign
7266
non-secure images. These default .pem keys can (and **should**) be overridden
@@ -95,14 +89,28 @@ flags.
9589
and it will no longer be possible to update your devices in the field!
9690

9791
After the built-in signing script has run, it creates a ``tfm_merged.hex``
98-
file that contains all three binaries: bl2, tfm_s, and the zephyr app. This
99-
hex file can then be flashed to your development board or run in QEMU.
92+
(and ``tfm_merged.bin``) file that contains all three binaries: bl2, tfm_s,
93+
and the zephyr app. These files can then be flashed to your development board
94+
or run in QEMU.
10095

10196
.. _PSA Certified Level 1:
10297
https://www.psacertified.org/security-certification/psa-certified-level-1/
10398
.. _PSA Certified Firmware Update API:
10499
https://arm-software.github.io/psa-api/fwu/
105100

101+
Output Files
102+
************
103+
104+
Upon completion of the Zephyr TF-M build, the following output files exist:
105+
106+
.. csv-table:: TF-M Output Files
107+
:header: Filename, Created From, Bootloader Flags, Usage
108+
109+
``tfm_s_signed.{hex/bin}``, "TF-M Secure", Signed, OTA Upgrades (:kconfig:option:`CONFIG_TFM_MCUBOOT_IMAGE_NUMBER` == 2)
110+
``zephyr_ns_signed.{hex/bin}``, "Zephyr Nonsecure", Signed, OTA Upgrades (:kconfig:option:`CONFIG_TFM_MCUBOOT_IMAGE_NUMBER` == 2)
111+
``tfm_s_zephyr_ns_signed.{hex/bin}``, "TF-M Secure, Zephyr Nonsecure", Signed, OTA Upgrades (:kconfig:option:`CONFIG_TFM_MCUBOOT_IMAGE_NUMBER` == 1)
112+
``tfm_merged.{hex/bin}``, "Bootloader, TF-M Secure, Zephyr Nonsecure", "Signed, Confirmed", "Production Programming, flashed by ``west flash``"
113+
106114
Custom CMake arguments
107115
======================
108116

0 commit comments

Comments
 (0)