Skip to content

Commit

Permalink
doc: Fix renamed ARM MPS* board targets
Browse files Browse the repository at this point in the history
Fixes some board target names that have changed or were not
updated for hwmv2

Signed-off-by: Jamie McCrae <[email protected]>
  • Loading branch information
nordicjm committed Nov 7, 2024
1 parent c3466b1 commit 48e4481
Show file tree
Hide file tree
Showing 6 changed files with 44 additions and 45 deletions.
6 changes: 3 additions & 3 deletions doc/build/sysbuild/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -499,16 +499,16 @@ In sysbuild and Zephyr CMake build system a board may refer to:
* A specific SoC on a physical board with multiple SoCs, such as
:ref:`nrf9160dk_nrf9160` and :ref:`nrf9160dk_nrf52840`.

If your main application, for example, is built for ``mps2_an521``, and your
helper application must target the ``mps2_an521_remote`` board (cpu1), add
If your main application, for example, is built for ``mps2/an521/cpu0``, and your
helper application must target the ``mps2/an521/cpu1`` board target, add
a CMake function call that is structured as follows:

.. code-block:: cmake
ExternalZephyrProject_Add(
APPLICATION my_sample
SOURCE_DIR <path-to>/my_sample
BOARD mps2_an521_remote
BOARD mps2/an521/cpu1
)
This could be useful, for example, if your main application requires another
Expand Down
46 changes: 23 additions & 23 deletions doc/hardware/arch/arm_cortex_m.rst
Original file line number Diff line number Diff line change
Expand Up @@ -651,29 +651,29 @@ The table below lists the QEMU platform targets defined in Zephyr
along with the corresponding Cortex-M implementation variant and the peripherals
these targets emulate.

+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| | **QEMU target** |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| Architecture variant | Arm v6-M | Arm v7-M | Arm v8-M | Arm v8.1-M |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| | **qemu_cortex_m0** | **qemu_cortex_m3** | **mps2_an385** | **mps2_an521** | **mps3_an547** |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| **Emulated features** | |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| NVIC | Y | Y | Y | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| BASEPRI | N | Y | Y | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| SysTick | N | Y | Y | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| MPU | N | N | Y | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| FPU | N | N | N | Y | N |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| SPLIM | N | N | N | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
| TrustZone-M | N | N | N | Y | N |
+---------------------------------+--------------------+--------------------+----------------+-----------------+----------------+
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| | **QEMU target** |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| Architecture variant | Arm v6-M | Arm v7-M | Arm v8-M | Arm v8.1-M |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| | **qemu_cortex_m0** | **qemu_cortex_m3** | **mps2/an385** | **mps2/an521/cpu0** | **mps3/corstone300/an547** |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| **Emulated features** | |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| NVIC | Y | Y | Y | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| BASEPRI | N | Y | Y | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| SysTick | N | Y | Y | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| MPU | N | N | Y | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| FPU | N | N | N | Y | N |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| SPLIM | N | N | N | Y | Y |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+
| TrustZone-M | N | N | N | Y | N |
+---------------------------------+--------------------+--------------------+----------------+----------------------+----------------------------+

Maintainers & Collaborators
***************************
Expand Down
10 changes: 5 additions & 5 deletions doc/services/tfm/build.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ steps required:

.. code-block:: bash
$ west build -p auto -b mps2_an521_ns samples/tfm_integration/psa_protected_storage/ -t run
$ west build -p auto -b mps2/an521/cpu0/ns samples/tfm_integration/psa_protected_storage/ -t run
The outputs and certain key steps in this build process are described here,
however, since you will need to understand and interact with the outputs, and
Expand Down Expand Up @@ -146,29 +146,29 @@ Use the ``tfm_ram_report`` to get the RAM report for TF-M secure firmware (tfm_s
.. zephyr-app-commands::
:tool: all
:zephyr-app: samples/hello_world
:board: mps2_an521_ns
:board: mps2/an521/cpu0/ns
:goals: tfm_ram_report

Use the ``tfm_rom_report`` to get the ROM report for TF-M secure firmware (tfm_s).

.. zephyr-app-commands::
:tool: all
:zephyr-app: samples/hello_world
:board: mps2_an521_ns
:board: mps2/an521/cpu0/ns
:goals: tfm_rom_report

Use the ``bl2_ram_report`` to get the RAM report for TF-M MCUboot, if enabled.

.. zephyr-app-commands::
:tool: all
:zephyr-app: samples/hello_world
:board: mps2_an521_ns
:board: mps2/an521/cpu0/ns
:goals: bl2_ram_report

Use the ``bl2_rom_report`` to get the ROM report for TF-M MCUboot, if enabled.

.. zephyr-app-commands::
:tool: all
:zephyr-app: samples/hello_world
:board: mps2_an521_ns
:board: mps2/an521/cpu0/ns
:goals: bl2_rom_report
14 changes: 7 additions & 7 deletions doc/services/tfm/integration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,22 +23,22 @@ processing environment. :kconfig:option:`CONFIG_TFM_BOARD` must also be set via
to the board name that TF-M expects for this target, so that it knows which
target to build for the secure processing environment.

Example: ``mps2_an521_ns``
==========================
Example: ``mps2/an521/cpu0/ns``
===============================

The ``mps2_an521`` target is a dual-core Arm Cortex-M33 evaluation board that,
when using the default board variant, would generate a secure Zephyr binary.
The ``mps2/an521/cpu0`` board target is a dual-core Arm Cortex-M33 evaluation board that generates
a secure Zephyr binary.

The optional ``mps2_an521_ns`` target, however, sets these additional
The optional ``mps2/an521/cpu0/ns`` board target, however, sets these additional
kconfig flags that indicate that Zephyr should be built as a
non-secure image, linked with TF-M as an external project, and optionally the
secure bootloader:

* :kconfig:option:`CONFIG_TRUSTED_EXECUTION_NONSECURE` ``y``
* :kconfig:option:`CONFIG_ARM_TRUSTZONE_M` ``y``

Comparing the ``mps2_an521.dts`` and ``mps2_an521_ns.dts`` files, we can see
that the ``_ns`` version defines offsets in flash and SRAM memory, which leave
Comparing the :zephyr_file:`mps2_an521_cpu0.dts` and :zephyr_file:`mps2_an521_cpu0_ns.dts` files,
we can see that the ``ns`` version defines offsets in flash and SRAM memory, which leave
the required space for TF-M and the secure bootloader:

::
Expand Down
4 changes: 2 additions & 2 deletions doc/services/tfm/overview.rst
Original file line number Diff line number Diff line change
Expand Up @@ -261,8 +261,8 @@ Non-Secure Processing Environment
Zephyr is used for the NSPE, using a board that is supported by TF-M where the
:kconfig:option:`CONFIG_BUILD_WITH_TFM` flag has been enabled.

Generally, you simply need to select the ``*_ns`` variant of a valid target
(for example ``mps2_an521_ns``), which will configure your Zephyr application
Generally, you simply need to select the ``*/ns`` board target of a valid board
(for example ``mps2/an521/cpu0/ns``), which will configure your Zephyr application
to run in the NSPE, correctly build and link it with the TF-M secure images,
sign the secure and non-secure images, and merge the three binaries into a
single ``tfm_merged.hex`` file. The :ref:`west flash <west-flashing>` command
Expand Down
9 changes: 4 additions & 5 deletions doc/services/tfm/requirements.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ The following are some of the boards that can be used with TF-M:
* - Board
- NSPE board name
* - :ref:`mps2_an521_board`
- ``mps2_an521_ns`` (qemu supported)
- ``mps2/an521/cpu0/ns`` (qemu supported)
* - :ref:`mps3_board`
- ``mps3/corstone300/an547/ns`` (qemu supported)
* - :zephyr:board:`bl5340_dvk`
Expand All @@ -27,12 +27,11 @@ The following are some of the boards that can be used with TF-M:
* - :zephyr:board:`stm32l562e_dk`
- ``stm32l562e_dk/stm32l562xx/ns``
* - :ref:`v2m_musca_b1_board`
- ``v2m_musca_b1_ns``
- ``v2m_musca_b1/musca_b1/ns``
* - :ref:`v2m_musca_s1_board`
- ``v2m_musca_s1_ns``
- ``v2m_musca_s1/musca_s1/ns``

You can run ``west boards -n _ns$`` to search for non-secure variants
of different board targets. To make sure TF-M is supported for a board
To make sure TF-M is supported for a board
in its output, check that :kconfig:option:`CONFIG_TRUSTED_EXECUTION_NONSECURE`
is set to ``y`` in that board's default configuration.

Expand Down

0 comments on commit 48e4481

Please sign in to comment.