From 0a580b6e151ea1d18c58c3da14a15aade42c8684 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20B=C3=B8e?= Date: Mon, 16 Oct 2023 12:30:14 +0200 Subject: [PATCH] tfm: Kconfig: Enable TF-M logging by default also with minimal conf MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 --- .../releases/release-notes-changelog.rst | 5 ++++- modules/trusted-firmware-m/Kconfig | 1 - 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst b/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst index 0cd43b8d0b02..f7339ff73aaf 100644 --- a/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst +++ b/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst @@ -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 ===== diff --git a/modules/trusted-firmware-m/Kconfig b/modules/trusted-firmware-m/Kconfig index 598eeaa07faa..e8e4b7202aa4 100644 --- a/modules/trusted-firmware-m/Kconfig +++ b/modules/trusted-firmware-m/Kconfig @@ -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