Skip to content

Commit

Permalink
tfm: Kconfig: Enable TF-M logging by default also with minimal conf
Browse files Browse the repository at this point in the history
Stop enabling TFM_LOG_LEVEL_SILENCE from the TFM_PROFILE_TYPE_MINIMAL
option.

Without logging it becomes more difficult to debug failures, both in
the non-secure image (secure faults), and in TF-M.

I assume we disabled logging at some point due to the 32kB resource
usage limit. But my testing shows that we have space for this now,
presumably due to some optimization work that we have done.

NB: TF-M will usually use the UART1 instance. If this conflicts with
another user of UART1 then they either must be configured to use
different UART instances, or TF-M could be configured to share UART0
with the application (CONFIG_TFM_SECURE_UART0), or logging from TF-M
must be disabled.

Signed-off-by: Sebastian Bøe <[email protected]>
  • Loading branch information
SebastianBoe authored and rlubos committed Nov 6, 2023
1 parent d2f3df0 commit 0a580b6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,10 @@ zcbor
Trusted Firmware-M
==================

|no_changes_yet_note|
* The minimal TF-M build profile no longer silences TF-M logs by default.

.. note::
This can be a breaking change if the UART instance used by TF-M is already in use, for example by modem trace with a UART backend.

cJSON
=====
Expand Down
1 change: 0 additions & 1 deletion modules/trusted-firmware-m/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ choice TFM_PROFILE_TYPE
config TFM_PROFILE_TYPE_MINIMAL
bool "Use minimal TF-M build"
select PSA_DEFAULT_OFF
imply TFM_LOG_LEVEL_SILENCE
help
Use minimal TF-M build. This will make the TF-M image fit within 32kB.
No configuration of the size of the partition nor the features of the
Expand Down

0 comments on commit 0a580b6

Please sign in to comment.