From fe6e5f37073b71dff082461b6c3486e698c3fc6d Mon Sep 17 00:00:00 2001 From: Nordic Builder Date: Thu, 4 Dec 2025 14:31:51 +0000 Subject: [PATCH 1/2] manifest: Update sdk-zephyr revision (auto-manifest PR) Automatically created by action-manifest-pr GH action from PR: https://github.com/nrfconnect/sdk-zephyr/pull/3606 Signed-off-by: Nordic Builder --- west.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/west.yml b/west.yml index d82f31baec2..81f5188f007 100644 --- a/west.yml +++ b/west.yml @@ -64,7 +64,7 @@ manifest: # https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/guides/modules.html - name: zephyr repo-path: sdk-zephyr - revision: ceabc540fed74d3e1969b78f92dc0fbd7e815a3e + revision: pull/3606/head import: # In addition to the zephyr repository itself, NCS also # imports the contents of zephyr/west.yml at the above From 22d102230fd4eefc0b97f14f8c4c47f4d9207775 Mon Sep 17 00:00:00 2001 From: Kyra Lengfeld Date: Mon, 8 Dec 2025 14:09:17 +0100 Subject: [PATCH 2/2] Konfig.nrf: Bluetooth Add SOC dependent BT_TX_PROCESSOR_STACK_SIZE Values were derived from Thread Analyzer results. Applying SoC-specific defaults here to avoid touching upstream Zephyr files. BT_TX_PROCESSOR_STACK_SIZE config is made promped in the nrf-scope and was disabled for the samples/applications that don't have enough RAM to support it. Signed-off-by: Kyra Lengfeld --- Kconfig.nrf | 18 ++++++++++++++++++ .../nrf52820dongle_nrf52820/prj.conf | 2 ++ .../nrf52820dongle_nrf52820/prj_release.conf | 2 ++ .../configuration/nrf52833dk_nrf52820/prj.conf | 2 ++ .../nrf52833dk_nrf52820/prj_release.conf | 2 ++ .../nrf52833dk_nrf52833/prj_dongle_small.conf | 2 ++ .../direction_finding_central/prj.conf | 3 +++ .../direction_finding_peripheral/prj.conf | 3 +++ subsys/bluetooth/Kconfig | 6 ++++++ 9 files changed, 40 insertions(+) diff --git a/Kconfig.nrf b/Kconfig.nrf index 25c67b41312..050c099ac8e 100644 --- a/Kconfig.nrf +++ b/Kconfig.nrf @@ -121,6 +121,24 @@ config NRF_SECURITY_ENABLER imply MBEDTLS_ENABLE_HEAP if BT_HOST_CRYPTO_PRNG || BT_ECC || BT_GATT_CACHING || BT_CRYPTO depends on !SOC_NRF5340_CPUNET +# Bluetooth TX processor thread stack Thread Analyzer measurements +# Apply SoC-specific defaults here to avoid touching upstream Zephyr files. +# Applications can still override via prj.conf. +configdefault BT_TX_PROCESSOR_STACK_SIZE + # nRF52 variants + default 768 if SOC_NRF52840 + default 696 if SOC_NRF52832 + default 969 if SOC_NRF52833 + # nRF53 (application core) + default 688 if SOC_NRF5340_CPUAPP + # nRF54H20 (application core) + default 624 if SOC_NRF54H20_CPUAPP + # nRF54L15 (application core) + default 856 if SOC_NRF54L15_CPUAPP + # nRF54L V10A / LM20A (currently application core EngA variants are used) + default 856 if SOC_NRF54LV10A_ENGA_CPUAPP + default 856 if SOC_NRF54LM20A_ENGA_CPUAPP + if SOC_SERIES_BSIM_NRFXX && ENTROPY_GENERATOR config MBEDTLS_HEAP_SIZE int diff --git a/applications/nrf_desktop/configuration/nrf52820dongle_nrf52820/prj.conf b/applications/nrf_desktop/configuration/nrf52820dongle_nrf52820/prj.conf index 7106856d9a4..74e6f94694f 100644 --- a/applications/nrf_desktop/configuration/nrf52820dongle_nrf52820/prj.conf +++ b/applications/nrf_desktop/configuration/nrf52820dongle_nrf52820/prj.conf @@ -48,6 +48,8 @@ CONFIG_BT_RECV_WORKQ_SYS=y CONFIG_BT_GATT_DM_WORKQ_SYS=y # Disable Bluetooth long workqueue to reduce memory consumption CONFIG_BT_LONG_WQ=n +# Don't use BT TX processor thread due to limited RAM. +CONFIG_BT_TX_PROCESSOR_THREAD=n # Limit number of key slots in the PSA Crypto core to reduce memory consumption CONFIG_MBEDTLS_PSA_KEY_SLOT_COUNT=10 diff --git a/applications/nrf_desktop/configuration/nrf52820dongle_nrf52820/prj_release.conf b/applications/nrf_desktop/configuration/nrf52820dongle_nrf52820/prj_release.conf index 735ed8a3d35..7972a3e0795 100644 --- a/applications/nrf_desktop/configuration/nrf52820dongle_nrf52820/prj_release.conf +++ b/applications/nrf_desktop/configuration/nrf52820dongle_nrf52820/prj_release.conf @@ -46,6 +46,8 @@ CONFIG_BT_RECV_WORKQ_SYS=y CONFIG_BT_GATT_DM_WORKQ_SYS=y # Disable Bluetooth long workqueue to reduce memory consumption CONFIG_BT_LONG_WQ=n +# Don't use BT TX processor thread due to limited RAM. +CONFIG_BT_TX_PROCESSOR_THREAD=n # Limit number of key slots in the PSA Crypto core to reduce memory consumption CONFIG_MBEDTLS_PSA_KEY_SLOT_COUNT=10 diff --git a/applications/nrf_desktop/configuration/nrf52833dk_nrf52820/prj.conf b/applications/nrf_desktop/configuration/nrf52833dk_nrf52820/prj.conf index d9b9d774e9d..3552607a24a 100644 --- a/applications/nrf_desktop/configuration/nrf52833dk_nrf52820/prj.conf +++ b/applications/nrf_desktop/configuration/nrf52833dk_nrf52820/prj.conf @@ -49,6 +49,8 @@ CONFIG_BT_RECV_WORKQ_SYS=y CONFIG_BT_GATT_DM_WORKQ_SYS=y # Disable Bluetooth long workqueue to reduce memory consumption CONFIG_BT_LONG_WQ=n +# Don't use BT TX processor thread due to limited RAM. +CONFIG_BT_TX_PROCESSOR_THREAD=n # Limit number of key slots in the PSA Crypto core to reduce memory consumption CONFIG_MBEDTLS_PSA_KEY_SLOT_COUNT=10 diff --git a/applications/nrf_desktop/configuration/nrf52833dk_nrf52820/prj_release.conf b/applications/nrf_desktop/configuration/nrf52833dk_nrf52820/prj_release.conf index a616ae5d3be..94f05452345 100644 --- a/applications/nrf_desktop/configuration/nrf52833dk_nrf52820/prj_release.conf +++ b/applications/nrf_desktop/configuration/nrf52833dk_nrf52820/prj_release.conf @@ -47,6 +47,8 @@ CONFIG_BT_RECV_WORKQ_SYS=y CONFIG_BT_GATT_DM_WORKQ_SYS=y # Disable Bluetooth long workqueue to reduce memory consumption CONFIG_BT_LONG_WQ=n +# Don't use BT TX processor thread due to limited RAM. +CONFIG_BT_TX_PROCESSOR_THREAD=n # Limit number of key slots in the PSA Crypto core to reduce memory consumption CONFIG_MBEDTLS_PSA_KEY_SLOT_COUNT=10 diff --git a/applications/nrf_desktop/configuration/nrf52833dk_nrf52833/prj_dongle_small.conf b/applications/nrf_desktop/configuration/nrf52833dk_nrf52833/prj_dongle_small.conf index 1477d8ae0f8..02dfc7c30c7 100644 --- a/applications/nrf_desktop/configuration/nrf52833dk_nrf52833/prj_dongle_small.conf +++ b/applications/nrf_desktop/configuration/nrf52833dk_nrf52833/prj_dongle_small.conf @@ -54,6 +54,8 @@ CONFIG_BT_RECV_WORKQ_SYS=y CONFIG_BT_GATT_DM_WORKQ_SYS=y # Disable Bluetooth long workqueue to reduce memory consumption CONFIG_BT_LONG_WQ=n +# Don't use BT TX processor thread due to limited RAM. +CONFIG_BT_TX_PROCESSOR_THREAD=n # Limit number of key slots in the PSA Crypto core to reduce memory consumption CONFIG_MBEDTLS_PSA_KEY_SLOT_COUNT=10 diff --git a/samples/bluetooth/direction_finding_central/prj.conf b/samples/bluetooth/direction_finding_central/prj.conf index f696c4664e6..320d0f9dfbc 100644 --- a/samples/bluetooth/direction_finding_central/prj.conf +++ b/samples/bluetooth/direction_finding_central/prj.conf @@ -16,3 +16,6 @@ CONFIG_BT_GATT_CLIENT=y CONFIG_BT_DF=y CONFIG_BT_DF_CONNECTION_CTE_RX=y CONFIG_BT_DF_CONNECTION_CTE_REQ=y + +# Don't use BT TX processor thread due to limited RAM. +CONFIG_BT_TX_PROCESSOR_THREAD=n diff --git a/samples/bluetooth/direction_finding_peripheral/prj.conf b/samples/bluetooth/direction_finding_peripheral/prj.conf index 1da0905df11..5bbdcef3da6 100644 --- a/samples/bluetooth/direction_finding_peripheral/prj.conf +++ b/samples/bluetooth/direction_finding_peripheral/prj.conf @@ -19,3 +19,6 @@ CONFIG_BT_DF_CONNECTION_CTE_RSP=y # Disable AoD Feature (antenna switching) in Tx mode in Host CONFIG_BT_DF_CTE_TX_AOD=n + +# Don't use BT TX processor thread due to limited RAM. +CONFIG_BT_TX_PROCESSOR_THREAD=n diff --git a/subsys/bluetooth/Kconfig b/subsys/bluetooth/Kconfig index 43ae027819d..8dde3f9467a 100644 --- a/subsys/bluetooth/Kconfig +++ b/subsys/bluetooth/Kconfig @@ -45,6 +45,12 @@ config BT_LONG_WQ_STACK_SIZE default 1800 if (BT_ECC || BT_GATT_CACHING) default 1024 +# Note that some nRF boards have very limited RAM. For these we give the prompt-option to disable +# the BT TX processor thread. +# Disabling the BT TX processor thread may cause deadlocks. +config BT_TX_PROCESSOR_THREAD + prompt "Bluetooth TX processor thread" + rsource "controller/Kconfig" rsource "host_extensions/Kconfig" rsource "cs_de/Kconfig"