From 790320ea8b9ff6342c32c2bfa0eb69cec02aab56 Mon Sep 17 00:00:00 2001 From: Piotr Kosycarz Date: Thu, 21 May 2026 08:43:42 +0200 Subject: [PATCH 01/37] scripts: quarantine: update quarantine for ble at lc10 More failures. Signed-off-by: Piotr Kosycarz --- scripts/quarantine.yaml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/scripts/quarantine.yaml b/scripts/quarantine.yaml index ef4f8f7dc6c4..5cf6659ed1b1 100644 --- a/scripts/quarantine.yaml +++ b/scripts/quarantine.yaml @@ -114,13 +114,15 @@ comment: "https://nordicsemi.atlassian.net/browse/NRFX-9465" - scenarios: - - sample.benchmarks.peripheral_stress_test.nrf54lv10_lc10 + - benchmarks.current_consumption.beacon_idle.nrf54l + - benchmarks.current_consumption.beacon_idle.nrf54l.lfrc - benchmarks.current_consumption.beacon_vs_vdd - benchmarks.current_consumption.beacon_vs_vdd.nrf54l_lfrc - - benchmarks.current_consumptaion.beacon_idle.nrf54l.lfrc - benchmarks.peripheral_stress_test.nrf54lv10_lc10.mcuboot - - benchmarks.current_consumption.beacon_idle.nrf54l - benchmarks.peripheral_stress_test.nrf54lv10_lc10.mcuboot.lto + - sample.benchmarks.peripheral_stress_test.nrf54lv10_lc10 + - sample.benchmarks.peripheral_stress_test.nrf54lv10_lc10.mcuboot + - sample.benchmarks.peripheral_stress_test.nrf54lv10_lc10.mcuboot.lto platforms: - nrf54lc10dk@0.8.0/nrf54lc10a/cpuapp comment: "no MPSL for nrf54lc10 at the moment" From 22863e342d18bcff680f25fa737d19fcc8325eb9 Mon Sep 17 00:00:00 2001 From: Piotr Kosycarz Date: Thu, 21 May 2026 08:46:09 +0200 Subject: [PATCH 02/37] scripts: quarantine: add lc10/ns TFM not supported yet. Signed-off-by: Piotr Kosycarz --- scripts/quarantine.yaml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/scripts/quarantine.yaml b/scripts/quarantine.yaml index 5cf6659ed1b1..51545f597da6 100644 --- a/scripts/quarantine.yaml +++ b/scripts/quarantine.yaml @@ -127,6 +127,24 @@ - nrf54lc10dk@0.8.0/nrf54lc10a/cpuapp comment: "no MPSL for nrf54lc10 at the moment" +- scenarios: + - nrf.extended.drivers.clock.clock_control_onoff + - nrf.extended.drivers.clock.nrf5_clock_calibration + - nrf.extended.drivers.clock.nrf_lf_clock_start_rc_available + - nrf.extended.drivers.clock.nrf_lf_clock_start_rc_no_wait + - nrf.extended.drivers.clock.nrf_lf_clock_start_rc_stable + - nrf.extended.drivers.clock.nrf_lf_clock_start_synth_available + - nrf.extended.drivers.clock.nrf_lf_clock_start_synth_no_wait + - nrf.extended.drivers.clock.nrf_lf_clock_start_synth_stable + - nrf.extended.drivers.clock.nrf_lf_clock_start_xtal_available + - nrf.extended.drivers.clock.nrf_lf_clock_start_xtal_no_wait + - nrf.extended.drivers.clock.nrf_lf_clock_start_xtal_stable + - nrf.extended.drivers.comparator.gpio_loopback.nrf_comp + - nrf.extended.drivers.comparator.gpio_loopback.nrf_lpcomp + platforms: + - nrf54lc10dk@0.8.0/nrf54lc10a/cpuapp/ns + comment: "no TFM for nrf54lc10 at the moment" + - scenarios: - nrf.extended.drivers.counter.basic_api platforms: From 2543bff4dd63a6fccdc39c1efccf85b6952bdce0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simen=20S=2E=20R=C3=B8stad?= Date: Tue, 10 Mar 2026 16:58:44 +0100 Subject: [PATCH 03/37] samples: net: http_server: disable IPv6 and fix TLS cert generation docs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace `CONFIG_NET_IPV6_NBR_CACHE=n` and `CONFIG_NET_IPV6_MLD=n` with `CONFIG_NET_IPV6=n` on all nRF91 and Thingy91 board configs to fully disable IPv6 rather than only disabling DAD workarounds. The server sample does not currently work properly with Ipv6 enabled on cellular targets. Update TLS credential generation docs to include `-subj` and `-addext` flags so the certificate CN and SAN match the device's static IP, fixing certificate validation failures for cellular builds. Signed-off-by: Simen S. Røstad --- samples/net/http_server/README.rst | 7 ++++--- .../http_server/boards/nrf9151dk_nrf9151_ns.conf | 14 +++++++++----- .../http_server/boards/nrf9160dk_nrf9160_ns.conf | 14 +++++++++----- .../http_server/boards/nrf9161dk_nrf9161_ns.conf | 14 +++++++++----- .../http_server/boards/thingy91_nrf9160_ns.conf | 14 +++++++++----- samples/net/http_server/overlay-tls-nrf91.conf | 8 +++----- 6 files changed, 43 insertions(+), 28 deletions(-) diff --git a/samples/net/http_server/README.rst b/samples/net/http_server/README.rst index 51d45e68bca0..c33eab69c621 100644 --- a/samples/net/http_server/README.rst +++ b/samples/net/http_server/README.rst @@ -121,12 +121,13 @@ To enable TLS, the sample includes pregenerated credentials that are located in Peer verification can be used by building the sample with the :ref:`CONFIG_HTTP_SERVER_SAMPLE_PEER_VERIFICATION_REQUIRE ` Kconfig option, and passing the appropriate credentials when making the HTTP calls. These pregenerated credentials work only when you are building for Wi-Fi and running the server on your local Wi-Fi network. You need to generate new credentials when building for cellular due to a CN mismatch. -To generate new credentials, run the following commands: +To generate new credentials, run the following commands, replacing ```` with the static IP address assigned to the device: - .. code-block:: console + .. code-block:: bash # Generate a new RSA key pair (private key and public key) and create a self-signed X.509 certificate for a server. - openssl req -newkey rsa:2048 -nodes -keyout server_private_key.pem -x509 -days 365 -out server_certificate.pem + # The -subj and -addext flags set the Common Name (CN) and Subject Alternative Name (SAN) to the server's static IP. + openssl req -newkey rsa:2048 -nodes -keyout server_private_key.pem -x509 -days 365 -out server_certificate.pem -subj "/CN=" -addext "subjectAltName=IP:" # Generate a new RSA private key for a client. openssl genpkey -algorithm RSA -out client.key diff --git a/samples/net/http_server/boards/nrf9151dk_nrf9151_ns.conf b/samples/net/http_server/boards/nrf9151dk_nrf9151_ns.conf index 2f2efdf91124..ea3ab3758b56 100644 --- a/samples/net/http_server/boards/nrf9151dk_nrf9151_ns.conf +++ b/samples/net/http_server/boards/nrf9151dk_nrf9151_ns.conf @@ -11,14 +11,18 @@ # General CONFIG_PICOLIBC=y -# Disable Duplicate Address Detection (DAD) -# due to not being properly implemented for offloaded interfaces. -CONFIG_NET_IPV6_NBR_CACHE=n -CONFIG_NET_IPV6_MLD=n +# The server doesn't support dual stack (IPv4/IPv6) on cellular. +CONFIG_NET_IPV6=n # Zephyr NET Connection Manager and Connectivity layer. CONFIG_NET_CONNECTION_MANAGER_MONITOR_STACK_SIZE=1024 CONFIG_NRF_MODEM_LIB_NET_IF=y -# Disable PSM to make sure that the server is always available. +# Disable PSM and eDRX to increase the servers latency. +CONFIG_LTE_LC_PSM_MODULE=y CONFIG_LTE_PSM_REQ=n +CONFIG_LTE_LC_EDRX_MODULE=y +CONFIG_LTE_EDRX_REQ=n + +# TF-M config +CONFIG_TFM_PROFILE_TYPE_MINIMAL=y diff --git a/samples/net/http_server/boards/nrf9160dk_nrf9160_ns.conf b/samples/net/http_server/boards/nrf9160dk_nrf9160_ns.conf index b01cfceb85c6..2533c234e7d4 100644 --- a/samples/net/http_server/boards/nrf9160dk_nrf9160_ns.conf +++ b/samples/net/http_server/boards/nrf9160dk_nrf9160_ns.conf @@ -11,14 +11,18 @@ # General CONFIG_PICOLIBC=y -# Disable Duplicate Address Detection (DAD) -# due to not being properly implemented for offloaded interfaces. -CONFIG_NET_IPV6_NBR_CACHE=n -CONFIG_NET_IPV6_MLD=n +# The server doesn't support dual stack (IPv4/IPv6) on cellular. +CONFIG_NET_IPV6=n # Zephyr NET Connection Manager and Connectivity layer. CONFIG_NET_CONNECTION_MANAGER_MONITOR_STACK_SIZE=1024 CONFIG_NRF_MODEM_LIB_NET_IF=y -# Disable PSM to make sure that the server is always available. +# Disable PSM and eDRX to increase the servers latency. +CONFIG_LTE_LC_PSM_MODULE=y CONFIG_LTE_PSM_REQ=n +CONFIG_LTE_LC_EDRX_MODULE=y +CONFIG_LTE_EDRX_REQ=n + +# TF-M config +CONFIG_TFM_PROFILE_TYPE_MINIMAL=y diff --git a/samples/net/http_server/boards/nrf9161dk_nrf9161_ns.conf b/samples/net/http_server/boards/nrf9161dk_nrf9161_ns.conf index 3bf27e40129d..9f0cf5d86a54 100644 --- a/samples/net/http_server/boards/nrf9161dk_nrf9161_ns.conf +++ b/samples/net/http_server/boards/nrf9161dk_nrf9161_ns.conf @@ -11,14 +11,18 @@ # General CONFIG_PICOLIBC=y -# Disable Duplicate Address Detection (DAD) -# due to not being properly implemented for offloaded interfaces. -CONFIG_NET_IPV6_NBR_CACHE=n -CONFIG_NET_IPV6_MLD=n +# The server doesn't support dual stack (IPv4/IPv6) on cellular. +CONFIG_NET_IPV6=n # Zephyr NET Connection Manager and Connectivity layer. CONFIG_NET_CONNECTION_MANAGER_MONITOR_STACK_SIZE=1024 CONFIG_NRF_MODEM_LIB_NET_IF=y -# Disable PSM to make sure that the server is always available. +# Disable PSM and eDRX to increase the servers latency. +CONFIG_LTE_LC_PSM_MODULE=y CONFIG_LTE_PSM_REQ=n +CONFIG_LTE_LC_EDRX_MODULE=y +CONFIG_LTE_EDRX_REQ=n + +# TF-M config +CONFIG_TFM_PROFILE_TYPE_MINIMAL=y diff --git a/samples/net/http_server/boards/thingy91_nrf9160_ns.conf b/samples/net/http_server/boards/thingy91_nrf9160_ns.conf index 7a8465aad8b9..500f0bb7319d 100644 --- a/samples/net/http_server/boards/thingy91_nrf9160_ns.conf +++ b/samples/net/http_server/boards/thingy91_nrf9160_ns.conf @@ -11,14 +11,18 @@ # General CONFIG_PICOLIBC=y -# Disable Duplicate Address Detection (DAD) -# due to not being properly implemented for offloaded interfaces. -CONFIG_NET_IPV6_NBR_CACHE=n -CONFIG_NET_IPV6_MLD=n +# The server doesn't support dual stack (IPv4/IPv6) on cellular. +CONFIG_NET_IPV6=n # Zephyr NET Connection Manager and Connectivity layer. CONFIG_NET_CONNECTION_MANAGER_MONITOR_STACK_SIZE=1024 CONFIG_NRF_MODEM_LIB_NET_IF=y -# Disable PSM to make sure that the server is always available. +# Disable PSM and eDRX to increase the servers latency. +CONFIG_LTE_LC_PSM_MODULE=y CONFIG_LTE_PSM_REQ=n +CONFIG_LTE_LC_EDRX_MODULE=y +CONFIG_LTE_EDRX_REQ=n + +# TF-M config +CONFIG_TFM_PROFILE_TYPE_MINIMAL=y diff --git a/samples/net/http_server/overlay-tls-nrf91.conf b/samples/net/http_server/overlay-tls-nrf91.conf index 118025930602..91aeaac229d4 100644 --- a/samples/net/http_server/overlay-tls-nrf91.conf +++ b/samples/net/http_server/overlay-tls-nrf91.conf @@ -6,14 +6,12 @@ # NET sockets CONFIG_NET_SOCKETS_SOCKOPT_TLS=y -CONFIG_NET_SOCKETS_TLS_MAX_CONTEXTS=3 +CONFIG_NET_SOCKETS_TLS_MAX_CONTEXTS=2 -# nRF Security legacy MBed TLS +# nRF Security MBed TLS CONFIG_NORDIC_SECURITY_BACKEND=y CONFIG_MBEDTLS_ENABLE_HEAP=y -CONFIG_MBEDTLS_HEAP_SIZE=36864 -# Legacy API is required for RSA -CONFIG_MBEDTLS_LEGACY_CRYPTO_C=y +CONFIG_MBEDTLS_HEAP_SIZE=51200 CONFIG_MBEDTLS_RSA_C=y CONFIG_PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_IMPORT=y CONFIG_PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_EXPORT=y From 4dd1959c39529423c7528f45223f49c62b34cebb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simen=20S=2E=20R=C3=B8stad?= Date: Mon, 11 May 2026 11:05:40 +0200 Subject: [PATCH 04/37] samples: net: http_server: switch TF-M to small profile MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace `CONFIG_TFM_PROFILE_TYPE_MINIMAL` with `CONFIG_TFM_PROFILE_TYPE_SMALL` and add explicit partition size configs for TF-M SRAM and flash across all nRF91 board configs. Without this, the TF-M partition sizes are too small to fit the TLS server. Signed-off-by: Simen S. Røstad --- samples/net/http_server/boards/nrf9151dk_nrf9151_ns.conf | 8 +++++--- samples/net/http_server/boards/nrf9160dk_nrf9160_ns.conf | 8 +++++--- samples/net/http_server/boards/nrf9161dk_nrf9161_ns.conf | 8 +++++--- samples/net/http_server/boards/thingy91_nrf9160_ns.conf | 8 +++++--- 4 files changed, 20 insertions(+), 12 deletions(-) diff --git a/samples/net/http_server/boards/nrf9151dk_nrf9151_ns.conf b/samples/net/http_server/boards/nrf9151dk_nrf9151_ns.conf index ea3ab3758b56..dd18363f9347 100644 --- a/samples/net/http_server/boards/nrf9151dk_nrf9151_ns.conf +++ b/samples/net/http_server/boards/nrf9151dk_nrf9151_ns.conf @@ -8,6 +8,11 @@ # This file is merged with prj.conf in the application folder, and options # set here will take precedence if they are present in both files. +# Optimize TF-M +CONFIG_TFM_PROFILE_TYPE_SMALL=y +CONFIG_PM_PARTITION_SIZE_TFM_SRAM=0xc000 +CONFIG_PM_PARTITION_SIZE_TFM=0x20000 + # General CONFIG_PICOLIBC=y @@ -23,6 +28,3 @@ CONFIG_LTE_LC_PSM_MODULE=y CONFIG_LTE_PSM_REQ=n CONFIG_LTE_LC_EDRX_MODULE=y CONFIG_LTE_EDRX_REQ=n - -# TF-M config -CONFIG_TFM_PROFILE_TYPE_MINIMAL=y diff --git a/samples/net/http_server/boards/nrf9160dk_nrf9160_ns.conf b/samples/net/http_server/boards/nrf9160dk_nrf9160_ns.conf index 2533c234e7d4..807d005a2cee 100644 --- a/samples/net/http_server/boards/nrf9160dk_nrf9160_ns.conf +++ b/samples/net/http_server/boards/nrf9160dk_nrf9160_ns.conf @@ -8,6 +8,11 @@ # This file is merged with prj.conf in the application folder, and options # set here will take precedence if they are present in both files. +# Optimize TF-M +CONFIG_TFM_PROFILE_TYPE_SMALL=y +CONFIG_PM_PARTITION_SIZE_TFM_SRAM=0xc000 +CONFIG_PM_PARTITION_SIZE_TFM=0x20000 + # General CONFIG_PICOLIBC=y @@ -23,6 +28,3 @@ CONFIG_LTE_LC_PSM_MODULE=y CONFIG_LTE_PSM_REQ=n CONFIG_LTE_LC_EDRX_MODULE=y CONFIG_LTE_EDRX_REQ=n - -# TF-M config -CONFIG_TFM_PROFILE_TYPE_MINIMAL=y diff --git a/samples/net/http_server/boards/nrf9161dk_nrf9161_ns.conf b/samples/net/http_server/boards/nrf9161dk_nrf9161_ns.conf index 9f0cf5d86a54..d3145d727602 100644 --- a/samples/net/http_server/boards/nrf9161dk_nrf9161_ns.conf +++ b/samples/net/http_server/boards/nrf9161dk_nrf9161_ns.conf @@ -8,6 +8,11 @@ # This file is merged with prj.conf in the application folder, and options # set here will take precedence if they are present in both files. +# Optimize TF-M +CONFIG_TFM_PROFILE_TYPE_SMALL=y +CONFIG_PM_PARTITION_SIZE_TFM_SRAM=0xc000 +CONFIG_PM_PARTITION_SIZE_TFM=0x20000 + # General CONFIG_PICOLIBC=y @@ -23,6 +28,3 @@ CONFIG_LTE_LC_PSM_MODULE=y CONFIG_LTE_PSM_REQ=n CONFIG_LTE_LC_EDRX_MODULE=y CONFIG_LTE_EDRX_REQ=n - -# TF-M config -CONFIG_TFM_PROFILE_TYPE_MINIMAL=y diff --git a/samples/net/http_server/boards/thingy91_nrf9160_ns.conf b/samples/net/http_server/boards/thingy91_nrf9160_ns.conf index 500f0bb7319d..01e66ff26269 100644 --- a/samples/net/http_server/boards/thingy91_nrf9160_ns.conf +++ b/samples/net/http_server/boards/thingy91_nrf9160_ns.conf @@ -8,6 +8,11 @@ # This file is merged with prj.conf in the application folder, and options # set here will take precedence if they are present in both files. +# Optimize TF-M +CONFIG_TFM_PROFILE_TYPE_SMALL=y +CONFIG_PM_PARTITION_SIZE_TFM_SRAM=0xc000 +CONFIG_PM_PARTITION_SIZE_TFM=0x20000 + # General CONFIG_PICOLIBC=y @@ -23,6 +28,3 @@ CONFIG_LTE_LC_PSM_MODULE=y CONFIG_LTE_PSM_REQ=n CONFIG_LTE_LC_EDRX_MODULE=y CONFIG_LTE_EDRX_REQ=n - -# TF-M config -CONFIG_TFM_PROFILE_TYPE_MINIMAL=y From ce7560f17f598590550285e5fee5b23ca3986ce7 Mon Sep 17 00:00:00 2001 From: Bartlomiej Buczek Date: Wed, 13 May 2026 12:16:06 +0200 Subject: [PATCH 05/37] tests: mbox_error_cases: Enable for nrf54lc10a. Add neccessary overlay and testcase.yaml entries. Signed-off-by: Bartlomiej Buczek --- .../nrf54lc10dk_nrf54lc10a_cpuapp.overlay | 22 +++++++++++++++++++ .../drivers/mbox/mbox_error_cases/sample.yaml | 1 + 2 files changed, 23 insertions(+) create mode 100644 tests/zephyr/drivers/mbox/mbox_error_cases/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay diff --git a/tests/zephyr/drivers/mbox/mbox_error_cases/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay b/tests/zephyr/drivers/mbox/mbox_error_cases/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay new file mode 100644 index 000000000000..2cd01ba6572b --- /dev/null +++ b/tests/zephyr/drivers/mbox/mbox_error_cases/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay @@ -0,0 +1,22 @@ +/* + * Copyright 2026 Nordic Semiconductor ASA + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + mbox-consumer { + compatible = "vnd,mbox-consumer"; + mboxes = <&cpuapp_vevif_tx 21>, <&cpuapp_vevif_tx 32>, + <&cpuapp_vevif_rx 20>, <&cpuapp_vevif_rx 32>; + mbox-names = "remote_valid", "remote_incorrect", + "local_valid", "local_incorrect"; + }; +}; + +&cpuapp_vevif_rx { + status = "okay"; +}; + +&cpuapp_vevif_tx { + status = "okay"; +}; diff --git a/tests/zephyr/drivers/mbox/mbox_error_cases/sample.yaml b/tests/zephyr/drivers/mbox/mbox_error_cases/sample.yaml index c06c7f9432fe..832a8b7cb78b 100644 --- a/tests/zephyr/drivers/mbox/mbox_error_cases/sample.yaml +++ b/tests/zephyr/drivers/mbox/mbox_error_cases/sample.yaml @@ -16,6 +16,7 @@ tests: nrf.extended.tests.drivers.mbox_error_cases.nrf54l: platform_allow: - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54lv10dk/nrf54lv10a/cpuapp extra_args: SNIPPET=nordic-flpr From b7ce50aa02b005d9dd546200933539701efb33f6 Mon Sep 17 00:00:00 2001 From: Bartlomiej Buczek Date: Wed, 13 May 2026 12:27:13 +0200 Subject: [PATCH 06/37] samples: ipc_service: Enable for nrf54lc10a. Add neccessary overlay and testcase.yaml entries. Signed-off-by: Bartlomiej Buczek --- samples/ipc/ipc_service/Kconfig.sysbuild | 1 + .../nrf54lc10dk_nrf54lc10a_cpuapp.overlay | 42 ++++++++++++++++ ...f54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay | 44 +++++++++++++++++ .../nrf54lc10dk_nrf54lc10a_cpuflpr.overlay | 46 ++++++++++++++++++ ...54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay | 48 +++++++++++++++++++ samples/ipc/ipc_service/sample.yaml | 2 + 6 files changed, 183 insertions(+) create mode 100644 samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay create mode 100644 samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay create mode 100644 samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay create mode 100644 samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay diff --git a/samples/ipc/ipc_service/Kconfig.sysbuild b/samples/ipc/ipc_service/Kconfig.sysbuild index 6fc2aa588087..aedd2cafde23 100644 --- a/samples/ipc/ipc_service/Kconfig.sysbuild +++ b/samples/ipc/ipc_service/Kconfig.sysbuild @@ -13,6 +13,7 @@ config REMOTE_BOARD default "nrf54lm20dk/nrf54lm20a/cpuflpr" if BOARD_NRF54LM20DK_NRF54LM20A_CPUAPP default "nrf54lm20dk/nrf54lm20b/cpuflpr" if BOARD_NRF54LM20DK_NRF54LM20B_CPUAPP default "nrf54lv10dk/nrf54lv10a/cpuflpr" if BOARD_NRF54LV10DK_NRF54LV10A_CPUAPP + default "nrf54lc10dk/nrf54lc10a/cpuflpr" if BOARD_NRF54LC10DK_NRF54LC10A_CPUAPP default "nrf7120dk/nrf7120/cpuflpr" if BOARD_NRF7120DK_NRF7120_CPUAPP default "nrf9251dk/nrf9251/cpuppr" if BOARD_NRF9251DK_NRF9251_CPUAPP diff --git a/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay b/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay new file mode 100644 index 000000000000..32d2a9d75043 --- /dev/null +++ b/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay @@ -0,0 +1,42 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + mboxes = <&cpuapp_vevif_rx 20>, <&cpuapp_vevif_tx 21>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuapp_vevif_rx { + status = "okay"; +}; + +&cpuapp_vevif_tx { + status = "okay"; +}; diff --git a/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay b/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay new file mode 100644 index 000000000000..270560eceed4 --- /dev/null +++ b/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icbmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + tx-blocks = <16>; + rx-blocks = <18>; + mboxes = <&cpuapp_vevif_rx 20>, <&cpuapp_vevif_tx 21>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuapp_vevif_rx { + status = "okay"; +}; + +&cpuapp_vevif_tx { + status = "okay"; +}; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay b/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay new file mode 100644 index 000000000000..d547e8617887 --- /dev/null +++ b/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay @@ -0,0 +1,46 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + mboxes = <&cpuflpr_vevif_rx 21>, <&cpuflpr_vevif_tx 20>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuflpr_vevif_rx { + status = "okay"; +}; + +&cpuflpr_vevif_tx { + status = "okay"; +}; + +&uart20 { + /delete-property/ hw-flow-control; +}; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay b/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay new file mode 100644 index 000000000000..30a93ff5167a --- /dev/null +++ b/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay @@ -0,0 +1,48 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icbmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + tx-blocks = <18>; + rx-blocks = <16>; + mboxes = <&cpuflpr_vevif_rx 21>, <&cpuflpr_vevif_tx 20>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuflpr_vevif_rx { + status = "okay"; +}; + +&cpuflpr_vevif_tx { + status = "okay"; +}; + +&uart20 { + /delete-property/ hw-flow-control; +}; diff --git a/samples/ipc/ipc_service/sample.yaml b/samples/ipc/ipc_service/sample.yaml index 859899d4436e..e1855a417618 100644 --- a/samples/ipc/ipc_service/sample.yaml +++ b/samples/ipc/ipc_service/sample.yaml @@ -191,6 +191,7 @@ tests: - nrf54lm20dk/nrf54lm20a/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54l15dk/nrf54l15/cpuapp timeout: 20 @@ -205,6 +206,7 @@ tests: - nrf54lm20dk/nrf54lm20a/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54l15dk/nrf54l15/cpuapp timeout: 20 From 61657b1e84f6f4c037d5e69ef904b5c5c7e86c8f Mon Sep 17 00:00:00 2001 From: Bartlomiej Buczek Date: Wed, 13 May 2026 12:30:44 +0200 Subject: [PATCH 07/37] samples: event_manager_proxy: Enable for nrf54lc10a. Add neccessary overlay and testcase.yaml entries. Signed-off-by: Bartlomiej Buczek --- samples/event_manager_proxy/Kconfig.sysbuild | 1 + .../nrf54lc10dk_nrf54lc10a_cpuapp.overlay | 46 +++++++++++++++++++ .../nrf54lc10dk_nrf54lc10a_cpuflpr.conf | 17 +++++++ .../nrf54lc10dk_nrf54lc10a_cpuflpr.overlay | 46 +++++++++++++++++++ samples/event_manager_proxy/sample.yaml | 1 + 5 files changed, 111 insertions(+) create mode 100644 samples/event_manager_proxy/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay create mode 100644 samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.conf create mode 100644 samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay diff --git a/samples/event_manager_proxy/Kconfig.sysbuild b/samples/event_manager_proxy/Kconfig.sysbuild index ea76c66382a0..0b7653298f7f 100644 --- a/samples/event_manager_proxy/Kconfig.sysbuild +++ b/samples/event_manager_proxy/Kconfig.sysbuild @@ -16,6 +16,7 @@ config REMOTE_BOARD default "nrf54lm20dk/nrf54lm20a/cpuflpr" if BOARD_NRF54LM20DK_NRF54LM20A_CPUAPP default "nrf54lm20dk/nrf54lm20b/cpuflpr" if BOARD_NRF54LM20DK_NRF54LM20B_CPUAPP default "nrf54lv10dk/nrf54lv10a/cpuflpr" if BOARD_NRF54LV10DK_NRF54LV10A_CPUAPP + default "nrf54lc10dk/nrf54lc10a/cpuflpr" if BOARD_NRF54LC10DK_NRF54LC10A_CPUAPP default "nrf9251dk/nrf9251/cpuppr" if BOARD_NRF9251DK_NRF9251_CPUAPP source "share/sysbuild/Kconfig" diff --git a/samples/event_manager_proxy/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay b/samples/event_manager_proxy/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay new file mode 100644 index 000000000000..caae937b1a90 --- /dev/null +++ b/samples/event_manager_proxy/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay @@ -0,0 +1,46 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + chosen { + /delete-property/ zephyr,bt-hci; + }; + + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + mboxes = <&cpuapp_vevif_rx 20>, <&cpuapp_vevif_tx 21>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuapp_vevif_rx { + status = "okay"; +}; + +&cpuapp_vevif_tx { + status = "okay"; +}; diff --git a/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.conf b/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.conf new file mode 100644 index 000000000000..b4d2a7f704b1 --- /dev/null +++ b/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.conf @@ -0,0 +1,17 @@ +# +# Copyright (c) 2026 Nordic Semiconductor ASA +# +# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause +# +################################################################################ + +CONFIG_LOG=y +CONFIG_LOG_MODE_MINIMAL=y +CONFIG_ASSERT=n +CONFIG_LOG_BACKEND_UART=n + +CONFIG_BOOT_BANNER=n +CONFIG_EARLY_CONSOLE=y +CONFIG_HEAP_MEM_POOL_SIZE=1024 + +CONFIG_SIZE_OPTIMIZATIONS=y diff --git a/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay b/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay new file mode 100644 index 000000000000..d547e8617887 --- /dev/null +++ b/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay @@ -0,0 +1,46 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + mboxes = <&cpuflpr_vevif_rx 21>, <&cpuflpr_vevif_tx 20>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuflpr_vevif_rx { + status = "okay"; +}; + +&cpuflpr_vevif_tx { + status = "okay"; +}; + +&uart20 { + /delete-property/ hw-flow-control; +}; diff --git a/samples/event_manager_proxy/sample.yaml b/samples/event_manager_proxy/sample.yaml index a63573dcd894..fc7d892e521a 100644 --- a/samples/event_manager_proxy/sample.yaml +++ b/samples/event_manager_proxy/sample.yaml @@ -50,6 +50,7 @@ tests: - nrf54lm20dk/nrf54lm20a/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54l15dk/nrf54l15/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp From 9354b00076a4db369afa4e349fb309531abcfc63 Mon Sep 17 00:00:00 2001 From: Bartlomiej Buczek Date: Wed, 13 May 2026 12:35:31 +0200 Subject: [PATCH 08/37] samples: subsys: ipc_service: icmsg: Enable for nrf54lc10a. Add neccessary overlay and testcase.yaml entries. Signed-off-by: Bartlomiej Buczek --- .../ipc/ipc_service/icmsg/Kconfig.sysbuild | 1 + .../nrf54lc10dk_nrf54lc10a_cpuapp.overlay | 42 ++++++++++++++++ ...f54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay | 44 +++++++++++++++++ .../nrf54lc10dk_nrf54lc10a_cpuflpr.conf | 10 ++++ .../nrf54lc10dk_nrf54lc10a_cpuflpr.overlay | 46 ++++++++++++++++++ ...54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay | 48 +++++++++++++++++++ .../subsys/ipc/ipc_service/icmsg/sample.yaml | 6 +++ 7 files changed, 197 insertions(+) create mode 100644 samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay create mode 100644 samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay create mode 100644 samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.conf create mode 100644 samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay create mode 100644 samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/Kconfig.sysbuild b/samples/zephyr/subsys/ipc/ipc_service/icmsg/Kconfig.sysbuild index 371f731195c1..9711c69d0933 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/Kconfig.sysbuild +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/Kconfig.sysbuild @@ -7,6 +7,7 @@ source "share/sysbuild/Kconfig" config REMOTE_BOARD string default "$(BOARD)/nrf54lv10a/cpuflpr" if SOC_NRF54LV10A_CPUAPP + default "$(BOARD)/nrf54lc10a/cpuflpr" if SOC_NRF54LC10A_CPUAPP default "$(BOARD)/nrf54lm20a/cpuflpr" if SOC_NRF54LM20A_CPUAPP default "$(BOARD)/nrf54lm20b/cpuflpr" if SOC_NRF54LM20B_CPUAPP default "$(BOARD)/nrf54h20/cpuppr" if SOC_NRF54H20_CPUAPP diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay new file mode 100644 index 000000000000..32d2a9d75043 --- /dev/null +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay @@ -0,0 +1,42 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + mboxes = <&cpuapp_vevif_rx 20>, <&cpuapp_vevif_tx 21>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuapp_vevif_rx { + status = "okay"; +}; + +&cpuapp_vevif_tx { + status = "okay"; +}; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay new file mode 100644 index 000000000000..270560eceed4 --- /dev/null +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icbmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + tx-blocks = <16>; + rx-blocks = <18>; + mboxes = <&cpuapp_vevif_rx 20>, <&cpuapp_vevif_tx 21>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuapp_vevif_rx { + status = "okay"; +}; + +&cpuapp_vevif_tx { + status = "okay"; +}; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.conf b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.conf new file mode 100644 index 000000000000..527250c24c15 --- /dev/null +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.conf @@ -0,0 +1,10 @@ +CONFIG_LOG=y +CONFIG_LOG_MODE_MINIMAL=y +CONFIG_ASSERT=n +CONFIG_LOG_BACKEND_UART=n + +CONFIG_BOOT_BANNER=n +CONFIG_EARLY_CONSOLE=y +CONFIG_HEAP_MEM_POOL_SIZE=1024 + +CONFIG_SIZE_OPTIMIZATIONS=y diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay new file mode 100644 index 000000000000..d547e8617887 --- /dev/null +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay @@ -0,0 +1,46 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + mboxes = <&cpuflpr_vevif_rx 21>, <&cpuflpr_vevif_tx 20>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuflpr_vevif_rx { + status = "okay"; +}; + +&cpuflpr_vevif_tx { + status = "okay"; +}; + +&uart20 { + /delete-property/ hw-flow-control; +}; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay new file mode 100644 index 000000000000..30a93ff5167a --- /dev/null +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay @@ -0,0 +1,48 @@ +/* + * Copyright (c) 2026 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause + */ + +/ { + soc { + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; + + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; + }; + }; + }; + + ipc { + ipc0: ipc0 { + compatible = "zephyr,ipc-icbmsg"; + dcache-alignment = <32>; + tx-region = <&sram_tx>; + rx-region = <&sram_rx>; + tx-blocks = <18>; + rx-blocks = <16>; + mboxes = <&cpuflpr_vevif_rx 21>, <&cpuflpr_vevif_tx 20>; + mbox-names = "rx", "tx"; + status = "okay"; + }; + }; +}; + +&cpuflpr_vevif_rx { + status = "okay"; +}; + +&cpuflpr_vevif_tx { + status = "okay"; +}; + +&uart20 { + /delete-property/ hw-flow-control; +}; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/sample.yaml b/samples/zephyr/subsys/ipc/ipc_service/icmsg/sample.yaml index 1303a9f9405c..74631f018167 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/sample.yaml +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/sample.yaml @@ -26,6 +26,7 @@ tests: - nrf54lm20dk/nrf54lm20a/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54lv10dk/nrf54lv10a/cpuapp @@ -51,6 +52,7 @@ tests: - nrf54lm20dk/nrf54lm20a/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54lv10dk/nrf54lv10a/cpuapp @@ -74,6 +76,7 @@ tests: - nrf54lm20dk/nrf54lm20a/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54lv10dk/nrf54lv10a/cpuapp @@ -99,6 +102,7 @@ tests: - nrf54lm20dk/nrf54lm20a/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54lv10dk/nrf54lv10a/cpuapp @@ -128,6 +132,7 @@ tests: - nrf54lm20dk/nrf54lm20a/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54lv10dk/nrf54lv10a/cpuapp @@ -155,6 +160,7 @@ tests: - nrf54lm20dk/nrf54lm20a/cpuapp - nrf54lm20dk/nrf54lm20b/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp + - nrf54lc10dk/nrf54lc10a/cpuapp integration_platforms: - nrf54lv10dk/nrf54lv10a/cpuapp From 6a6fb04b6c4abfb0b814e81195686437f8d31397 Mon Sep 17 00:00:00 2001 From: Jan Tore Guggedal Date: Wed, 20 May 2026 09:52:48 +0200 Subject: [PATCH 09/37] net: lib: mqtt_helper: Conditionally request IPv6 address Only request Ipv6 address if CONFIG_NET_IPV6 is enabled. This fixes a possible buffer overflow where neighboring memory could be overwritten by IPv6 address if CONFIG_NET_IPV6 was not enabled, but DNS request responded with an IPv6 address. Signed-off-by: Jan Tore Guggedal --- .../releases/release-notes-changelog.rst | 4 +++ subsys/net/lib/mqtt_helper/mqtt_helper.c | 35 ++++++++++++++++--- .../lib/mqtt_helper/src/mqtt_helper_test.c | 35 ++++++++++--------- 3 files changed, 53 insertions(+), 21 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 3c5b58896cc6..03b92cba21da 100644 --- a/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst +++ b/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst @@ -676,6 +676,10 @@ Libraries for networking * Updated the status from experimental to supported. +* :ref:`lib_mqtt_helper` library: + + * Fixed an issue where the library could overflow the broker address buffer if an IPv6 address was returned by the DNS resolver while the :kconfig:option:`CONFIG_NET_IPV6` Kconfig option was disabled. + Libraries for NFC ----------------- diff --git a/subsys/net/lib/mqtt_helper/mqtt_helper.c b/subsys/net/lib/mqtt_helper/mqtt_helper.c index f96e7ecdb262..1357e3f43c85 100644 --- a/subsys/net/lib/mqtt_helper/mqtt_helper.c +++ b/subsys/net/lib/mqtt_helper/mqtt_helper.c @@ -378,10 +378,18 @@ static int broker_init(struct net_sockaddr_storage *broker, struct mqtt_helper_conn_params *conn_params) { int err; + bool resolved = false; struct zsock_addrinfo *result; struct zsock_addrinfo *addr; struct zsock_addrinfo hints = { - .ai_socktype = NET_SOCK_STREAM + .ai_socktype = NET_SOCK_STREAM, +#if defined(CONFIG_NET_IPV6) && defined(CONFIG_NET_IPV4) + .ai_family = NET_AF_UNSPEC, +#elif defined(CONFIG_NET_IPV6) + .ai_family = NET_AF_INET6, +#else + .ai_family = NET_AF_INET, +#endif }; char addr_str[NET_IPV6_ADDR_LEN]; @@ -402,6 +410,7 @@ static int broker_init(struct net_sockaddr_storage *broker, addr = result; while (addr != NULL) { +#if defined(CONFIG_NET_IPV6) if (addr->ai_family == NET_AF_INET6) { struct net_sockaddr_in6 *broker6 = ((struct net_sockaddr_in6 *)broker); @@ -414,8 +423,14 @@ static int broker_init(struct net_sockaddr_storage *broker, addr_str, sizeof(addr_str)); LOG_DBG("IPv6 Address found %s (%s)", addr_str, net_family2str(addr->ai_family)); + + resolved = true; + break; - } else if (addr->ai_family == NET_AF_INET) { + } +#endif /* CONFIG_NET_IPV6 */ + + if (addr->ai_family == NET_AF_INET) { struct net_sockaddr_in *broker4 = ((struct net_sockaddr_in *)broker); net_ipaddr_copy(&broker4->sin_addr, @@ -427,17 +442,27 @@ static int broker_init(struct net_sockaddr_storage *broker, addr_str, sizeof(addr_str)); LOG_DBG("IPv4 Address found %s (%s)", addr_str, net_family2str(addr->ai_family)); + + resolved = true; + break; - } else { - LOG_DBG("Unknown address family %d", (unsigned int)addr->ai_family); } + LOG_DBG("Skipping unsupported address family %d", + (unsigned int)addr->ai_family); + addr = addr->ai_next; } zsock_freeaddrinfo(result); - return err; + if (!resolved) { + LOG_ERR("No usable address returned for %s", conn_params->hostname.ptr); + + return -ENOENT; + } + + return 0; } static int client_connect(struct mqtt_helper_conn_params *conn_params) diff --git a/tests/subsys/net/lib/mqtt_helper/src/mqtt_helper_test.c b/tests/subsys/net/lib/mqtt_helper/src/mqtt_helper_test.c index acd2b0504eb9..24c5010453f4 100644 --- a/tests/subsys/net/lib/mqtt_helper/src/mqtt_helper_test.c +++ b/tests/subsys/net/lib/mqtt_helper/src/mqtt_helper_test.c @@ -51,6 +51,17 @@ extern void mqtt_helper_poll_loop(void); extern void on_publish(const struct mqtt_evt *mqtt_evt); extern char payload_buf[]; +/* Fake addrinfo entries returned from the mocked zsock_getaddrinfo(). */ +static struct net_sockaddr_in test_sockaddr_in = { + .sin_family = NET_AF_INET, +}; +static struct zsock_addrinfo test_addrinfo = { + .ai_family = NET_AF_INET, + .ai_addr = (struct net_sockaddr *)&test_sockaddr_in, + .ai_addrlen = sizeof(test_sockaddr_in), + .ai_next = NULL, +}; + /* Semaphores used by tests to wait for a certain callbacks */ static K_SEM_DEFINE(connack_success_sem, 0, 1); static K_SEM_DEFINE(connack_failed_sem, 0, 1); @@ -273,12 +284,7 @@ void test_mqtt_helper_connect_when_disconnected(void) .size = TEST_DEVICE_ID_LEN, }, }; - - /* Make getddrinfo return a pointer that points to NULL. Otherwise the unit under test - * would be dereferencing uninitialized memory location. The behavior of the unit - * under test for when non-NULL values are returned is out of scope of this test. - */ - struct zsock_addrinfo *test_res = NULL; + struct zsock_addrinfo *test_res = &test_addrinfo; __cmock_zsock_getaddrinfo_ExpectAndReturn(NULL, NULL, NULL, NULL, 0); __cmock_zsock_getaddrinfo_IgnoreArg_host(); @@ -286,6 +292,7 @@ void test_mqtt_helper_connect_when_disconnected(void) __cmock_zsock_getaddrinfo_IgnoreArg_res(); __cmock_zsock_getaddrinfo_ReturnThruPtr_res(&test_res); + __cmock_zsock_inet_ntop_IgnoreAndReturn(NULL); __cmock_zsock_freeaddrinfo_ExpectAnyArgs(); __cmock_mqtt_connect_ExpectAndReturn(&mqtt_client, 0); @@ -298,15 +305,7 @@ void test_mqtt_helper_connect_when_disconnected(void) void test_mqtt_helper_connect_when_disconnected_mqtt_api_error(void) { struct mqtt_helper_conn_params conn_params_dummy; - - __cmock_zsock_freeaddrinfo_ExpectAnyArgs(); - __cmock_mqtt_connect_ExpectAndReturn(&mqtt_client, -2); - - /* Make getddrinfo return a pointer that points to NULL. Otherwise the unit under test - * would be dereferencing uninitialized memory location. The behavior of the unit - * under test for when non-NULL values are returned is out of scope of this test. - */ - struct zsock_addrinfo *test_res = NULL; + struct zsock_addrinfo *test_res = &test_addrinfo; __cmock_zsock_getaddrinfo_ExpectAndReturn(NULL, NULL, NULL, NULL, 0); __cmock_zsock_getaddrinfo_IgnoreArg_host(); @@ -314,9 +313,13 @@ void test_mqtt_helper_connect_when_disconnected_mqtt_api_error(void) __cmock_zsock_getaddrinfo_IgnoreArg_res(); __cmock_zsock_getaddrinfo_ReturnThruPtr_res(&test_res); + __cmock_zsock_inet_ntop_IgnoreAndReturn(NULL); + __cmock_zsock_freeaddrinfo_ExpectAnyArgs(); + __cmock_mqtt_connect_ExpectAndReturn(&mqtt_client, -ENOENT); + mqtt_state = MQTT_STATE_DISCONNECTED; - TEST_ASSERT_EQUAL(-2, mqtt_helper_connect(&conn_params_dummy)); + TEST_ASSERT_EQUAL(-ENOENT, mqtt_helper_connect(&conn_params_dummy)); TEST_ASSERT_EQUAL(MQTT_STATE_DISCONNECTED, mqtt_state_get()); } From 549d536c331b9f1ebf770a51013dd857773de2b0 Mon Sep 17 00:00:00 2001 From: Robert Lubos Date: Tue, 19 May 2026 12:13:26 +0200 Subject: [PATCH 10/37] samples: net: https_client: Fix TLS configuration for native_sim The TLS configuration for native_sim target is currently broken, it fails to parse the certificate used in the sample: net_sock_tls: Failed to parse certificate on tag 42, err: -0x3a00 That's because CONFIG_PSA_WANT_ECC_SECP_R1_384 was missing and the certificate uses this curve. The remaining configs added were needed to pass the handshake with the default example.com host. Signed-off-by: Robert Lubos --- samples/net/https_client/boards/native_sim.conf | 3 +++ 1 file changed, 3 insertions(+) diff --git a/samples/net/https_client/boards/native_sim.conf b/samples/net/https_client/boards/native_sim.conf index 6f188926b423..6a4741241176 100644 --- a/samples/net/https_client/boards/native_sim.conf +++ b/samples/net/https_client/boards/native_sim.conf @@ -28,6 +28,9 @@ CONFIG_MBEDTLS_SSL_MAX_CONTENT_LEN=7168 CONFIG_MBEDTLS_PEM_PARSE_C=y CONFIG_MBEDTLS_PEM_WRITE_C=y CONFIG_MBEDTLS_CIPHERSUITE_TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256=y +CONFIG_MBEDTLS_CIPHERSUITE_TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384=y +CONFIG_MBEDTLS_SSL_SERVER_NAME_INDICATION=y +CONFIG_PSA_WANT_ECC_SECP_R1_384=y # DNS CONFIG_DNS_RESOLVER=y From e536b2d79fbcbd363f6b9f623c4d2e893a6f5cb8 Mon Sep 17 00:00:00 2001 From: Nordic Builder Date: Wed, 13 May 2026 08:45:34 +0000 Subject: [PATCH 11/37] 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/4075 Signed-off-by: Nordic Builder lib: nrf_modem_lib: SO_POLLCB support Implement SO_POLLCB in the offloading layer. Only one callback may be set per socket. If poll() is called on a socket with SO_POLLCB, the poll callback gets overwritten. Signed-off-by: Kacper Radoszewski --- lib/nrf_modem_lib/nrf9x_sockets.c | 54 +++++++++++++++++++++++++++++-- west.yml | 2 +- 2 files changed, 53 insertions(+), 3 deletions(-) diff --git a/lib/nrf_modem_lib/nrf9x_sockets.c b/lib/nrf_modem_lib/nrf9x_sockets.c index 82ae418a5ca2..b8f2b86eee50 100644 --- a/lib/nrf_modem_lib/nrf9x_sockets.c +++ b/lib/nrf_modem_lib/nrf9x_sockets.c @@ -52,6 +52,7 @@ static struct nrf_sock_ctx { int zvfs_fd; /* ZVFS socket descriptor. */ struct k_mutex *lock; /* Mutex associated with the socket. */ struct k_poll_signal poll; /* poll() signal. */ + struct socket_ncs_pollcb pollcb; /* Poll callback (owned by the app). */ struct socket_ncs_sendcb sendcb; /* Send callback. */ } offload_ctx[NRF_MODEM_MAX_SOCKET_COUNT]; @@ -91,6 +92,7 @@ static void release_ctx(struct nrf_sock_ctx *ctx) ctx->nrf_fd = -1; ctx->lock = NULL; ctx->zvfs_fd = -1; + memset(&ctx->pollcb, 0, sizeof(ctx->pollcb)); memset(&ctx->sendcb, 0, sizeof(ctx->sendcb)); k_mutex_unlock(&ctx_lock); @@ -245,6 +247,9 @@ static int z_to_nrf_optname(int z_in_level, int z_in_optname, case SO_SENDCB: *nrf_out_optname = NRF_SO_SENDCB; break; + case SO_POLLCB: + *nrf_out_optname = NRF_SO_POLLCB; + break; default: retval = -1; break; @@ -520,6 +525,27 @@ static void sendcb(const struct nrf_modem_sendcb_params *nrf_params) ctx->sendcb.callback(¶ms); } +static void pollcb(struct nrf_pollfd *pollfd) +{ + struct nrf_sock_ctx *ctx; + struct socket_ncs_pollcb_params params; + + ctx = find_ctx(pollfd->fd); + if (!ctx || !ctx->pollcb.callback) { + return; + } + + params.fd = ctx->zvfs_fd; + params.events = ctx->pollcb.events; + params.revents = pollfd->revents; + + ctx->pollcb.callback(¶ms); + + if (ctx->pollcb.oneshot) { + memset(&ctx->pollcb, 0, sizeof(ctx->pollcb)); + } +} + static int nrf9x_socket_offload_setsockopt(void *obj, int level, int optname, const void *optval, net_socklen_t optlen) { @@ -535,6 +561,9 @@ static int nrf9x_socket_offload_setsockopt(void *obj, int level, int optname, static struct nrf_modem_sendcb offload_sendcb = { .callback = sendcb, }; + static struct nrf_modem_pollcb offload_pollcb = { + .callback = pollcb, + }; if ((level == ZSOCK_SOL_SOCKET) && (optname == ZSOCK_SO_BINDTODEVICE)) { if (IS_ENABLED(CONFIG_NET_SOCKETS_OFFLOAD_DISPATCHER)) { @@ -572,6 +601,24 @@ static int nrf9x_socket_offload_setsockopt(void *obj, int level, int optname, } else { memset(&ctx->sendcb, 0, sizeof(ctx->sendcb)); } + } else if ((level == ZSOCK_SOL_SOCKET) && (optname == SO_POLLCB)) { + if (optval != NULL) { + const struct socket_ncs_pollcb *pollcb_opt = optval; + + if (optlen != sizeof(struct socket_ncs_pollcb) || + !pollcb_opt->callback) { + errno = EINVAL; + return -1; + } + + ctx->pollcb = *pollcb_opt; + offload_pollcb.events = pollcb_opt->events; + offload_pollcb.oneshot = pollcb_opt->oneshot; + nrf_optval = &offload_pollcb; + nrf_optlen = sizeof(offload_pollcb); + } else { + memset(&ctx->pollcb, 0, sizeof(ctx->pollcb)); + } } retval = nrf_setsockopt(sd, nrf_level, nrf_optname, nrf_optval, @@ -916,7 +963,7 @@ static int nrf9x_socket_offload_fcntl(int fd, int cmd, va_list args) return retval; } -static void pollcb(struct nrf_pollfd *pollfd) +static void pollcb_internal(struct nrf_pollfd *pollfd) { struct nrf_sock_ctx *ctx; @@ -936,7 +983,7 @@ static int nrf9x_poll_prepare(struct nrf_sock_ctx *ctx, struct zsock_pollfd *pfd unsigned int signaled; int fd = OBJ_TO_SD(ctx); struct nrf_modem_pollcb pcb = { - .callback = pollcb, + .callback = pollcb_internal, .events = pfd->events, .oneshot = true, /* callback invoked only once */ }; @@ -949,6 +996,9 @@ static int nrf9x_poll_prepare(struct nrf_sock_ctx *ctx, struct zsock_pollfd *pfd k_poll_signal_init(&ctx->poll); k_poll_event_init(*pev, K_POLL_TYPE_SIGNAL, K_POLL_MODE_NOTIFY_ONLY, &ctx->poll); + /* Remove any application-defined poll callbacks, as it will be overwritten in the modem. */ + memset(&ctx->pollcb, 0, sizeof(ctx->pollcb)); + err = nrf_setsockopt(fd, NRF_SOL_SOCKET, NRF_SO_POLLCB, &pcb, sizeof(pcb)); if (err) { return -1; diff --git a/west.yml b/west.yml index 75ded8f994a6..0540226aa473 100644 --- a/west.yml +++ b/west.yml @@ -65,7 +65,7 @@ manifest: # https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/guides/modules.html - name: zephyr repo-path: sdk-zephyr - revision: cea63b3906540b754e4392f178b6edf73dd34251 + revision: 44eb15e8155448b603bd1ec654d692e1d1557244 import: # In addition to the zephyr repository itself, NCS also # imports the contents of zephyr/west.yml at the above From e87269d26ea3d52b877ea3c6c3d935074a68b3f8 Mon Sep 17 00:00:00 2001 From: Uma Praseeda Date: Tue, 24 Feb 2026 16:02:57 +0100 Subject: [PATCH 12/37] doc: Theme preview New theme changes Signed-off-by: Uma Praseeda --- CODEOWNERS | 1 + doc/_doxygen/doxygen-awesome.css | 145 ++++++++++++++++++++++------- doc/_doxygen/logo.png | Bin 4338 -> 20890 bytes doc/_doxygen/search.html | 14 +++ doc/_static/css/kconfig.css | 37 +++++++- doc/_static/css/matter.css | 3 + doc/_static/css/nrf.css | 1 + doc/_static/css/zephyr.css | 13 +++ doc/kconfig/conf.py | 3 +- doc/matter/conf.py | 2 + doc/mcuboot/conf.py | 3 + doc/nrf/conf.py | 3 +- doc/nrfxlib/conf.py | 3 +- doc/requirements.txt | 3 +- doc/tfm/conf.py | 2 + doc/zephyr/conf.py | 2 + scripts/ci/license_allow_list.yaml | 4 +- 17 files changed, 198 insertions(+), 41 deletions(-) create mode 100644 doc/_doxygen/search.html diff --git a/CODEOWNERS b/CODEOWNERS index 7f16196c1853..50ca1c628be0 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -68,6 +68,7 @@ # All doc related files /doc/_zoomin/ @nrfconnect/ncs-co-doc @nrfconnect/ncs-doc-leads +/doc/_doxygen/ @nrfconnect/ncs-co-doc @nrfconnect/ncs-doc-leads /doc/_extensions/ @nrfconnect/ncs-co-doc @nrfconnect/ncs-doc-leads /doc/kconfig/ @nrfconnect/ncs-doc-leads /doc/matter/ @nrfconnect/ncs-matter-doc diff --git a/doc/_doxygen/doxygen-awesome.css b/doc/_doxygen/doxygen-awesome.css index a2715e268c55..532d6122bd24 100644 --- a/doc/_doxygen/doxygen-awesome.css +++ b/doc/_doxygen/doxygen-awesome.css @@ -29,17 +29,21 @@ SOFTWARE. html { /* primary theme color. This will affect the entire websites color scheme: links, arrows, labels, ... */ - --primary-color: #1779c4; - --primary-dark-color: #335c80; - --primary-light-color: #70b1e9; + + --primary-color: #00a9ce; + --primary-dark-color: #0056b3; + --primary-light-color: #5cc8e0; /* page base colors */ --page-background-color: #ffffff; - --page-foreground-color: #2f4153; - --page-secondary-foreground-color: #6f7e8e; + --page-foreground-color: #323e48; + --page-secondary-foreground-color: #6b7280; /* color for all separators on the website: hr, borders, ... */ - --separator-color: #dedede; + --separator-color: #e2e8f0; + --font-family: "Noto Sans", Carlito, sans-serif; + --font-family-monospace: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; + /* border radius for all rounded components. Will affect many components, like dropdowns, memitems, codeblocks, ... */ --border-radius-large: 8px; @@ -64,14 +68,13 @@ html { --font-family-monospace: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace; /* font sizes */ - --page-font-size: 15.6px; + --page-font-size: 16px; --navigation-font-size: 14.4px; --toc-font-size: 13.4px; - --code-font-size: 14px; /* affects code, fragment */ --title-font-size: 22px; /* content text properties. These only affect the page content, not the navigation or any other ui elements */ - --content-line-height: 27px; + --content-line-height: 23px; /* The content is centered and constraint in it's width. To make the content fill the whole page, set the variable to auto.*/ --content-maxwidth: 1050px; --table-line-height: 24px; @@ -84,7 +87,7 @@ html { --warning-color-dark: #f3a600; --warning-color-darker: #5f4204; --note-color: #e4f3ff; - --note-color-dark: #1879C4; + --note-color-dark: #00a9ce; --note-color-darker: #274a5c; --todo-color: #e4dafd; --todo-color-dark: #5b2bdd; @@ -104,8 +107,9 @@ html { --blockquote-foreground: #636568; /* table colors */ - --tablehead-background: #f1f1f1; - --tablehead-foreground: var(--page-foreground-color); + + --tablehead-background: #eaeded; + --tablehead-foreground: #333f48; /* menu-display: block | none * Visibility of the top navigation on screens >= 768px. On smaller screen the menu is always visible. @@ -113,8 +117,8 @@ html { */ --menu-display: block; - --menu-focus-foreground: var(--page-background-color); - --menu-focus-background: var(--primary-color); + --menu-focus-foreground: #0033a0; + --menu-focus-background: #e0f4f9; --menu-selected-background: rgba(0,0,0,.05); @@ -122,16 +126,37 @@ html { --header-foreground: var(--page-foreground-color); /* searchbar colors */ - --searchbar-background: var(--side-nav-background); - --searchbar-foreground: var(--page-foreground-color); + --searchbar-background: #ffffff; + --searchbar-foreground: #666f7b; /* searchbar size * (`searchbar-width` is only applied on screens >= 768px. * on smaller screens the searchbar will always fill the entire screen width) */ - --searchbar-height: 33px; - --searchbar-width: 210px; - --searchbar-border-radius: var(--searchbar-height); + --searchbar-height: 36px; + --searchbar-width: 100%; + max-width: none; + --searchbar-border-radius: 4px; + /* Nordic-like search (see sphinx nordic .ncs-search-input) */ +#MSearchBox { + background: #ffffff !important; + border: 1px solid rgba(0, 0, 0, 0.08) !important; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06) !important; + border-radius: 4px !important; +} + +#MSearchBox.MSearchBoxActive { + border-color: #00a9ce !important; + box-shadow: 0 0 0 1px #00a9ce !important; +} + +#MSearchField { + color: #666f7b !important; +} +#MSearchField::placeholder { + color: #666f7b !important; + opacity: 1; +} /* code block colors */ --code-background: #f5f5f5; --code-foreground: var(--page-foreground-color); @@ -144,7 +169,7 @@ html { --fragment-keywordflow: #d67c3b; --fragment-token: #438a59; --fragment-comment: #969696; - --fragment-link: #5383d6; + --fragment-link: #00a9ce; --fragment-preprocessor: #46aaa5; --fragment-linenumber-color: #797979; --fragment-linenumber-background: #f4f4f5; @@ -152,7 +177,8 @@ html { --fragment-lineheight: 20px; /* sidebar navigation (treeview) colors */ - --side-nav-background: #fbfbfb; + + --side-nav-background: #ffffff; --side-nav-foreground: var(--page-foreground-color); --side-nav-arrow-opacity: 0; --side-nav-arrow-hover-opacity: 0.9; @@ -347,7 +373,7 @@ a.anchor { */ #top { - background: var(--header-background); + background:#333f48;; border-bottom: 1px solid var(--separator-color); } @@ -363,14 +389,16 @@ a.anchor { #main-nav { flex-grow: 5; padding: var(--spacing-small) var(--spacing-medium); + margin-bottom: 18px; } #titlearea { width: auto; - padding: var(--spacing-medium) var(--spacing-large); + /* padding: var(--spacing-medium) var(--spacing-large); */ background: none; color: var(--header-foreground); border-bottom: none; + padding: 0px 15px 23px 16px; } @media screen and (max-width: 767px) { @@ -386,6 +414,7 @@ a.anchor { #projectname { font-size: var(--title-font-size); font-weight: 600; + color: white; } #projectnumber { @@ -405,6 +434,9 @@ a.anchor { #projectlogo img { max-height: calc(var(--title-font-size) * 2); margin-right: var(--spacing-small); + max-height: 93px; + width: auto; + max-width: 200px; } .sm-dox, .tabs, .tabs2, .tabs3 { @@ -416,7 +448,24 @@ a.anchor { border-bottom: 1px solid var(--separator-color); margin-bottom: -1px; } - +li#searchBoxPos2 { + right: 1.5rem; +} +doxygen-awesome-dark-mode-toggle svg { + color: #ffffff; + } + + doxygen-awesome-dark-mode-toggle svg path, + doxygen-awesome-dark-mode-toggle svg circle, + doxygen-awesome-dark-mode-toggle svg line, + doxygen-awesome-dark-mode-toggle svg g { + fill: #ffffff !important; + stroke: #ffffff !important; + } + doxygen-awesome-dark-mode-toggle svg { + transform: scale(0.75); /* try 0.65–0.9 */ + transform-origin: center; + } .main-menu-btn-icon, .main-menu-btn-icon:before, .main-menu-btn-icon:after { background: var(--page-secondary-foreground-color); } @@ -432,9 +481,11 @@ a.anchor { } #main-menu a.has-submenu:hover span.sub-arrow { - color: var(--page-foreground-color); + border-color: #0033a0 transparent transparent transparent; + color: #0033a0; + } } -} + @media screen and (min-width: 768px) { .sm-dox li, .tablist li { @@ -446,7 +497,8 @@ a.anchor { } .sm-dox a:hover span.sub-arrow { - border-color: var(--menu-focus-foreground) transparent transparent transparent; + border-color: #0033a0 transparent transparent transparent; + color: #0033a0; } .sm-dox ul a span.sub-arrow { @@ -454,10 +506,32 @@ a.anchor { } .sm-dox ul a:hover span.sub-arrow { - border-color: transparent transparent transparent var(--menu-focus-foreground); + border-color: #0033a0 transparent transparent transparent; + color: #0033a0; } -} + } + @media screen and (min-width: 768px) { + /* top row: down-arrow */ + .sm-dox a.highlighted span.sub-arrow, + .sm-dox a[aria-expanded="true"] span.sub-arrow { + border-color: var(--menu-focus-foreground) transparent transparent transparent; + /* or: #0033a0 */ + } + /* submenus: right-arrow */ + .sm-dox ul a.highlighted span.sub-arrow, + .sm-dox ul a[aria-expanded="true"] span.sub-arrow { + border-color: transparent transparent transparent var(--menu-focus-foreground); + } + } + +#MSearchField { + background-image: url(search.svg); + background-repeat: no-repeat; + background-position: 10px center; + background-size: 1rem; + padding-left: 2.25rem !important; +} .sm-dox ul { background: var(--page-background-color); box-shadow: var(--box-shadow); @@ -495,9 +569,10 @@ a.anchor { .sm-dox ul a:hover, .sm-dox ul a:active, .sm-dox ul a:focus { font-size: var(--navigation-font-size) !important; - color: var(--menu-focus-foreground) !important; + /* color: var(--menu-focus-foreground) !important; */ text-shadow: none; - background-color: var(--menu-focus-background); + background-color: #e0f4f9 !important; + color: #0033a0 !important; border-radius: var(--border-radius-small) !important; } @@ -505,7 +580,7 @@ a.anchor { text-shadow: none; background: transparent; background-image: none !important; - color: var(--header-foreground) !important; + color: #ffffff !important; font-weight: normal; font-size: var(--navigation-font-size); border-radius: var(--border-radius-small) !important; @@ -518,10 +593,12 @@ a.anchor { .sm-dox a:hover, .sm-dox a:active, .tablist li a:hover { text-shadow: none; font-weight: normal; - background: var(--menu-focus-background); - color: var(--menu-focus-foreground) !important; + /* background: var(--menu-focus-background); */ + /* color: var(--menu-focus-foreground) !important; */ border-radius: var(--border-radius-small) !important; font-size: var(--navigation-font-size); + background-color: rgb(224, 244, 249) !important; + color: #0033a0 !important; } .tablist li.current { diff --git a/doc/_doxygen/logo.png b/doc/_doxygen/logo.png index 9ebfb7b56fe34f80b39288e2ce7e035deb518702..5cd3c99d3656067d7d7387514c38d56471191df3 100644 GIT binary patch literal 20890 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 VC|=6iy!ncdYnLrh6(;Tv{|DL!s{jB1 literal 4338 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 diff --git a/doc/_doxygen/search.html b/doc/_doxygen/search.html new file mode 100644 index 000000000000..96154ad6f49d --- /dev/null +++ b/doc/_doxygen/search.html @@ -0,0 +1,14 @@ +{% extends "sphinx_rtd_theme/search.html" %} +{% block body %} +

+

Tip

+

+ Search results include entries for all documentation sets. Each search + result entry is prefixed with the name of the documentation set in + which the result is found. For example, the search result + "nRF Connect SDK » Getting started" refers to the Getting Started + page from the "nRF Connect SDK" documentation set. +

+
+ {{ super() }} +{% endblock %} diff --git a/doc/_static/css/kconfig.css b/doc/_static/css/kconfig.css index d48f15b03ea1..2cc3b3409a49 100644 --- a/doc/_static/css/kconfig.css +++ b/doc/_static/css/kconfig.css @@ -11,6 +11,39 @@ dl.kconfig { } div#__kconfig-search .input-container { - border: 2.5px solid rgb(0 0 0 / 60%); - box-shadow: rgb(149 157 165 / 90%) 0px 8px 24px !important; + border: 1px solid rgba(149, 157, 165, 0.2); + margin-bottom: 0.5rem; + width: 100%; + height: 60px; + box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px !important; } +#__kconfig-search .input-container button { + font-size: px; + border-radius: 0px 5px 5px 0px; + float: right; + width: 10%; + height: 100%; + border: none; + background-color: white !important; +} +dl.kconfig dl.field-list { + line-height: 30px !important; + margin-left: -17px; +} +dl.kconfig dl.field-list>dt { + margin-bottom:1em !important; + font: size 14px; +} +#__kconfig-search dl.kconfig dt.sig-object { + background: #e6f6f9; + border-top: 3px solid #00a9ce; + color: #0077c8; + font-size: 14px; + margin: 6px 0; + padding: 6px; + width: fit-content; +} +.kconfig ul { + margin-bottom: 0 !important; + margin-left:0em; +} \ No newline at end of file diff --git a/doc/_static/css/matter.css b/doc/_static/css/matter.css index b069a668ae2e..32cfa0da9602 100644 --- a/doc/_static/css/matter.css +++ b/doc/_static/css/matter.css @@ -4,3 +4,6 @@ border-top: unset; padding-top: unset; } +.rst-content hr { + max-width: 85%; +} \ No newline at end of file diff --git a/doc/_static/css/nrf.css b/doc/_static/css/nrf.css index 83da6e53cc28..602a369ab1c3 100644 --- a/doc/_static/css/nrf.css +++ b/doc/_static/css/nrf.css @@ -107,6 +107,7 @@ color: #000; border-top: none; background: transparent; + max-width: calc(100% - var(--ncs-right-toc-width)); } #versions-select { diff --git a/doc/_static/css/zephyr.css b/doc/_static/css/zephyr.css index 9e46874b61b0..947672ce15e9 100644 --- a/doc/_static/css/zephyr.css +++ b/doc/_static/css/zephyr.css @@ -33,6 +33,7 @@ .grid-item h2 { font-size: 1rem; color: #fff; + max-width: none; } .grid-item img { @@ -47,6 +48,7 @@ .grid-item p { font-size: 0.9rem; margin-top: 0.5rem; + max-width: none; } .grid-icon { @@ -54,3 +56,14 @@ font-size: 3rem; color: white; } +.rst-content .highlight { +background: #f8f9f9!important; +} +.rst-content dl > dt { + margin-left: 0; + max-width: 85%; + } +.rst-content h1 code, .rst-content h1 .literal, .rst-content h1 span.pre { + font-size: 31px; + padding-top: 5px; +} \ No newline at end of file diff --git a/doc/kconfig/conf.py b/doc/kconfig/conf.py index d8e0c21a4e06..042c7fae87b4 100644 --- a/doc/kconfig/conf.py +++ b/doc/kconfig/conf.py @@ -43,7 +43,8 @@ html_theme_options = { "docset": "kconfig", "docsets": utils.ALL_DOCSETS, - "prev_next_buttons_location": None + "prev_next_buttons_location": None, + "logo_url": "https://docs.nordicsemi.com" } # Options for external_content ------------------------------------------------- diff --git a/doc/matter/conf.py b/doc/matter/conf.py index d29b3f8674a0..3b088962e632 100644 --- a/doc/matter/conf.py +++ b/doc/matter/conf.py @@ -49,6 +49,8 @@ "docset": "matter", "docsets": utils.ALL_DOCSETS, "subtitle": "nRF Connect SDK", + "collapse_navigation": False, + "logo_url": "https://docs.nordicsemi.com" } # Options for warnings_filter -------------------------------------------------- diff --git a/doc/mcuboot/conf.py b/doc/mcuboot/conf.py index 13613a1cf3e9..069488315f10 100644 --- a/doc/mcuboot/conf.py +++ b/doc/mcuboot/conf.py @@ -34,6 +34,7 @@ "sphinx.ext.intersphinx", "recommonmark", "sphinx_markdown_tables", + "sphinxcontrib.jquery", "zephyr.external_content" ] source_suffix = [".rst", ".md"] @@ -59,6 +60,8 @@ "docset": "mcuboot", "docsets": utils.ALL_DOCSETS, "subtitle": "nRF Connect SDK", + "collapse_navigation": False, + "logo_url": "https://docs.nordicsemi.com" } # Options for intersphinx ------------------------------------------------------ diff --git a/doc/nrf/conf.py b/doc/nrf/conf.py index a67eee2e7d93..5df30562e8f6 100644 --- a/doc/nrf/conf.py +++ b/doc/nrf/conf.py @@ -57,6 +57,7 @@ "page_filter", "sphinxcontrib.plantuml", "sphinxcontrib.programoutput", + "sphinxcontrib.jquery" ] linkcheck_ignore = [ @@ -91,7 +92,7 @@ html_show_sourcelink = True html_show_sphinx = False -html_theme_options = {"docset": "nrf", "docsets": utils.ALL_DOCSETS} +html_theme_options = {"docset": "nrf", "docsets": utils.ALL_DOCSETS, "logo_url": "https://docs.nordicsemi.com/"} # Options for intersphinx ------------------------------------------------------ diff --git a/doc/nrfxlib/conf.py b/doc/nrfxlib/conf.py index f3bd880df043..b4bfbd09ba25 100644 --- a/doc/nrfxlib/conf.py +++ b/doc/nrfxlib/conf.py @@ -32,6 +32,7 @@ extensions = [ "sphinx.ext.intersphinx", + "sphinxcontrib.jquery", "sphinxcontrib.mscgen", "inventory_builder", "warnings_filter", @@ -59,7 +60,7 @@ html_show_sourcelink = True html_show_sphinx = False -html_theme_options = {"docset": "nrfxlib", "docsets": utils.ALL_DOCSETS} +html_theme_options = {"docset": "nrfxlib", "docsets": utils.ALL_DOCSETS, "logo_url": "https://docs.nordicsemi.com/"} # Options for intersphinx ------------------------------------------------------ diff --git a/doc/requirements.txt b/doc/requirements.txt index 75e3eb13de9f..973430027492 100644 --- a/doc/requirements.txt +++ b/doc/requirements.txt @@ -20,7 +20,7 @@ snowballstemmer<3.0.0 # https://github.com/snowballstem/snowball/issue sphinx>=8.1,<8.2 # | X | X | X | X | X | X | X | sphinx-autobuild # | X | X | X | X | X | X | X | sphinx-copybutton # | X | | | | | | X | -sphinx-ncs-theme<1.1 # | X | | | | | | | +sphinx-ncs-theme<2.1 # | X | | | | | | | sphinx-notfound-page>=1.0.0 # | X | | | | | | X | sphinx-tabs>=3.4 # | X | | | | | | X | sphinx-togglebutton # | X | | | | | | X | @@ -28,6 +28,7 @@ sphinx_markdown_tables # | | | X | | | sphinxcontrib-mscgen # | X | | | | X | | | sphinxcontrib-plantuml>=0.27 # | | | | | | X | | sphinxcontrib-programoutput # | X | | | | | | X | +sphinxcontrib.jquery # | X | | X | X | X | X | | west>=1.0.0 # | | | | | | | X | ply # | | | | | | | X | python-dotenv # | | X | | | | | | diff --git a/doc/tfm/conf.py b/doc/tfm/conf.py index bf8769170a1d..a74daf03c305 100644 --- a/doc/tfm/conf.py +++ b/doc/tfm/conf.py @@ -68,6 +68,8 @@ "docset": "tfm", "docsets": utils.ALL_DOCSETS, "subtitle": "nRF Connect SDK", + "collapse_navigation": False, + "logo_url": "https://docs.nordicsemi.com/" } # Options for autosectionlabel ------------------------------------------------- diff --git a/doc/zephyr/conf.py b/doc/zephyr/conf.py index bcba8e4451c5..7bbdd41eea9e 100644 --- a/doc/zephyr/conf.py +++ b/doc/zephyr/conf.py @@ -59,6 +59,8 @@ "docset": "zephyr", "docsets": utils.ALL_DOCSETS, "subtitle": "nRF Connect SDK", + "collapse_navigation": False, + "logo_url": "https://docs.nordicsemi.com/" } # Options for intersphinx ------------------------------------------------------ diff --git a/scripts/ci/license_allow_list.yaml b/scripts/ci/license_allow_list.yaml index 6d463e7d6af1..ad7328c0a3f9 100644 --- a/scripts/ci/license_allow_list.yaml +++ b/scripts/ci/license_allow_list.yaml @@ -70,7 +70,9 @@ Apache-2.0: | ^nrf/drivers/flash/soc_flash_nrf_non_secure.c ^nrf/applications/nrf_audio/src/modules/audio_usb_init.c curl: "^nrf/ext/" -MIT: "^nrf/ext/" +MIT: | + "^nrf/ext/" + ^nrf/doc/_doxygen/doxygen-awesome.css BSD-3-CLAUSE: | ^nrf/ext/ ^nrf/drivers/wifi/nrf71/ From 9ce2a3842144259c8b5e945f094342a48f43c60a Mon Sep 17 00:00:00 2001 From: Nordic Builder Date: Tue, 12 May 2026 14:12:56 +0000 Subject: [PATCH 13/37] 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/4072 Signed-off-by: Nordic Builder --- west.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/west.yml b/west.yml index 0540226aa473..0560a7c2d33c 100644 --- a/west.yml +++ b/west.yml @@ -65,7 +65,7 @@ manifest: # https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/guides/modules.html - name: zephyr repo-path: sdk-zephyr - revision: 44eb15e8155448b603bd1ec654d692e1d1557244 + revision: 76c2f9407d6caaa66a148321b3618fc8b5f993a6 import: # In addition to the zephyr repository itself, NCS also # imports the contents of zephyr/west.yml at the above From 244f0b4851955e0fc33e533bca0af53564b02e98 Mon Sep 17 00:00:00 2001 From: Jan Tore Guggedal Date: Tue, 19 May 2026 13:39:12 +0200 Subject: [PATCH 14/37] sysbuild: Add PPR core support to nRF9251 nRF9251 has PPR core and this patch adds support to build for it. Signed-off-by: Jan Tore Guggedal --- sysbuild/Kconfig.pprcore | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sysbuild/Kconfig.pprcore b/sysbuild/Kconfig.pprcore index a4f4c4d978a3..b9850f75077b 100644 --- a/sysbuild/Kconfig.pprcore +++ b/sysbuild/Kconfig.pprcore @@ -4,13 +4,13 @@ config SUPPORT_PPRCORE bool - default y if SOC_NRF54H20_CPUAPP + default y if SOC_NRF54H20_CPUAPP || SOC_NRF9251_CPUAPP if SUPPORT_PPRCORE config PPRCORE_REMOTE_BOARD_TARGET_CPUCLUSTER string - default "cpuppr" if SOC_NRF54H20_CPUAPP + default "cpuppr" if SOC_NRF54H20_CPUAPP || SOC_NRF9251_CPUAPP menu "Peripheral processor core (PPR) configuration" depends on SUPPORT_PPRCORE From 177c5e3930495e79d459a7a5f3ab60bcceccc609 Mon Sep 17 00:00:00 2001 From: Herman Berget Date: Tue, 19 May 2026 15:01:42 +0200 Subject: [PATCH 15/37] Bluetooth: Controller: Add Kconfig for data related address changes This command is unused by Zephyr host. Removing it saves NVM size. Applications that call into HCI directly can enable this config. Temporarily enable the config if the host used is unknown. Signed-off-by: Herman Berget --- subsys/bluetooth/controller/Kconfig | 7 +++++++ subsys/bluetooth/controller/hci_internal.c | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/subsys/bluetooth/controller/Kconfig b/subsys/bluetooth/controller/Kconfig index 844c247768fa..ad84b165a546 100644 --- a/subsys/bluetooth/controller/Kconfig +++ b/subsys/bluetooth/controller/Kconfig @@ -734,6 +734,13 @@ config BT_CTLR_SDC_ENABLE_LOWEST_FRAME_SPACE Note: This option forces ACL connections to always use the same TX and RX PHY. +config BT_CTLR_SDC_DATA_RELATED_ADDRESS_CHANGES + bool "Data Related Address Changes" + depends on BT_BROADCASTER + default y if BT_HCI_RAW + help + Support for LE Set Data Related Address Changes command + config BT_CTLR_DTM select EXPERIMENTAL diff --git a/subsys/bluetooth/controller/hci_internal.c b/subsys/bluetooth/controller/hci_internal.c index 291d34f47357..9b520197cee8 100644 --- a/subsys/bluetooth/controller/hci_internal.c +++ b/subsys/bluetooth/controller/hci_internal.c @@ -387,8 +387,10 @@ void hci_internal_supported_commands(sdc_hci_ip_supported_commands_t *cmds) cmds->hci_le_set_advertising_data = 1; cmds->hci_le_set_scan_response_data = 1; cmds->hci_le_set_advertising_enable = 1; +#if defined(CONFIG_BT_CTLR_SDC_DATA_RELATED_ADDRESS_CHANGES) cmds->hci_le_set_data_related_address_changes = 1; #endif +#endif #if defined(CONFIG_BT_OBSERVER) cmds->hci_le_set_scan_parameters = 1; @@ -955,9 +957,11 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, case SDC_HCI_OPCODE_CMD_LE_SET_ADV_ENABLE: return sdc_hci_cmd_le_set_adv_enable((void *)cmd_params); +#if defined(CONFIG_BT_CTLR_SDC_DATA_RELATED_ADDRESS_CHANGES) case SDC_HCI_OPCODE_CMD_LE_SET_DATA_RELATED_ADDRESS_CHANGES: return sdc_hci_cmd_le_set_data_related_address_changes((void *)cmd_params); #endif +#endif #if defined(CONFIG_BT_OBSERVER) case SDC_HCI_OPCODE_CMD_LE_SET_SCAN_PARAMS: From ae4b30b8ccd859b7fc77b3f3312ce67505de2939 Mon Sep 17 00:00:00 2001 From: Herman Berget Date: Tue, 19 May 2026 15:13:41 +0200 Subject: [PATCH 16/37] Bluetooth: Controller: Add Kconfig for RF Path Compensation This command is unused by Zephyr host. Removing it saves NVM size. Applications that call into HCI directly can enable this config. Temporarily enable the config if the host used is unknown. Signed-off-by: Herman Berget --- subsys/bluetooth/controller/Kconfig | 7 +++++++ subsys/bluetooth/controller/hci_internal.c | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/subsys/bluetooth/controller/Kconfig b/subsys/bluetooth/controller/Kconfig index ad84b165a546..2d50ab3818b8 100644 --- a/subsys/bluetooth/controller/Kconfig +++ b/subsys/bluetooth/controller/Kconfig @@ -741,6 +741,13 @@ config BT_CTLR_SDC_DATA_RELATED_ADDRESS_CHANGES help Support for LE Set Data Related Address Changes command +config BT_CTLR_SDC_RF_PATH_COMPENSATION + bool "RF Path Compensation" + depends on BT_CTLR_LE_POWER_CONTROL || BT_CTLR_ADV_EXT + default y if BT_HCI_RAW + help + Support for LE RF Path Compensation + config BT_CTLR_DTM select EXPERIMENTAL diff --git a/subsys/bluetooth/controller/hci_internal.c b/subsys/bluetooth/controller/hci_internal.c index 9b520197cee8..f75a08ffa962 100644 --- a/subsys/bluetooth/controller/hci_internal.c +++ b/subsys/bluetooth/controller/hci_internal.c @@ -575,9 +575,11 @@ void hci_internal_supported_commands(sdc_hci_ip_supported_commands_t *cmds) #endif #if defined(CONFIG_BT_CTLR_LE_POWER_CONTROL) || defined(CONFIG_BT_CTLR_ADV_EXT) +#if defined(CONFIG_BT_CTLR_SDC_RF_PATH_COMPENSATION) cmds->hci_le_read_rf_path_compensation = 1; cmds->hci_le_write_rf_path_compensation = 1; #endif +#endif #if defined(CONFIG_BT_CTLR_SCA_UPDATE) cmds->hci_le_request_peer_sca = 1; @@ -1261,6 +1263,7 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, #endif #if defined(CONFIG_BT_CTLR_LE_POWER_CONTROL) || defined(CONFIG_BT_CTLR_ADV_EXT) +#if defined(CONFIG_BT_CTLR_SDC_RF_PATH_COMPENSATION) case SDC_HCI_OPCODE_CMD_LE_READ_RF_PATH_COMPENSATION: *param_length_out += sizeof(sdc_hci_cmd_le_read_rf_path_compensation_return_t); return sdc_hci_cmd_le_read_rf_path_compensation((void *)event_out_params); @@ -1268,6 +1271,7 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, case SDC_HCI_OPCODE_CMD_LE_WRITE_RF_PATH_COMPENSATION: return sdc_hci_cmd_le_write_rf_path_compensation((void *)cmd_params); #endif +#endif #if defined(CONFIG_BT_CTLR_SYNC_TRANSFER_SENDER) case SDC_HCI_OPCODE_CMD_LE_PERIODIC_ADV_SYNC_TRANSFER: From eec2deeb58e6c5e33c7ae26192e25d326937f955 Mon Sep 17 00:00:00 2001 From: Herman Berget Date: Tue, 19 May 2026 16:14:29 +0200 Subject: [PATCH 17/37] Bluetooth: Controller: Exclude LE Encrypt HCI if !BT_CTLR_CRYPTO This seems to have been missed. If controller crypto is not enabled there is no expectation that the encryption HCI commands work. Signed-off-by: Herman Berget --- subsys/bluetooth/controller/hci_internal.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/subsys/bluetooth/controller/hci_internal.c b/subsys/bluetooth/controller/hci_internal.c index f75a08ffa962..a8dc02ed5577 100644 --- a/subsys/bluetooth/controller/hci_internal.c +++ b/subsys/bluetooth/controller/hci_internal.c @@ -422,7 +422,10 @@ void hci_internal_supported_commands(sdc_hci_ip_supported_commands_t *cmds) cmds->hci_le_read_remote_features = 1; #endif +#if defined(CONFIG_BT_CTLR_CRYPTO) cmds->hci_le_encrypt = 1; +#endif + cmds->hci_le_rand = 1; #if defined(CONFIG_BT_CTLR_LE_ENC) && defined(CONFIG_BT_CENTRAL) @@ -1016,9 +1019,11 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, return sdc_hci_cmd_le_read_remote_features((void *)cmd_params); #endif +#if defined(CONFIG_BT_CTLR_CRYPTO) case SDC_HCI_OPCODE_CMD_LE_ENCRYPT: *param_length_out += sizeof(sdc_hci_cmd_le_encrypt_return_t); return sdc_hci_cmd_le_encrypt((void *)cmd_params, (void *)event_out_params); +#endif case SDC_HCI_OPCODE_CMD_LE_RAND: *param_length_out += sizeof(sdc_hci_cmd_le_rand_return_t); From 3acf7007c9be7a0406b88d32aab0871fca40b743 Mon Sep 17 00:00:00 2001 From: Herman Berget Date: Tue, 19 May 2026 16:22:57 +0200 Subject: [PATCH 18/37] Bluetooth: Controller: Add kconfig for ISO test commands Removing them saves NVM size. Applications that call into HCI directly can enable this config. Temporarily enable the config if the host used is unknown. Signed-off-by: Herman Berget --- subsys/bluetooth/controller/Kconfig | 7 +++++++ subsys/bluetooth/controller/hci_internal.c | 22 ++++++++++++++++++++-- 2 files changed, 27 insertions(+), 2 deletions(-) diff --git a/subsys/bluetooth/controller/Kconfig b/subsys/bluetooth/controller/Kconfig index 2d50ab3818b8..ce314050e06b 100644 --- a/subsys/bluetooth/controller/Kconfig +++ b/subsys/bluetooth/controller/Kconfig @@ -748,6 +748,13 @@ config BT_CTLR_SDC_RF_PATH_COMPENSATION help Support for LE RF Path Compensation +config BT_CTLR_SDC_ISO_TEST + bool "LE ISO Test commands" + depends on BT_CTLR_ISO + default y if BT_HCI_RAW || BT_ISO_TEST_PARAMS + help + Support for LE ISO test HCI commands + config BT_CTLR_DTM select EXPERIMENTAL diff --git a/subsys/bluetooth/controller/hci_internal.c b/subsys/bluetooth/controller/hci_internal.c index a8dc02ed5577..329bb3faff54 100644 --- a/subsys/bluetooth/controller/hci_internal.c +++ b/subsys/bluetooth/controller/hci_internal.c @@ -595,7 +595,9 @@ void hci_internal_supported_commands(sdc_hci_ip_supported_commands_t *cmds) #if defined(CONFIG_BT_CTLR_CENTRAL_ISO) cmds->hci_le_set_cig_parameters = 1; +#if defined(CONFIG_BT_CTLR_SDC_ISO_TEST) cmds->hci_le_set_cig_parameters_test = 1; +#endif cmds->hci_le_create_cis = 1; cmds->hci_le_remove_cig = 1; #endif @@ -609,7 +611,9 @@ void hci_internal_supported_commands(sdc_hci_ip_supported_commands_t *cmds) #if defined(CONFIG_BT_CTLR_ADV_ISO) cmds->hci_le_create_big = 1; +#if defined(CONFIG_BT_CTLR_SDC_ISO_TEST) cmds->hci_le_create_big_test = 1; +#endif cmds->hci_le_terminate_big = 1; #endif @@ -621,18 +625,22 @@ void hci_internal_supported_commands(sdc_hci_ip_supported_commands_t *cmds) #if defined(CONFIG_BT_CTLR_ISO) cmds->hci_le_setup_iso_data_path = 1; cmds->hci_le_remove_iso_data_path = 1; +#if defined(CONFIG_BT_CTLR_SDC_ISO_TEST) cmds->hci_le_iso_test_end = 1; cmds->hci_le_iso_read_test_counters = 1; +#endif cmds->hci_le_read_iso_link_quality = 1; #endif #if defined(CONFIG_BT_CTLR_ISO_TX_BUFFERS) cmds->hci_le_read_buffer_size_v2 = 1; cmds->hci_le_read_iso_tx_sync = 1; +#if defined(CONFIG_BT_CTLR_SDC_ISO_TEST) cmds->hci_le_iso_transmit_test = 1; #endif +#endif -#if defined(CONFIG_BT_CTLR_ISO_RX_BUFFERS) +#if defined(CONFIG_BT_CTLR_ISO_RX_BUFFERS) && defined(CONFIG_BT_CTLR_SDC_ISO_TEST) cmds->hci_le_iso_receive_test = 1; #endif @@ -1341,6 +1349,7 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, return status; } +#if defined(CONFIG_BT_CTLR_SDC_ISO_TEST) case SDC_HCI_OPCODE_CMD_LE_SET_CIG_PARAMS_TEST: { sdc_hci_cmd_le_set_cig_params_test_return_t *p_cig_params_test_ret = (sdc_hci_cmd_le_set_cig_params_test_return_t *)event_out_params; @@ -1355,6 +1364,7 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, return status; } +#endif /* CONFIG_BT_CTLR_SDC_ISO_TEST */ case SDC_HCI_OPCODE_CMD_LE_CREATE_CIS: return sdc_hci_cmd_le_create_cis((sdc_hci_cmd_le_create_cis_t const *)cmd_params); @@ -1380,9 +1390,11 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, #ifdef CONFIG_BT_CTLR_ADV_ISO case SDC_HCI_OPCODE_CMD_LE_CREATE_BIG: return sdc_hci_cmd_le_create_big((sdc_hci_cmd_le_create_big_t const *)cmd_params); +#if defined(CONFIG_BT_CTLR_SDC_ISO_TEST) case SDC_HCI_OPCODE_CMD_LE_CREATE_BIG_TEST: return sdc_hci_cmd_le_create_big_test( (sdc_hci_cmd_le_create_big_test_t const *)cmd_params); +#endif case SDC_HCI_OPCODE_CMD_LE_TERMINATE_BIG: return sdc_hci_cmd_le_terminate_big( (sdc_hci_cmd_le_terminate_big_t const *)cmd_params); @@ -1400,14 +1412,16 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, (sdc_hci_cmd_le_read_iso_tx_sync_t const *)cmd_params, (sdc_hci_cmd_le_read_iso_tx_sync_return_t *)event_out_params); +#if defined(CONFIG_BT_CTLR_SDC_ISO_TEST) case SDC_HCI_OPCODE_CMD_LE_ISO_TRANSMIT_TEST: *param_length_out += sizeof(sdc_hci_cmd_le_iso_transmit_test_return_t); return sdc_hci_cmd_le_iso_transmit_test( (sdc_hci_cmd_le_iso_transmit_test_t const *)cmd_params, (sdc_hci_cmd_le_iso_transmit_test_return_t *)event_out_params); +#endif /* CONFIG_BT_CTLR_SDC_ISO_TEST */ #endif /* CONFIG_BT_CTLR_ISO_TX_BUFFERS */ -#if defined(CONFIG_BT_CTLR_ISO_RX_BUFFERS) +#if defined(CONFIG_BT_CTLR_ISO_RX_BUFFERS) && defined(CONFIG_BT_CTLR_SDC_ISO_TEST) case SDC_HCI_OPCODE_CMD_LE_ISO_RECEIVE_TEST: *param_length_out += sizeof(sdc_hci_cmd_le_iso_receive_test_return_t); return sdc_hci_cmd_le_iso_receive_test( @@ -1416,11 +1430,13 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, #endif #if defined(CONFIG_BT_CTLR_ISO) +#if defined(CONFIG_BT_CTLR_SDC_ISO_TEST) case SDC_HCI_OPCODE_CMD_LE_ISO_READ_TEST_COUNTERS: *param_length_out += sizeof(sdc_hci_cmd_le_iso_read_test_counters_return_t); return sdc_hci_cmd_le_iso_read_test_counters( (sdc_hci_cmd_le_iso_read_test_counters_t const *)cmd_params, (sdc_hci_cmd_le_iso_read_test_counters_return_t *)event_out_params); +#endif /* CONFIG_BT_CTLR_SDC_ISO_TEST */ case SDC_HCI_OPCODE_CMD_LE_SETUP_ISO_DATA_PATH: *param_length_out += sizeof(sdc_hci_cmd_le_setup_iso_data_path_return_t); @@ -1434,11 +1450,13 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, (sdc_hci_cmd_le_remove_iso_data_path_t const *)cmd_params, (sdc_hci_cmd_le_remove_iso_data_path_return_t *)event_out_params); +#if defined(CONFIG_BT_CTLR_SDC_ISO_TEST) case SDC_HCI_OPCODE_CMD_LE_ISO_TEST_END: *param_length_out += sizeof(sdc_hci_cmd_le_iso_test_end_return_t); return sdc_hci_cmd_le_iso_test_end( (sdc_hci_cmd_le_iso_test_end_t const *)cmd_params, (sdc_hci_cmd_le_iso_test_end_return_t *)event_out_params); +#endif /* CONFIG_BT_CTLR_SDC_ISO_TEST */ case SDC_HCI_OPCODE_CMD_LE_READ_ISO_LINK_QUALITY: *param_length_out += sizeof(sdc_hci_cmd_le_read_iso_link_quality_return_t); From 95642f98dfd3b345cc2f5a7690769280dc01aec7 Mon Sep 17 00:00:00 2001 From: Herman Berget Date: Wed, 20 May 2026 14:56:59 +0200 Subject: [PATCH 19/37] Bluetooth: Controller: Ifdef out LE Rand command In configurations where the Zephyr host doesnt call the LE Rand HCI command we can remove it and save some space. Signed-off-by: Herman Berget --- subsys/bluetooth/controller/hci_internal.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/subsys/bluetooth/controller/hci_internal.c b/subsys/bluetooth/controller/hci_internal.c index 329bb3faff54..2660556cb785 100644 --- a/subsys/bluetooth/controller/hci_internal.c +++ b/subsys/bluetooth/controller/hci_internal.c @@ -426,7 +426,9 @@ void hci_internal_supported_commands(sdc_hci_ip_supported_commands_t *cmds) cmds->hci_le_encrypt = 1; #endif +#if !defined(CONFIG_BT_HOST_CRYPTO_PRNG) cmds->hci_le_rand = 1; +#endif #if defined(CONFIG_BT_CTLR_LE_ENC) && defined(CONFIG_BT_CENTRAL) cmds->hci_le_enable_encryption = 1; @@ -1033,9 +1035,11 @@ static uint8_t le_controller_cmd_put(uint8_t const * const cmd, return sdc_hci_cmd_le_encrypt((void *)cmd_params, (void *)event_out_params); #endif +#if !defined(CONFIG_BT_HOST_CRYPTO_PRNG) case SDC_HCI_OPCODE_CMD_LE_RAND: *param_length_out += sizeof(sdc_hci_cmd_le_rand_return_t); return sdc_hci_cmd_le_rand((void *)event_out_params); +#endif #if defined(CONFIG_BT_CENTRAL) case SDC_HCI_OPCODE_CMD_LE_ENABLE_ENCRYPTION: From ef316113f5765ba5b8f14e4cf952d4aeede6d2e4 Mon Sep 17 00:00:00 2001 From: Herman Berget Date: Wed, 20 May 2026 15:06:14 +0200 Subject: [PATCH 20/37] release-notes: Add note about new Kconfig options for SDC Some HCI commands have been moved behind kconfig options. Signed-off-by: Herman Berget --- .../releases/release-notes-changelog.rst | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) 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 03b92cba21da..e0413355f576 100644 --- a/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst +++ b/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst @@ -184,7 +184,11 @@ See `Samples`_ for lists of changes for the protocol-related samples. Bluetooth® LE ------------- -|no_changes_yet_note| +* Added the following Kconfig options to enable support for certain HCI commands: + + * :kconfig:option:`CONFIG_BT_CTLR_SDC_DATA_RELATED_ADDRESS_CHANGES` + * :kconfig:option:`CONFIG_BT_CTLR_SDC_RF_PATH_COMPENSATION` + * :kconfig:option:`CONFIG_BT_CTLR_SDC_ISO_TEST` Bluetooth Mesh -------------- From a334787181b33401b94089d15a4f4eafab0d6326 Mon Sep 17 00:00:00 2001 From: Marek Porwisz Date: Fri, 24 Apr 2026 13:32:35 +0200 Subject: [PATCH 21/37] rpc: samples: Extend verbosity of RPC errors Added support for more detailed RPC error info to the protocol_serialization sample. Updated protocols rpc implementation not to loose the file/line/function info due to the usage of a common error reporting function. Signed-off-by: Marek Porwisz --- .../client/verbose.conf | 1 + .../server/verbose.conf | 1 + .../bluetooth/rpc/client/bt_rpc_conn_client.c | 46 ++++----- .../bluetooth/rpc/client/bt_rpc_gap_client.c | 28 +++--- .../bluetooth/rpc/client/bt_rpc_gatt_client.c | 36 +++---- subsys/bluetooth/rpc/common/bt_rpc_common.h | 4 + subsys/bluetooth/rpc/host/bt_rpc_conn_host.c | 64 ++++++------- .../bluetooth/rpc/host/bt_rpc_crypto_host.c | 16 +--- subsys/bluetooth/rpc/host/bt_rpc_gap_host.c | 96 +++++++++---------- subsys/bluetooth/rpc/host/bt_rpc_gatt_host.c | 50 ++++------ .../bluetooth/rpc/host/bt_rpc_internal_host.c | 10 +- subsys/dm/rpc/common/dm_rpc_common.h | 4 + subsys/dm/rpc/host/dm_rpc_host.c | 10 +- .../net/openthread/rpc/common/ot_rpc_common.c | 10 -- .../net/openthread/rpc/common/ot_rpc_common.h | 7 +- subsys/nfc/rpc/common/nfc_rpc_common.c | 6 -- subsys/nfc/rpc/common/nfc_rpc_common.h | 5 +- west.yml | 2 +- 18 files changed, 169 insertions(+), 227 deletions(-) diff --git a/samples/nrf_rpc/protocols_serialization/client/verbose.conf b/samples/nrf_rpc/protocols_serialization/client/verbose.conf index 3ee3c7d5a414..967bcae5d2f9 100644 --- a/samples/nrf_rpc/protocols_serialization/client/verbose.conf +++ b/samples/nrf_rpc/protocols_serialization/client/verbose.conf @@ -15,3 +15,4 @@ CONFIG_NRF_PS_CLIENT_LOG_LEVEL_DBG=y CONFIG_NRF_RPC_TR_LOG_LEVEL_DBG=y CONFIG_NRF_RPC_LOG_LEVEL_DBG=y CONFIG_NRF_RPC_OS_LOG_LEVEL_DBG=y +CONFIG_NRF_RPC_DETAILED_ERROR_REPORTING=y diff --git a/samples/nrf_rpc/protocols_serialization/server/verbose.conf b/samples/nrf_rpc/protocols_serialization/server/verbose.conf index 0610b2f356a1..13841f726e2b 100644 --- a/samples/nrf_rpc/protocols_serialization/server/verbose.conf +++ b/samples/nrf_rpc/protocols_serialization/server/verbose.conf @@ -21,3 +21,4 @@ CONFIG_NRF_PS_SERVER_LOG_LEVEL_DBG=y CONFIG_NRF_RPC_TR_LOG_LEVEL_DBG=y CONFIG_NRF_RPC_LOG_LEVEL_DBG=y CONFIG_NRF_RPC_OS_LOG_LEVEL_DBG=y +CONFIG_NRF_RPC_DETAILED_ERROR_REPORTING=y diff --git a/subsys/bluetooth/rpc/client/bt_rpc_conn_client.c b/subsys/bluetooth/rpc/client/bt_rpc_conn_client.c index bc4d6de389d1..349caaf18d6a 100644 --- a/subsys/bluetooth/rpc/client/bt_rpc_conn_client.c +++ b/subsys/bluetooth/rpc/client/bt_rpc_conn_client.c @@ -13,12 +13,6 @@ #include #include -static void report_decoding_error(uint8_t cmd_evt_id, void *data) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - #define LOCK_CONN_INFO() k_mutex_lock(&bt_rpc_conn_mutex, K_FOREVER) #define UNLOCK_CONN_INFO() k_mutex_unlock(&bt_rpc_conn_mutex) @@ -141,7 +135,7 @@ static void bt_conn_foreach_cb_callback_rpc_handler(const struct nrf_rpc_group * return; decoding_error: - report_decoding_error(BT_CONN_FOREACH_CB_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_FOREACH_CB_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_foreach_cb_callback, @@ -720,7 +714,7 @@ static void bt_conn_cb_connected_call_rpc_handler(const struct nrf_rpc_group *gr return; decoding_error: - report_decoding_error(BT_CONN_CB_CONNECTED_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_CB_CONNECTED_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_cb_connected_call, BT_CONN_CB_CONNECTED_CALL_RPC_CMD, @@ -763,7 +757,7 @@ static void bt_conn_cb_disconnected_call_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_CONN_CB_DISCONNECTED_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_CB_DISCONNECTED_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_cb_disconnected_call, @@ -846,7 +840,7 @@ static void bt_conn_cb_le_param_req_call_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_CONN_CB_LE_PARAM_REQ_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_CB_LE_PARAM_REQ_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_cb_le_param_req_call, @@ -895,7 +889,7 @@ static void bt_conn_cb_le_param_updated_call_rpc_handler(const struct nrf_rpc_gr return; decoding_error: - report_decoding_error(BT_CONN_CB_LE_PARAM_UPDATED_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_CB_LE_PARAM_UPDATED_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_cb_le_param_updated_call, @@ -945,7 +939,7 @@ static void bt_conn_cb_identity_resolved_call_rpc_handler(const struct nrf_rpc_g return; decoding_error: - report_decoding_error(BT_CONN_CB_IDENTITY_RESOLVED_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_CB_IDENTITY_RESOLVED_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_cb_identity_resolved_call, @@ -994,7 +988,7 @@ static void bt_conn_cb_security_changed_call_rpc_handler(const struct nrf_rpc_gr return; decoding_error: - report_decoding_error(BT_CONN_CB_SECURITY_CHANGED_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_CB_SECURITY_CHANGED_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_cb_security_changed_call, @@ -1043,7 +1037,7 @@ static void bt_conn_cb_remote_info_available_call_rpc_handler(const struct nrf_r return; decoding_error: - report_decoding_error(BT_CONN_CB_REMOTE_INFO_AVAILABLE_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_CB_REMOTE_INFO_AVAILABLE_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_cb_remote_info_available_call, @@ -1089,7 +1083,7 @@ static void bt_conn_cb_le_phy_updated_call_rpc_handler(const struct nrf_rpc_grou return; decoding_error: - report_decoding_error(BT_CONN_CB_LE_PHY_UPDATED_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_CB_LE_PHY_UPDATED_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_cb_le_phy_updated_call, @@ -1136,7 +1130,7 @@ static void bt_conn_cb_le_data_len_updated_call_rpc_handler(const struct nrf_rpc return; decoding_error: - report_decoding_error(BT_CONN_CB_LE_DATA_LEN_UPDATED_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_CB_LE_DATA_LEN_UPDATED_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_cb_le_data_len_updated_call, @@ -1448,7 +1442,7 @@ static void bt_rpc_auth_cb_pairing_accept_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_RPC_AUTH_CB_PAIRING_ACCEPT_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_CB_PAIRING_ACCEPT_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_cb_pairing_accept, @@ -1478,7 +1472,7 @@ static void bt_rpc_auth_cb_passkey_display_rpc_handler(const struct nrf_rpc_grou return; decoding_error: - report_decoding_error(BT_RPC_AUTH_CB_PASSKEY_DISPLAY_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_CB_PASSKEY_DISPLAY_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_cb_passkey_display, @@ -1505,7 +1499,7 @@ static void bt_rpc_auth_cb_passkey_entry_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_RPC_AUTH_CB_PASSKEY_ENTRY_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_CB_PASSKEY_ENTRY_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_cb_passkey_entry, @@ -1534,7 +1528,7 @@ static void bt_rpc_auth_cb_passkey_confirm_rpc_handler(const struct nrf_rpc_grou return; decoding_error: - report_decoding_error(BT_RPC_AUTH_CB_PASSKEY_CONFIRM_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_CB_PASSKEY_CONFIRM_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_cb_passkey_confirm, @@ -1564,7 +1558,7 @@ static void bt_rpc_auth_cb_oob_data_request_rpc_handler(const struct nrf_rpc_gro return; decoding_error: - report_decoding_error(BT_RPC_AUTH_CB_OOB_DATA_REQUEST_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_CB_OOB_DATA_REQUEST_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_cb_oob_data_request, @@ -1590,7 +1584,7 @@ static void bt_rpc_auth_cb_cancel_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_RPC_AUTH_CB_CANCEL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_CB_CANCEL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_cb_cancel, BT_RPC_AUTH_CB_CANCEL_RPC_CMD, @@ -1616,7 +1610,7 @@ static void bt_rpc_auth_cb_pairing_confirm_rpc_handler(const struct nrf_rpc_grou return; decoding_error: - report_decoding_error(BT_RPC_AUTH_CB_PAIRING_CONFIRM_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_CB_PAIRING_CONFIRM_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_cb_pairing_confirm, @@ -1694,7 +1688,7 @@ static void bt_rpc_auth_info_cb_bond_deleted_rpc_handler(const struct nrf_rpc_gr nrf_rpc_rsp_send_void(group); decoding_error: - report_decoding_error(BT_RPC_AUTH_INFO_CB_BOND_DELETED_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_INFO_CB_BOND_DELETED_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_info_cb_bond_deleted, @@ -1726,7 +1720,7 @@ static void bt_rpc_auth_info_cb_pairing_complete_rpc_handler(const struct nrf_rp return; decoding_error: - report_decoding_error(BT_RPC_AUTH_INFO_CB_PAIRING_COMPLETE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_INFO_CB_PAIRING_COMPLETE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_info_cb_pairing_complete, @@ -1758,7 +1752,7 @@ static void bt_rpc_auth_info_cb_pairing_failed_rpc_handler(const struct nrf_rpc_ return; decoding_error: - report_decoding_error(BT_RPC_AUTH_INFO_CB_PAIRING_FAILED_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_AUTH_INFO_CB_PAIRING_FAILED_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_auth_info_cb_pairing_failed, diff --git a/subsys/bluetooth/rpc/client/bt_rpc_gap_client.c b/subsys/bluetooth/rpc/client/bt_rpc_gap_client.c index 65f05f4b127b..788cb070cd31 100644 --- a/subsys/bluetooth/rpc/client/bt_rpc_gap_client.c +++ b/subsys/bluetooth/rpc/client/bt_rpc_gap_client.c @@ -22,12 +22,6 @@ LOG_MODULE_DECLARE(BT_RPC, CONFIG_BT_RPC_LOG_LEVEL); -static void report_decoding_error(uint8_t cmd_evt_id, void *data) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - struct bt_rpc_get_check_list_rpc_res { size_t size; uint8_t *data; @@ -96,7 +90,7 @@ static void bt_ready_cb_t_callback_rpc_handler(const struct nrf_rpc_group *group return; decoding_error: - report_decoding_error(BT_READY_CB_T_CALLBACK_RPC_EVT, handler_data); + bt_rpc_report_decoding_error(BT_READY_CB_T_CALLBACK_RPC_EVT); } NRF_RPC_CBOR_EVT_DECODER(bt_rpc_grp, bt_ready_cb_t_callback, BT_READY_CB_T_CALLBACK_RPC_EVT, @@ -516,7 +510,7 @@ static void bt_le_scan_cb_t_callback_rpc_handler(const struct nrf_rpc_group *gro return; decoding_error: - report_decoding_error(BT_LE_SCAN_CB_T_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_SCAN_CB_T_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_scan_cb_t_callback, BT_LE_SCAN_CB_T_CALLBACK_RPC_CMD, @@ -693,7 +687,7 @@ static void bt_le_ext_adv_cb_sent_callback_rpc_handler(const struct nrf_rpc_grou return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_CB_SENT_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_CB_SENT_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_cb_sent_callback, @@ -729,7 +723,7 @@ static void bt_le_ext_adv_cb_connected_callback_rpc_handler(const struct nrf_rpc return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_CB_CONNECTED_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_CB_CONNECTED_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_cb_connected_callback, @@ -762,7 +756,7 @@ static void bt_le_ext_adv_cb_scanned_callback_rpc_handler(const struct nrf_rpc_g return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_CB_SCANNED_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_CB_SCANNED_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_cb_scanned_callback, @@ -1448,7 +1442,7 @@ static void per_adv_sync_cb_synced_rpc_handler(const struct nrf_rpc_group *group return; decoding_error: - report_decoding_error(PER_ADV_SYNC_CB_SYNCED_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(PER_ADV_SYNC_CB_SYNCED_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, per_adv_sync_cb_synced, PER_ADV_SYNC_CB_SYNCED_RPC_CMD, @@ -1515,7 +1509,7 @@ static void per_adv_sync_cb_term_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(PER_ADV_SYNC_CB_TERM_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(PER_ADV_SYNC_CB_TERM_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, per_adv_sync_cb_term, PER_ADV_SYNC_CB_TERM_RPC_CMD, @@ -1561,7 +1555,7 @@ static void per_adv_sync_cb_recv_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(PER_ADV_SYNC_CB_RECV_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(PER_ADV_SYNC_CB_RECV_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, per_adv_sync_cb_recv, PER_ADV_SYNC_CB_RECV_RPC_CMD, @@ -1599,7 +1593,7 @@ static void per_adv_sync_cb_state_changed_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(PER_ADV_SYNC_CB_STATE_CHANGED_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(PER_ADV_SYNC_CB_STATE_CHANGED_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, per_adv_sync_cb_state_changed, @@ -1693,7 +1687,7 @@ static void bt_le_scan_cb_recv_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_SCAN_CB_RECV_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_SCAN_CB_RECV_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_scan_cb_recv, BT_LE_SCAN_CB_RECV_RPC_CMD, @@ -1993,7 +1987,7 @@ static void bt_foreach_bond_cb_callback_rpc_handler(const struct nrf_rpc_group * return; decoding_error: - report_decoding_error(BT_FOREACH_BOND_CB_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_FOREACH_BOND_CB_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_foreach_bond_cb_callback, diff --git a/subsys/bluetooth/rpc/client/bt_rpc_gatt_client.c b/subsys/bluetooth/rpc/client/bt_rpc_gatt_client.c index c429e8a42abf..92b1b9f6ef93 100644 --- a/subsys/bluetooth/rpc/client/bt_rpc_gatt_client.c +++ b/subsys/bluetooth/rpc/client/bt_rpc_gatt_client.c @@ -82,12 +82,6 @@ const struct bt_gatt_attr *bt_rpc_decode_gatt_attr(struct nrf_rpc_cbor_ctx *ctx) return bt_rpc_gatt_index_to_attr(attr_index); } -static void report_decoding_error(uint8_t cmd_evt_id, void *data) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - ssize_t bt_gatt_attr_read(struct bt_conn *conn, const struct bt_gatt_attr *attr, void *buf, uint16_t buf_len, uint16_t offset, const void *value, uint16_t value_len) @@ -129,7 +123,7 @@ static void bt_gatt_complete_func_t_callback_rpc_handler(const struct nrf_rpc_gr return; decoding_error: - report_decoding_error(BT_GATT_COMPLETE_FUNC_T_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_COMPLETE_FUNC_T_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_complete_func_t_callback, @@ -167,7 +161,7 @@ static void bt_rpc_gatt_ccc_cfg_changed_cb_rpc_handler(const struct nrf_rpc_grou return; decoding_error: - report_decoding_error(BT_RPC_GATT_CB_CCC_CFG_CHANGED_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_CB_CCC_CFG_CHANGED_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_gatt_ccc_cfg_changed_cb, @@ -208,7 +202,7 @@ static void bt_rpc_gatt_ccc_cfg_write_cb_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_RPC_GATT_CB_CCC_CFG_WRITE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_CB_CCC_CFG_WRITE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_gatt_ccc_cfg_write_cb, @@ -247,7 +241,7 @@ static void bt_rpc_gatt_ccc_cfg_match_cb_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_RPC_GATT_CB_CCC_CFG_MATCH_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_CB_CCC_CFG_MATCH_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_gatt_ccc_cfg_match_cb, @@ -305,7 +299,7 @@ static void bt_rpc_gatt_attr_read_cb_rpc_handler(const struct nrf_rpc_group *gro return; decoding_error: - report_decoding_error(BT_RPC_GATT_CB_ATTR_READ_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_CB_ATTR_READ_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_gatt_attr_read_cb, BT_RPC_GATT_CB_ATTR_READ_RPC_CMD, @@ -351,7 +345,7 @@ static void bt_rpc_gatt_attr_write_cb_rpc_handler(const struct nrf_rpc_group *gr return; decoding_error: - report_decoding_error(BT_RPC_GATT_CB_ATTR_WRITE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_CB_ATTR_WRITE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_gatt_attr_write_cb, BT_RPC_GATT_CB_ATTR_WRITE_RPC_CMD, @@ -904,7 +898,7 @@ static void bt_gatt_indicate_func_t_callback_rpc_handler(const struct nrf_rpc_gr return; decoding_error: - report_decoding_error(BT_GATT_INDICATE_FUNC_T_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_INDICATE_FUNC_T_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_indicate_func_t_callback, @@ -931,7 +925,7 @@ static void bt_gatt_indicate_params_destroy_t_callback_rpc_handler( return; decoding_error: - report_decoding_error(BT_GATT_INDICATE_PARAMS_DESTROY_T_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_INDICATE_PARAMS_DESTROY_T_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_indicate_params_destroy_t_callback, @@ -998,7 +992,7 @@ static void bt_gatt_exchange_mtu_callback_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_GATT_EXCHANGE_MTU_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_EXCHANGE_MTU_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_exchange_mtu_callback, @@ -1156,7 +1150,7 @@ static void bt_gatt_cb_att_mtu_update_call_rpc_handler(const struct nrf_rpc_grou return; decoding_error: - report_decoding_error(BT_GATT_CB_ATT_MTU_UPDATE_CALL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_CB_ATT_MTU_UPDATE_CALL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_cb_att_mtu_update_call, @@ -1264,7 +1258,7 @@ static void bt_gatt_discover_callback_rpc_handler(const struct nrf_rpc_group *gr decoding_done_with_error: nrf_rpc_decoding_done_and_check(group, ctx); decoding_error: - report_decoding_error(BT_GATT_DISCOVER_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_DISCOVER_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_discover_callback, BT_GATT_DISCOVER_CALLBACK_RPC_CMD, @@ -1351,7 +1345,7 @@ static void bt_gatt_read_callback_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_GATT_READ_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_READ_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_read_callback, BT_GATT_READ_CALLBACK_RPC_CMD, @@ -1409,7 +1403,7 @@ static void bt_gatt_write_callback_rpc_handler(const struct nrf_rpc_group *group return; decoding_error: - report_decoding_error(BT_GATT_WRITE_CALLBACK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_WRITE_CALLBACK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_write_callback, BT_GATT_WRITE_CALLBACK_RPC_CMD, @@ -1602,7 +1596,7 @@ static void bt_gatt_subscribe_params_notify_rpc_handler(const struct nrf_rpc_gro return; decoding_error: - report_decoding_error(BT_GATT_SUBSCRIBE_PARAMS_NOTIFY_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_SUBSCRIBE_PARAMS_NOTIFY_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_subscribe_params_notify, @@ -1648,7 +1642,7 @@ static void bt_gatt_subscribe_params_subscribe_rpc_handler(const struct nrf_rpc_ return; decoding_error: - report_decoding_error(BT_GATT_SUBSCRIBE_PARAMS_SUBSCRIBE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_SUBSCRIBE_PARAMS_SUBSCRIBE_RPC_CMD); } diff --git a/subsys/bluetooth/rpc/common/bt_rpc_common.h b/subsys/bluetooth/rpc/common/bt_rpc_common.h index b3a2519ddcaf..c13362d0a138 100644 --- a/subsys/bluetooth/rpc/common/bt_rpc_common.h +++ b/subsys/bluetooth/rpc/common/bt_rpc_common.h @@ -292,4 +292,8 @@ struct bt_conn *bt_rpc_decode_bt_conn(struct nrf_rpc_cbor_ctx *ctx); NRF_RPC_CBKPROXY_HANDLER_DECL(bt_gatt_complete_func_t_encoder, (struct bt_conn *conn, void *user_data), (conn, user_data)); +#define bt_rpc_report_decoding_error(cmd_evt_id) \ + nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, \ + NRF_RPC_PACKET_TYPE_CMD) + #endif /* BT_RPC_COMMON_H_ */ diff --git a/subsys/bluetooth/rpc/host/bt_rpc_conn_host.c b/subsys/bluetooth/rpc/host/bt_rpc_conn_host.c index fda93350d504..2b2692ad5d23 100644 --- a/subsys/bluetooth/rpc/host/bt_rpc_conn_host.c +++ b/subsys/bluetooth/rpc/host/bt_rpc_conn_host.c @@ -19,12 +19,6 @@ LOG_MODULE_DECLARE(BT_RPC, CONFIG_BT_RPC_LOG_LEVEL); -static void report_decoding_error(uint8_t cmd_evt_id, void *data) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - void bt_rpc_encode_bt_conn(struct nrf_rpc_cbor_ctx *encoder, const struct bt_conn *conn) { @@ -83,7 +77,7 @@ static void bt_conn_remote_update_ref_rpc_handler(const struct nrf_rpc_group *gr return; decoding_error: - report_decoding_error(BT_CONN_REMOTE_UPDATE_REF_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_REMOTE_UPDATE_REF_RPC_CMD); } @@ -130,7 +124,7 @@ static void bt_conn_foreach_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_FOREACH_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_FOREACH_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_foreach, BT_CONN_FOREACH_RPC_CMD, @@ -167,7 +161,7 @@ static void bt_conn_lookup_addr_le_rpc_handler(const struct nrf_rpc_group *group return; decoding_error: - report_decoding_error(BT_CONN_LOOKUP_ADDR_LE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_LOOKUP_ADDR_LE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_lookup_addr_le, BT_CONN_LOOKUP_ADDR_LE_RPC_CMD, @@ -206,7 +200,7 @@ static void bt_conn_get_dst_out_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_GET_DST_OUT_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_GET_DST_OUT_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_get_dst_out, BT_CONN_GET_DST_OUT_RPC_CMD, @@ -332,7 +326,7 @@ static void bt_conn_get_info_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_GET_INFO_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_GET_INFO_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_get_info, BT_CONN_GET_INFO_RPC_CMD, @@ -395,7 +389,7 @@ static void bt_conn_get_remote_info_rpc_handler(const struct nrf_rpc_group *grou return; decoding_error: - report_decoding_error(BT_CONN_GET_REMOTE_INFO_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_GET_REMOTE_INFO_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_get_remote_info, BT_CONN_GET_REMOTE_INFO_RPC_CMD, @@ -438,7 +432,7 @@ static void bt_conn_le_param_update_rpc_handler(const struct nrf_rpc_group *grou return; decoding_error: - report_decoding_error(BT_CONN_LE_PARAM_UPDATE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_LE_PARAM_UPDATE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_le_param_update, BT_CONN_LE_PARAM_UPDATE_RPC_CMD, @@ -472,7 +466,7 @@ static void bt_conn_le_data_len_update_rpc_handler(const struct nrf_rpc_group *g return; decoding_error: - report_decoding_error(BT_CONN_LE_DATA_LEN_UPDATE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_LE_DATA_LEN_UPDATE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_le_data_len_update, BT_CONN_LE_DATA_LEN_UPDATE_RPC_CMD, @@ -508,7 +502,7 @@ static void bt_conn_le_phy_update_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_LE_PHY_UPDATE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_LE_PHY_UPDATE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_le_phy_update, BT_CONN_LE_PHY_UPDATE_RPC_CMD, @@ -535,7 +529,7 @@ static void bt_conn_disconnect_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_DISCONNECT_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_DISCONNECT_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_disconnect, BT_CONN_DISCONNECT_RPC_CMD, @@ -588,7 +582,7 @@ static void bt_conn_le_create_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_LE_CREATE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_LE_CREATE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_le_create, BT_CONN_LE_CREATE_RPC_CMD, @@ -615,7 +609,7 @@ static void bt_conn_le_create_auto_rpc_handler(const struct nrf_rpc_group *group return; decoding_error: - report_decoding_error(BT_CONN_LE_CREATE_AUTO_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_LE_CREATE_AUTO_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_le_create_auto, BT_CONN_LE_CREATE_AUTO_RPC_CMD, @@ -659,7 +653,7 @@ static void bt_conn_set_security_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_SET_SECURITY_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_SET_SECURITY_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_set_security, BT_CONN_SET_SECURITY_RPC_CMD, @@ -692,7 +686,7 @@ static void bt_conn_get_security_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_GET_SECURITY_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_GET_SECURITY_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_get_security, BT_CONN_GET_SECURITY_RPC_CMD, @@ -716,7 +710,7 @@ static void bt_conn_enc_key_size_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_ENC_KEY_SIZE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_ENC_KEY_SIZE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_enc_key_size, BT_CONN_ENC_KEY_SIZE_RPC_CMD, @@ -957,7 +951,7 @@ static void bt_set_bondable_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_SET_BONDABLE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_SET_BONDABLE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_set_bondable, BT_SET_BONDABLE_RPC_CMD, @@ -981,7 +975,7 @@ static void bt_le_oob_set_legacy_flag_rpc_handler(const struct nrf_rpc_group *gr return; decoding_error: - report_decoding_error(BT_LE_OOB_SET_LEGACY_FLAG_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_OOB_SET_LEGACY_FLAG_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_oob_set_legacy_flag, BT_LE_OOB_SET_LEGACY_FLAG_RPC_CMD, @@ -1005,7 +999,7 @@ static void bt_le_oob_set_sc_flag_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_OOB_SET_SC_FLAG_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_OOB_SET_SC_FLAG_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_oob_set_sc_flag, BT_LE_OOB_SET_SC_FLAG_RPC_CMD, @@ -1036,7 +1030,7 @@ static void bt_le_oob_set_legacy_tk_rpc_handler(const struct nrf_rpc_group *grou return; decoding_error: - report_decoding_error(BT_LE_OOB_SET_LEGACY_TK_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_OOB_SET_LEGACY_TK_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_oob_set_legacy_tk, BT_LE_OOB_SET_LEGACY_TK_RPC_CMD, @@ -1101,7 +1095,7 @@ static void bt_le_oob_set_sc_data_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_OOB_SET_SC_DATA_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_OOB_SET_SC_DATA_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_oob_set_sc_data, BT_LE_OOB_SET_SC_DATA_RPC_CMD, @@ -1152,7 +1146,7 @@ static void bt_le_oob_get_sc_data_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_OOB_GET_SC_DATA_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_OOB_GET_SC_DATA_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_oob_get_sc_data, BT_LE_OOB_GET_SC_DATA_RPC_CMD, @@ -1178,7 +1172,7 @@ static void bt_passkey_set_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_PASSKEY_SET_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_PASSKEY_SET_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_passkey_set, BT_PASSKEY_SET_RPC_CMD, @@ -1364,7 +1358,7 @@ static void bt_conn_auth_cb_register_on_remote_rpc_handler(const struct nrf_rpc_ return; decoding_error: - report_decoding_error(BT_CONN_AUTH_CB_REGISTER_ON_REMOTE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_AUTH_CB_REGISTER_ON_REMOTE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_auth_cb_register_on_remote, @@ -1452,7 +1446,7 @@ static void bt_conn_auth_info_cb_register_on_remote_rpc_handler(const struct nrf return; decoding_error: - report_decoding_error(BT_CONN_AUTH_INFO_CB_REGISTER_ON_REMOTE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_AUTH_INFO_CB_REGISTER_ON_REMOTE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_auth_info_cb_register_on_remote, @@ -1476,7 +1470,7 @@ static void bt_conn_auth_info_cb_unregister_on_remote_rpc_handler(const struct n return; decoding_error: - report_decoding_error(BT_CONN_AUTH_INFO_CB_UNREGISTER_ON_REMOTE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_AUTH_INFO_CB_UNREGISTER_ON_REMOTE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_auth_info_cb_unregister_on_remote, @@ -1503,7 +1497,7 @@ static void bt_conn_auth_passkey_entry_rpc_handler(const struct nrf_rpc_group *g return; decoding_error: - report_decoding_error(BT_CONN_AUTH_PASSKEY_ENTRY_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_AUTH_PASSKEY_ENTRY_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_auth_passkey_entry, BT_CONN_AUTH_PASSKEY_ENTRY_RPC_CMD, @@ -1527,7 +1521,7 @@ static void bt_conn_auth_cancel_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CONN_AUTH_CANCEL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_AUTH_CANCEL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_auth_cancel, BT_CONN_AUTH_CANCEL_RPC_CMD, @@ -1552,7 +1546,7 @@ static void bt_conn_auth_passkey_confirm_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_CONN_AUTH_PASSKEY_CONFIRM_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_AUTH_PASSKEY_CONFIRM_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_auth_passkey_confirm, @@ -1578,7 +1572,7 @@ static void bt_conn_auth_pairing_confirm_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_CONN_AUTH_PAIRING_CONFIRM_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CONN_AUTH_PAIRING_CONFIRM_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_conn_auth_pairing_confirm, diff --git a/subsys/bluetooth/rpc/host/bt_rpc_crypto_host.c b/subsys/bluetooth/rpc/host/bt_rpc_crypto_host.c index 6d6eeb4ca562..8b9fcb873627 100644 --- a/subsys/bluetooth/rpc/host/bt_rpc_crypto_host.c +++ b/subsys/bluetooth/rpc/host/bt_rpc_crypto_host.c @@ -13,12 +13,6 @@ #include #include -static void report_decoding_error(uint8_t cmd_evt_id, void *data) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - static void bt_encrypt_le_rpc_handler(const struct nrf_rpc_group *group, struct nrf_rpc_cbor_ctx *ctx, void *handler_data) { @@ -45,7 +39,7 @@ static void bt_encrypt_le_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_ENCRYPT_LE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_ENCRYPT_LE_RPC_CMD); } @@ -78,7 +72,7 @@ static void bt_encrypt_be_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_ENCRYPT_BE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_ENCRYPT_BE_RPC_CMD); } @@ -121,7 +115,7 @@ static void bt_rand_rpc_handler(const struct nrf_rpc_group *group, struct nrf_rp return; decoding_error: - report_decoding_error(BT_RAND_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RAND_RPC_CMD); } @@ -177,7 +171,7 @@ static void bt_ccm_encrypt_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CCM_ENCRYPT_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CCM_ENCRYPT_RPC_CMD); } @@ -232,7 +226,7 @@ static void bt_ccm_decrypt_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_CCM_DECRYPT_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_CCM_DECRYPT_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_ccm_decrypt, BT_CCM_DECRYPT_RPC_CMD, diff --git a/subsys/bluetooth/rpc/host/bt_rpc_gap_host.c b/subsys/bluetooth/rpc/host/bt_rpc_gap_host.c index be7504052b92..e6b0280ae5dd 100644 --- a/subsys/bluetooth/rpc/host/bt_rpc_gap_host.c +++ b/subsys/bluetooth/rpc/host/bt_rpc_gap_host.c @@ -15,12 +15,6 @@ #include #include -static void report_decoding_error(uint8_t cmd_evt_id, void *data) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - static void bt_rpc_get_check_list_rpc_handler(const struct nrf_rpc_group *group, struct nrf_rpc_cbor_ctx *ctx, void *handler_data) { @@ -54,7 +48,7 @@ static void bt_rpc_get_check_list_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_RPC_GET_CHECK_LIST_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GET_CHECK_LIST_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_get_check_list, BT_RPC_GET_CHECK_LIST_RPC_CMD, @@ -93,7 +87,7 @@ static void bt_enable_rpc_handler(const struct nrf_rpc_group *group, struct nrf_ return; decoding_error: - report_decoding_error(BT_ENABLE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_ENABLE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_enable, BT_ENABLE_RPC_CMD, bt_enable_rpc_handler, NULL); @@ -114,7 +108,7 @@ static void bt_disable_rpc_handler(const struct nrf_rpc_group *group, struct nrf return; decoding_error: - report_decoding_error(BT_DISABLE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_DISABLE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_disable, BT_DISABLE_RPC_CMD, bt_disable_rpc_handler, NULL); @@ -135,7 +129,7 @@ static void bt_is_ready_rpc_handler(const struct nrf_rpc_group *group, struct nr return; decoding_error: - report_decoding_error(BT_IS_READY_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_IS_READY_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_is_ready, BT_IS_READY_RPC_CMD, bt_is_ready_rpc_handler, @@ -164,7 +158,7 @@ static void bt_set_name_rpc_handler(const struct nrf_rpc_group *group, struct nr return; decoding_error: - report_decoding_error(BT_SET_NAME_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_SET_NAME_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_set_name, BT_SET_NAME_RPC_CMD, bt_set_name_rpc_handler, @@ -223,7 +217,7 @@ static void bt_get_name_out_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_GET_NAME_OUT_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GET_NAME_OUT_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_get_name_out, BT_GET_NAME_OUT_RPC_CMD, @@ -247,7 +241,7 @@ static void bt_get_appearance_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_GET_APPEARANCE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GET_APPEARANCE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_get_appearance, BT_GET_APPEARANCE_RPC_CMD, @@ -271,7 +265,7 @@ static void bt_set_appearance_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_SET_APPEARANCE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_SET_APPEARANCE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_set_appearance, BT_SET_APPEARANCE_RPC_CMD, @@ -314,7 +308,7 @@ static void bt_id_get_rpc_handler(const struct nrf_rpc_group *group, struct nrf_ return; decoding_error: - report_decoding_error(BT_ID_GET_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_ID_GET_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_id_get, BT_ID_GET_RPC_CMD, bt_id_get_rpc_handler, NULL); @@ -357,7 +351,7 @@ static void bt_id_create_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_ID_CREATE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_ID_CREATE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_id_create, BT_ID_CREATE_RPC_CMD, bt_id_create_rpc_handler, @@ -403,7 +397,7 @@ static void bt_id_reset_rpc_handler(const struct nrf_rpc_group *group, struct nr return; decoding_error: - report_decoding_error(BT_ID_RESET_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_ID_RESET_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_id_reset, BT_ID_RESET_RPC_CMD, bt_id_reset_rpc_handler, @@ -427,7 +421,7 @@ static void bt_id_delete_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_ID_DELETE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_ID_DELETE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_id_delete, BT_ID_DELETE_RPC_CMD, bt_id_delete_rpc_handler, @@ -561,7 +555,7 @@ static void bt_le_adv_start_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_ADV_START_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_ADV_START_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_adv_start, BT_LE_ADV_START_RPC_CMD, @@ -608,7 +602,7 @@ static void bt_le_adv_update_data_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_ADV_UPDATE_DATA_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_ADV_UPDATE_DATA_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_adv_update_data, BT_LE_ADV_UPDATE_DATA_RPC_CMD, @@ -820,7 +814,7 @@ static void bt_le_ext_adv_create_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_CREATE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_CREATE_RPC_CMD); if (result == 0) { k_mem_slab_free(&bt_rpc_ext_adv_cb_cache, (void *)cb); @@ -857,7 +851,7 @@ static void bt_le_ext_adv_start_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_START_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_START_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_start, BT_LE_EXT_ADV_START_RPC_CMD, @@ -881,7 +875,7 @@ static void bt_le_ext_adv_stop_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_STOP_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_STOP_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_stop, BT_LE_EXT_ADV_STOP_RPC_CMD, @@ -931,7 +925,7 @@ static void bt_le_ext_adv_set_data_rpc_handler(const struct nrf_rpc_group *group return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_SET_DATA_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_SET_DATA_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_set_data, BT_LE_EXT_ADV_SET_DATA_RPC_CMD, @@ -960,7 +954,7 @@ static void bt_le_ext_adv_update_param_rpc_handler(const struct nrf_rpc_group *g return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_UPDATE_PARAM_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_UPDATE_PARAM_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_update_param, BT_LE_EXT_ADV_UPDATE_PARAM_RPC_CMD, @@ -994,7 +988,7 @@ static void bt_le_ext_adv_delete_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_DELETE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_DELETE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_delete, BT_LE_EXT_ADV_DELETE_RPC_CMD, @@ -1018,7 +1012,7 @@ static void bt_le_ext_adv_get_index_rpc_handler(const struct nrf_rpc_group *grou return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_GET_INDEX_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_GET_INDEX_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_get_index, BT_LE_EXT_ADV_GET_INDEX_RPC_CMD, @@ -1050,7 +1044,7 @@ static void bt_le_ext_adv_get_info_rpc_handler(const struct nrf_rpc_group *group return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_GET_INFO_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_GET_INFO_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_get_info, BT_LE_EXT_ADV_GET_INFO_RPC_CMD, @@ -1089,7 +1083,7 @@ static void bt_le_ext_adv_oob_get_local_rpc_handler(const struct nrf_rpc_group * return; decoding_error: - report_decoding_error(BT_LE_EXT_ADV_OOB_GET_LOCAL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_EXT_ADV_OOB_GET_LOCAL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_ext_adv_oob_get_local, @@ -1118,7 +1112,7 @@ static void bt_le_scan_start_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_SCAN_START_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_SCAN_START_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_scan_start, BT_LE_SCAN_START_RPC_CMD, @@ -1246,7 +1240,7 @@ static void bt_le_filter_accept_list_add_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_LE_FILTER_ACCEPT_LIST_ADD_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_FILTER_ACCEPT_LIST_ADD_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_filter_accept_list_add, @@ -1273,7 +1267,7 @@ static void bt_le_filter_accept_list_remove_rpc_handler(const struct nrf_rpc_gro return; decoding_error: - report_decoding_error(BT_LE_FILTER_ACCEPT_LIST_REMOVE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_FILTER_ACCEPT_LIST_REMOVE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_filter_accept_list_remove, @@ -1319,7 +1313,7 @@ static void bt_le_set_chan_map_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_SET_CHAN_MAP_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_SET_CHAN_MAP_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_set_chan_map, BT_LE_SET_CHAN_MAP_RPC_CMD, @@ -1357,7 +1351,7 @@ static void bt_le_oob_get_local_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_OOB_GET_LOCAL_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_OOB_GET_LOCAL_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_oob_get_local, BT_LE_OOB_GET_LOCAL_RPC_CMD, @@ -1385,7 +1379,7 @@ static void bt_unpair_rpc_handler(const struct nrf_rpc_group *group, struct nrf_ return; decoding_error: - report_decoding_error(BT_UNPAIR_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_UNPAIR_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_unpair, BT_UNPAIR_RPC_CMD, bt_unpair_rpc_handler, NULL); @@ -1448,7 +1442,7 @@ static void bt_foreach_bond_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_FOREACH_BOND_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_FOREACH_BOND_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_foreach_bond, BT_FOREACH_BOND_RPC_CMD, @@ -1492,7 +1486,7 @@ static void bt_le_per_adv_list_add_rpc_handler(const struct nrf_rpc_group *group return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_LIST_ADD_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_LIST_ADD_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_list_add, BT_LE_PER_ADV_LIST_ADD_RPC_CMD, @@ -1519,7 +1513,7 @@ static void bt_le_per_adv_list_remove_rpc_handler(const struct nrf_rpc_group *gr return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_LIST_REMOVE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_LIST_REMOVE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_list_remove, BT_LE_PER_ADV_LIST_REMOVE_RPC_CMD, @@ -1552,7 +1546,7 @@ static void bt_le_per_adv_set_param_rpc_handler(const struct nrf_rpc_group *grou return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SET_PARAM_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SET_PARAM_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_set_param, BT_LE_PER_ADV_SET_PARAM_RPC_CMD, @@ -1590,7 +1584,7 @@ static void bt_le_per_adv_set_data_rpc_handler(const struct nrf_rpc_group *group return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SET_DATA_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SET_DATA_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_set_data, BT_LE_PER_ADV_SET_DATA_RPC_CMD, @@ -1614,7 +1608,7 @@ static void bt_le_per_adv_start_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_START_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_START_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_start, BT_LE_PER_ADV_START_RPC_CMD, @@ -1638,7 +1632,7 @@ static void bt_le_per_adv_stop_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_STOP_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_STOP_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_stop, BT_LE_PER_ADV_STOP_RPC_CMD, @@ -1668,7 +1662,7 @@ static void bt_le_per_adv_set_info_transfer_rpc_handler(const struct nrf_rpc_gro return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SET_INFO_TRANSFER_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SET_INFO_TRANSFER_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_set_info_transfer, @@ -1697,7 +1691,7 @@ static void bt_le_per_adv_sync_get_index_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SYNC_GET_INDEX_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SYNC_GET_INDEX_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_sync_get_index, @@ -1744,7 +1738,7 @@ static void bt_le_per_adv_sync_create_rpc_handler(const struct nrf_rpc_group *gr return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SYNC_CREATE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SYNC_CREATE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_sync_create, BT_LE_PER_ADV_SYNC_CREATE_RPC_CMD, @@ -1768,7 +1762,7 @@ static void bt_le_per_adv_sync_delete_rpc_handler(const struct nrf_rpc_group *gr return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SYNC_DELETE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SYNC_DELETE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_sync_delete, BT_LE_PER_ADV_SYNC_DELETE_RPC_CMD, @@ -1793,7 +1787,7 @@ static void bt_le_per_adv_sync_recv_enable_rpc_handler(const struct nrf_rpc_grou return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SYNC_RECV_ENABLE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SYNC_RECV_ENABLE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_sync_recv_enable, @@ -1819,7 +1813,7 @@ static void bt_le_per_adv_sync_recv_disable_rpc_handler(const struct nrf_rpc_gro return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SYNC_RECV_DISABLE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SYNC_RECV_DISABLE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_sync_recv_disable, @@ -1850,7 +1844,7 @@ static void bt_le_per_adv_sync_transfer_rpc_handler(const struct nrf_rpc_group * return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SYNC_TRANSFER_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SYNC_TRANSFER_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_sync_transfer, @@ -1876,7 +1870,7 @@ static void bt_le_per_adv_sync_transfer_unsubscribe_rpc_handler(const struct nrf return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SYNC_TRANSFER_UNSUBSCRIBE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SYNC_TRANSFER_UNSUBSCRIBE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_sync_transfer_unsubscribe, @@ -1912,7 +1906,7 @@ static void bt_le_per_adv_sync_transfer_subscribe_rpc_handler(const struct nrf_r return; decoding_error: - report_decoding_error(BT_LE_PER_ADV_SYNC_TRANSFER_SUBSCRIBE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_LE_PER_ADV_SYNC_TRANSFER_SUBSCRIBE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_le_per_adv_sync_transfer_subscribe, diff --git a/subsys/bluetooth/rpc/host/bt_rpc_gatt_host.c b/subsys/bluetooth/rpc/host/bt_rpc_gatt_host.c index c159970b9aa3..e9f2de0bd05d 100644 --- a/subsys/bluetooth/rpc/host/bt_rpc_gatt_host.c +++ b/subsys/bluetooth/rpc/host/bt_rpc_gatt_host.c @@ -173,20 +173,12 @@ static struct bt_uuid *bt_uuid_cli_dec(struct nrf_rpc_cbor_ctx *ctx, struct bt_u return (struct bt_uuid *)nrf_rpc_decode_buffer(ctx, uuid, sizeof(struct bt_uuid_128)); } -static void report_encoding_error(uint8_t cmd_evt_id) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} +#define report_encoding_error(cmd_evt_id) \ + nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_SEND, &bt_rpc_grp, cmd_evt_id, \ + NRF_RPC_PACKET_TYPE_CMD) #endif /* CONFIG_BT_GATT_CLIENT */ -static void report_decoding_error(uint8_t cmd_evt_id, void *data) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - static int bt_rpc_gatt_start_service(uint8_t remote_service_index, size_t attr_count) { int err; @@ -246,7 +238,7 @@ static void bt_rpc_gatt_start_service_rpc_handler(const struct nrf_rpc_group *gr return; decoding_error: - report_decoding_error(BT_RPC_GATT_START_SERVICE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_START_SERVICE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_gatt_start_service, BT_RPC_GATT_START_SERVICE_RPC_CMD, @@ -438,7 +430,7 @@ static void bt_rpc_gatt_send_simple_attr_rpc_handler(const struct nrf_rpc_group return; decoding_error: - report_decoding_error(BT_RPC_GATT_SEND_SIMPLE_ATTR_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_SEND_SIMPLE_ATTR_RPC_CMD); } static int add_cep_attr(struct bt_gatt_attr *attr, uint16_t properties) @@ -678,7 +670,7 @@ static void bt_rpc_gatt_send_desc_attr_rpc_handler(const struct nrf_rpc_group *g return; decoding_error: - report_decoding_error(BT_RPC_GATT_SEND_DESC_ATTR_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_SEND_DESC_ATTR_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_gatt_send_desc_attr, BT_RPC_GATT_SEND_DESC_ATTR_RPC_CMD, @@ -754,7 +746,7 @@ static void bt_rpc_gatt_service_unregister_rpc_handler(const struct nrf_rpc_grou nrf_rpc_rsp_send_int(group, result); return; decoding_error: - report_decoding_error(BT_RPC_GATT_SERVICE_UNREGISTER_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_SERVICE_UNREGISTER_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_gatt_service_unregister, @@ -821,7 +813,7 @@ static void bt_gatt_notify_cb_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_GATT_NOTIFY_CB_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_NOTIFY_CB_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_notify_cb, BT_GATT_NOTIFY_CB_RPC_CMD, @@ -909,7 +901,7 @@ static void bt_gatt_indicate_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: k_free(params); - report_decoding_error(BT_GATT_INDICATE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_INDICATE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_indicate, BT_GATT_INDICATE_RPC_CMD, @@ -937,7 +929,7 @@ static void bt_gatt_is_subscribed_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_GATT_IS_SUBSCRIBED_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_IS_SUBSCRIBED_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_is_subscribed, BT_GATT_IS_SUBSCRIBED_RPC_CMD, @@ -962,7 +954,7 @@ static void bt_gatt_get_mtu_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_GATT_GET_MTU_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_GET_MTU_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_get_mtu, BT_GATT_GET_MTU_RPC_CMD, @@ -1029,7 +1021,7 @@ static void bt_gatt_exchange_mtu_rpc_handler(const struct nrf_rpc_group *group, decoding_error: k_free(container); alloc_error: - report_decoding_error(BT_GATT_EXCHANGE_MTU_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_EXCHANGE_MTU_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_exchange_mtu, BT_GATT_EXCHANGE_MTU_RPC_CMD, @@ -1056,7 +1048,7 @@ static void bt_gatt_attr_get_handle_rpc_handler(const struct nrf_rpc_group *grou return; decoding_error: - report_decoding_error(BT_GATT_ATTR_GET_HANDLE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_ATTR_GET_HANDLE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_attr_get_handle, BT_GATT_ATTR_GET_HANDLE_RPC_CMD, @@ -1206,7 +1198,7 @@ static void bt_gatt_discover_rpc_handler(const struct nrf_rpc_group *group, decoding_error: k_free(container); alloc_error: - report_decoding_error(BT_GATT_DISCOVER_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_DISCOVER_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_discover, BT_GATT_DISCOVER_RPC_CMD, @@ -1297,7 +1289,7 @@ static void bt_gatt_read_rpc_handler(const struct nrf_rpc_group *group, decoding_error: k_free(container); alloc_error: - report_decoding_error(BT_GATT_READ_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_READ_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_read, BT_GATT_READ_RPC_CMD, bt_gatt_read_rpc_handler, @@ -1368,7 +1360,7 @@ static void bt_gatt_write_rpc_handler(const struct nrf_rpc_group *group, decoding_error: k_free(container); alloc_error: - report_decoding_error(BT_GATT_WRITE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_WRITE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_write, BT_GATT_WRITE_RPC_CMD, @@ -1411,7 +1403,7 @@ static void bt_gatt_write_without_response_cb_rpc_handler(const struct nrf_rpc_g return; decoding_error: - report_decoding_error(BT_GATT_WRITE_WITHOUT_RESPONSE_CB_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_WRITE_WITHOUT_RESPONSE_CB_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_write_without_response_cb, @@ -1590,7 +1582,7 @@ static void bt_gatt_subscribe_rpc_handler(const struct nrf_rpc_group *group, free_subscribe_container(container); } alloc_error: - report_decoding_error(BT_GATT_SUBSCRIBE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_SUBSCRIBE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_subscribe, BT_GATT_SUBSCRIBE_RPC_CMD, @@ -1636,7 +1628,7 @@ static void bt_gatt_resubscribe_rpc_handler(const struct nrf_rpc_group *group, free_subscribe_container(container); } alloc_error: - report_decoding_error(BT_GATT_RESUBSCRIBE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_RESUBSCRIBE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_resubscribe, BT_GATT_RESUBSCRIBE_RPC_CMD, @@ -1671,7 +1663,7 @@ static void bt_gatt_unsubscribe_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_GATT_UNSUBSCRIBE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_GATT_UNSUBSCRIBE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_gatt_unsubscribe, BT_GATT_UNSUBSCRIBE_RPC_CMD, @@ -1717,7 +1709,7 @@ static void bt_rpc_gatt_subscribe_flag_update_rpc_handler(const struct nrf_rpc_g return; decoding_error: - report_decoding_error(BT_RPC_GATT_SUBSCRIBE_FLAG_UPDATE_RPC_CMD, handler_data); + bt_rpc_report_decoding_error(BT_RPC_GATT_SUBSCRIBE_FLAG_UPDATE_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_rpc_gatt_subscribe_flag_update, diff --git a/subsys/bluetooth/rpc/host/bt_rpc_internal_host.c b/subsys/bluetooth/rpc/host/bt_rpc_internal_host.c index 279a25ba97b4..12b82298c3f7 100644 --- a/subsys/bluetooth/rpc/host/bt_rpc_internal_host.c +++ b/subsys/bluetooth/rpc/host/bt_rpc_internal_host.c @@ -20,12 +20,6 @@ LOG_MODULE_DECLARE(BT_RPC, CONFIG_BT_RPC_LOG_LEVEL); -static void report_decoding_error(uint8_t cmd_evt_id, void *data) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &bt_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - static void bt_addr_le_is_bonded_rpc_handler(const struct nrf_rpc_group *group, struct nrf_rpc_cbor_ctx *ctx, void *handler_data) { @@ -47,7 +41,7 @@ static void bt_addr_le_is_bonded_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_ADDR_LE_IS_BONDED_CMD, handler_data); + bt_rpc_report_decoding_error(BT_ADDR_LE_IS_BONDED_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_addr_le_is_bonded, BT_ADDR_LE_IS_BONDED_CMD, @@ -136,7 +130,7 @@ static void bt_hci_cmd_send_sync_rpc_handler(const struct nrf_rpc_group *group, return; decoding_error: - report_decoding_error(BT_HCI_CMD_SEND_SYNC_RPC_CMD, hanler_data); + bt_rpc_report_decoding_error(BT_HCI_CMD_SEND_SYNC_RPC_CMD); } NRF_RPC_CBOR_CMD_DECODER(bt_rpc_grp, bt_hci_cmd_send_sync, BT_HCI_CMD_SEND_SYNC_RPC_CMD, diff --git a/subsys/dm/rpc/common/dm_rpc_common.h b/subsys/dm/rpc/common/dm_rpc_common.h index cd585d2f942d..1b9f672410b9 100644 --- a/subsys/dm/rpc/common/dm_rpc_common.h +++ b/subsys/dm/rpc/common/dm_rpc_common.h @@ -26,4 +26,8 @@ struct dm_rpc_process_data { bt_addr_le_t bt_addr; }; +#define dm_rpc_report_decoding_error(cmd_evt_id, data) \ + nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &dm_rpc_grp, cmd_evt_id, \ + NRF_RPC_PACKET_TYPE_CMD) + #endif /* DM_RPC_COMMON_H_ */ diff --git a/subsys/dm/rpc/host/dm_rpc_host.c b/subsys/dm/rpc/host/dm_rpc_host.c index 9971d06ae0d2..cf16df4d1cc2 100644 --- a/subsys/dm/rpc/host/dm_rpc_host.c +++ b/subsys/dm/rpc/host/dm_rpc_host.c @@ -22,12 +22,6 @@ static struct ipc_ept ep; static K_SEM_DEFINE(bound_sem, 0, 1); static K_SEM_DEFINE(process_sem, 0, 1); -static void report_decoding_error(uint8_t cmd_evt_id, void *data) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &dm_rpc_grp, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - static void dm_init_rpc_handler(const struct nrf_rpc_group *group, struct nrf_rpc_cbor_ctx *ctx, void *handler_data) { @@ -35,7 +29,7 @@ static void dm_init_rpc_handler(const struct nrf_rpc_group *group, struct nrf_rp struct dm_init_param dm_param; if (!ser_decoding_done_and_check(group, ctx)) { - report_decoding_error(DM_INIT_RPC_CMD, handler_data); + dm_rpc_report_decoding_error(DM_INIT_RPC_CMD, handler_data); return; } @@ -61,7 +55,7 @@ static void dm_request_add_rpc_handler(const struct nrf_rpc_group *group, req.extra_window_time_us = ser_decode_uint(ctx); if (!ser_decoding_done_and_check(group, ctx)) { - report_decoding_error(DM_REQUEST_ADD_RPC_CMD, handler_data); + dm_rpc_report_decoding_error(DM_REQUEST_ADD_RPC_CMD, handler_data); return; } diff --git a/subsys/net/openthread/rpc/common/ot_rpc_common.c b/subsys/net/openthread/rpc/common/ot_rpc_common.c index 1a9b506ea2ca..cb89e3b80220 100644 --- a/subsys/net/openthread/rpc/common/ot_rpc_common.c +++ b/subsys/net/openthread/rpc/common/ot_rpc_common.c @@ -173,16 +173,6 @@ void ot_rpc_encode_message_settings(struct nrf_rpc_cbor_ctx *ctx, const otMessag nrf_rpc_encode_uint(ctx, settings->mPriority); } -void ot_rpc_report_cmd_decoding_error(uint8_t cmd_evt_id) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &ot_group, cmd_evt_id, NRF_RPC_PACKET_TYPE_CMD); -} - -void ot_rpc_report_rsp_decoding_error(uint8_t cmd_evt_id) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &ot_group, cmd_evt_id, NRF_RPC_PACKET_TYPE_RSP); -} - void ot_rpc_encode_message_info(struct nrf_rpc_cbor_ctx *ctx, const otMessageInfo *aMessageInfo) { nrf_rpc_encode_buffer(ctx, aMessageInfo->mSockAddr.mFields.m8, diff --git a/subsys/net/openthread/rpc/common/ot_rpc_common.h b/subsys/net/openthread/rpc/common/ot_rpc_common.h index 9bbade3a35f0..51e3a3663c53 100644 --- a/subsys/net/openthread/rpc/common/ot_rpc_common.h +++ b/subsys/net/openthread/rpc/common/ot_rpc_common.h @@ -80,8 +80,11 @@ otMessageSettings *ot_rpc_decode_message_settings(struct nrf_rpc_cbor_ctx *ctx, otMessageSettings *settings); void ot_rpc_encode_message_settings(struct nrf_rpc_cbor_ctx *ctx, const otMessageSettings *settings); -void ot_rpc_report_cmd_decoding_error(uint8_t cmd_evt_id); -void ot_rpc_report_rsp_decoding_error(uint8_t cmd_evt_id); +#define ot_rpc_report_cmd_decoding_error(cmd_evt_id) \ + nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &ot_group, cmd_evt_id, NRF_RPC_PACKET_TYPE_CMD) + +#define ot_rpc_report_rsp_decoding_error(cmd_evt_id) \ + nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &ot_group, cmd_evt_id, NRF_RPC_PACKET_TYPE_RSP) void ot_rpc_decode_message_info(struct nrf_rpc_cbor_ctx *ctx, otMessageInfo *aMessageInfo); void ot_rpc_encode_message_info(struct nrf_rpc_cbor_ctx *ctx, const otMessageInfo *aMessageInfo); void ot_rpc_encode_service_config(struct nrf_rpc_cbor_ctx *ctx, diff --git a/subsys/nfc/rpc/common/nfc_rpc_common.c b/subsys/nfc/rpc/common/nfc_rpc_common.c index 7026ec769ef6..7f9e7854c454 100644 --- a/subsys/nfc/rpc/common/nfc_rpc_common.c +++ b/subsys/nfc/rpc/common/nfc_rpc_common.c @@ -14,12 +14,6 @@ void nfc_rpc_decode_error(const struct nrf_rpc_group *group, struct nrf_rpc_cbor nrf_rpc_rsp_decode_i32(group, ctx, handler_data); } -void nfc_rpc_report_decoding_error(uint8_t cmd_evt_id) -{ - nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &nfc_group, cmd_evt_id, - NRF_RPC_PACKET_TYPE_CMD); -} - void nfc_rpc_decode_parameter(const struct nrf_rpc_group *group, struct nrf_rpc_cbor_ctx *ctx, void *handler_data) { diff --git a/subsys/nfc/rpc/common/nfc_rpc_common.h b/subsys/nfc/rpc/common/nfc_rpc_common.h index 95717b1391bb..5d3a34d23731 100644 --- a/subsys/nfc/rpc/common/nfc_rpc_common.h +++ b/subsys/nfc/rpc/common/nfc_rpc_common.h @@ -20,7 +20,8 @@ void nfc_rpc_decode_error(const struct nrf_rpc_group *group, struct nrf_rpc_cbor void *handler_data); void nfc_rpc_decode_parameter(const struct nrf_rpc_group *group, struct nrf_rpc_cbor_ctx *ctx, void *handler_data); -/* The function reports about command decoding error (not responses). */ -void nfc_rpc_report_decoding_error(uint8_t cmd_evt_id); +/* The macro reports about command decoding error (not responses). */ +#define nfc_rpc_report_decoding_error(cmd_evt_id) \ + nrf_rpc_err(-EBADMSG, NRF_RPC_ERR_SRC_RECV, &nfc_group, cmd_evt_id, NRF_RPC_PACKET_TYPE_CMD) #endif /* NFC_RPC_COMMON_H_ */ diff --git a/west.yml b/west.yml index 0560a7c2d33c..00818c13b05a 100644 --- a/west.yml +++ b/west.yml @@ -144,7 +144,7 @@ manifest: - name: nrfxlib repo-path: sdk-nrfxlib path: nrfxlib - revision: 79c2aab46e1678d049a8256c9c38936a32da8b3f + revision: 3acc454e3ddb409d6ddf3b894eb41bec479e2a16 - name: trusted-firmware-m repo-path: sdk-trusted-firmware-m path: modules/tee/tf-m/trusted-firmware-m From e4927836202a98c8835f05cb6c87915117f8c0fc Mon Sep 17 00:00:00 2001 From: Ludvig Jordet Date: Wed, 20 May 2026 16:26:05 +0200 Subject: [PATCH 22/37] Samples: Bluetooth: Mesh: Avoid error during input OOB For samples which add a button handler for sample-specific functionality, this will run in parallell with the OOB button handler during OOB input. This affects two samples which print or log an error when buttons are pressed when the node is unprovisioned, which will be printed on every button press during input OOB, which is noisy. This print/log has been removed for these samples (light_dimmer and sensor_server), which is aligned with the silent handling of unprovisioned nodes already done in the light_switch and sensor_client samples. Signed-off-by: Ludvig Jordet --- samples/bluetooth/mesh/light_dimmer/src/model_handler.c | 1 - samples/bluetooth/mesh/sensor_server/src/model_handler.c | 1 - 2 files changed, 2 deletions(-) diff --git a/samples/bluetooth/mesh/light_dimmer/src/model_handler.c b/samples/bluetooth/mesh/light_dimmer/src/model_handler.c index e2028739253a..9039d0a2f7f6 100644 --- a/samples/bluetooth/mesh/light_dimmer/src/model_handler.c +++ b/samples/bluetooth/mesh/light_dimmer/src/model_handler.c @@ -221,7 +221,6 @@ static void scene_button_handler(struct scene_btn_ctx *ctx, bool pressed) static void button_handler_cb(uint32_t pressed, uint32_t changed) { if (!bt_mesh_is_provisioned()) { - LOG_ERR("Node is not provisioned"); return; } diff --git a/samples/bluetooth/mesh/sensor_server/src/model_handler.c b/samples/bluetooth/mesh/sensor_server/src/model_handler.c index 151d606e4879..caa994da6102 100644 --- a/samples/bluetooth/mesh/sensor_server/src/model_handler.c +++ b/samples/bluetooth/mesh/sensor_server/src/model_handler.c @@ -934,7 +934,6 @@ static void motion_button_handler(bool pressed) static void button_handler_cb(uint32_t pressed, uint32_t changed) { if (!bt_mesh_is_provisioned()) { - printk("Node is not provisioned"); return; } From 600dcf40a6dc953283f0004de5fce0f0ed369e44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Tue, 19 May 2026 16:03:51 +0200 Subject: [PATCH 23/37] samples: ipc: ipc_service: Add ranges property to reserved-memory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Property "ranges" is required for "reserved-memory" node. Set it unless already done at the board definition level. "reserved-memory" node must be placed under root node. Fix overlays for all platforms. Signed-off-by: Sebastian Głąb --- .../nrf5340dk_nrf5340_cpuapp_icbmsg.overlay | 1 + .../nrf5340dk_nrf5340_cpuapp_icmsg.overlay | 1 + .../boards/nrf54l15dk_nrf54l15_cpuapp.overlay | 19 +++++++++---------- .../nrf54l15dk_nrf54l15_cpuapp_icbmsg.overlay | 19 +++++++++---------- .../nrf54lc10dk_nrf54lc10a_cpuapp.overlay | 19 +++++++++---------- ...f54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay | 19 +++++++++---------- .../nrf54lm20dk_nrf54lm20a_cpuapp.overlay | 19 +++++++++---------- ...f54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay | 19 +++++++++---------- .../nrf54lv10dk_nrf54lv10a_cpuapp.overlay | 19 +++++++++---------- ...f54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay | 19 +++++++++---------- .../nrf7002dk_nrf5340_cpuapp_icbmsg.overlay | 1 + .../nrf7002dk_nrf5340_cpuapp_icmsg.overlay | 1 + .../boards/nrf7120dk_nrf7120_cpuapp.overlay | 17 ++++++----------- .../nrf5340dk_nrf5340_cpunet_icbmsg.overlay | 1 + .../nrf5340dk_nrf5340_cpunet_icmsg.overlay | 1 + .../nrf54l15dk_nrf54l15_cpuflpr.overlay | 19 +++++++++---------- ...nrf54l15dk_nrf54l15_cpuflpr_icbmsg.overlay | 19 +++++++++---------- .../nrf54lc10dk_nrf54lc10a_cpuflpr.overlay | 19 +++++++++---------- ...54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay | 19 +++++++++---------- .../nrf54lm20dk_nrf54lm20a_cpuflpr.overlay | 19 +++++++++---------- ...54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay | 19 +++++++++---------- .../nrf54lv10dk_nrf54lv10a_cpuflpr.overlay | 19 +++++++++---------- ...54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay | 19 +++++++++---------- .../nrf7002dk_nrf5340_cpunet_icbmsg.overlay | 1 + .../nrf7002dk_nrf5340_cpunet_icmsg.overlay | 1 + .../boards/nrf7120dk_nrf7120_cpuflpr.overlay | 17 ++++++----------- 26 files changed, 164 insertions(+), 182 deletions(-) diff --git a/samples/ipc/ipc_service/boards/nrf5340dk_nrf5340_cpuapp_icbmsg.overlay b/samples/ipc/ipc_service/boards/nrf5340dk_nrf5340_cpuapp_icbmsg.overlay index 0b7ddbcf5229..ffe37bc8fbfe 100644 --- a/samples/ipc/ipc_service/boards/nrf5340dk_nrf5340_cpuapp_icbmsg.overlay +++ b/samples/ipc/ipc_service/boards/nrf5340dk_nrf5340_cpuapp_icbmsg.overlay @@ -16,6 +16,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_tx: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/samples/ipc/ipc_service/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay b/samples/ipc/ipc_service/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay index 7f063fbf7262..078b17ae8019 100644 --- a/samples/ipc/ipc_service/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay +++ b/samples/ipc/ipc_service/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay @@ -16,6 +16,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_tx: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/samples/ipc/ipc_service/boards/nrf54l15dk_nrf54l15_cpuapp.overlay b/samples/ipc/ipc_service/boards/nrf54l15dk_nrf54l15_cpuapp.overlay index 85c30e94c98c..6da3df03daea 100644 --- a/samples/ipc/ipc_service/boards/nrf54l15dk_nrf54l15_cpuapp.overlay +++ b/samples/ipc/ipc_service/boards/nrf54l15dk_nrf54l15_cpuapp.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20018000 { - reg = <0x20018000 0x8000>; - }; + sram_rx: memory@20018000 { + reg = <0x20018000 0x8000>; + }; - sram_tx: memory@20020000 { - reg = <0x20020000 0x8000>; - }; + sram_tx: memory@20020000 { + reg = <0x20020000 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/boards/nrf54l15dk_nrf54l15_cpuapp_icbmsg.overlay b/samples/ipc/ipc_service/boards/nrf54l15dk_nrf54l15_cpuapp_icbmsg.overlay index f57f3d75d723..6375f9f81dab 100644 --- a/samples/ipc/ipc_service/boards/nrf54l15dk_nrf54l15_cpuapp_icbmsg.overlay +++ b/samples/ipc/ipc_service/boards/nrf54l15dk_nrf54l15_cpuapp_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20018000 { - reg = <0x20018000 0x8000>; - }; + sram_rx: memory@20018000 { + reg = <0x20018000 0x8000>; + }; - sram_tx: memory@20020000 { - reg = <0x20020000 0x8000>; - }; + sram_tx: memory@20020000 { + reg = <0x20020000 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay b/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay index 32d2a9d75043..968175efa2e1 100644 --- a/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay +++ b/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay b/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay index 270560eceed4..8f4a11ee3179 100644 --- a/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay +++ b/samples/ipc/ipc_service/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay b/samples/ipc/ipc_service/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay index 8febba357bad..ded1212ff814 100644 --- a/samples/ipc/ipc_service/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay +++ b/samples/ipc/ipc_service/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_rx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_tx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_tx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay b/samples/ipc/ipc_service/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay index dcef6ade921f..b0cae920bcd6 100644 --- a/samples/ipc/ipc_service/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay +++ b/samples/ipc/ipc_service/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_rx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_tx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_tx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay b/samples/ipc/ipc_service/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay index cc5b63d4e16f..20839bdd93c1 100644 --- a/samples/ipc/ipc_service/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay +++ b/samples/ipc/ipc_service/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay b/samples/ipc/ipc_service/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay index d3e9f325b997..a7cec5db8eba 100644 --- a/samples/ipc/ipc_service/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay +++ b/samples/ipc/ipc_service/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/boards/nrf7002dk_nrf5340_cpuapp_icbmsg.overlay b/samples/ipc/ipc_service/boards/nrf7002dk_nrf5340_cpuapp_icbmsg.overlay index 0b7ddbcf5229..ffe37bc8fbfe 100644 --- a/samples/ipc/ipc_service/boards/nrf7002dk_nrf5340_cpuapp_icbmsg.overlay +++ b/samples/ipc/ipc_service/boards/nrf7002dk_nrf5340_cpuapp_icbmsg.overlay @@ -16,6 +16,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_tx: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/samples/ipc/ipc_service/boards/nrf7002dk_nrf5340_cpuapp_icmsg.overlay b/samples/ipc/ipc_service/boards/nrf7002dk_nrf5340_cpuapp_icmsg.overlay index 4596b37578a3..a47adbd39480 100644 --- a/samples/ipc/ipc_service/boards/nrf7002dk_nrf5340_cpuapp_icmsg.overlay +++ b/samples/ipc/ipc_service/boards/nrf7002dk_nrf5340_cpuapp_icmsg.overlay @@ -16,6 +16,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_tx: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/samples/ipc/ipc_service/boards/nrf7120dk_nrf7120_cpuapp.overlay b/samples/ipc/ipc_service/boards/nrf7120dk_nrf7120_cpuapp.overlay index de035b2e2e3d..dcb067363094 100644 --- a/samples/ipc/ipc_service/boards/nrf7120dk_nrf7120_cpuapp.overlay +++ b/samples/ipc/ipc_service/boards/nrf7120dk_nrf7120_cpuapp.overlay @@ -5,18 +5,13 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; - - sram_rx: memory@20080000 { - reg = <0x20080000 0x8000>; - }; + reserved-memory { + sram_rx: memory@20080000 { + reg = <0x20080000 0x8000>; + }; - sram_tx: memory@20088000 { - reg = <0x20088000 0x8000>; - }; + sram_tx: memory@20088000 { + reg = <0x20088000 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/remote/boards/nrf5340dk_nrf5340_cpunet_icbmsg.overlay b/samples/ipc/ipc_service/remote/boards/nrf5340dk_nrf5340_cpunet_icbmsg.overlay index 15b029d3e465..80a161caabbc 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf5340dk_nrf5340_cpunet_icbmsg.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf5340dk_nrf5340_cpunet_icbmsg.overlay @@ -15,6 +15,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/samples/ipc/ipc_service/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay b/samples/ipc/ipc_service/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay index ea76fc1eabee..422f9a68805b 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay @@ -15,6 +15,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54l15dk_nrf54l15_cpuflpr.overlay b/samples/ipc/ipc_service/remote/boards/nrf54l15dk_nrf54l15_cpuflpr.overlay index 123038696e97..1d878aa80bc0 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf54l15dk_nrf54l15_cpuflpr.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf54l15dk_nrf54l15_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20018000 { - reg = <0x20018000 0x8000>; - }; + sram_tx: memory@20018000 { + reg = <0x20018000 0x8000>; + }; - sram_rx: memory@20020000 { - reg = <0x20020000 0x8000>; - }; + sram_rx: memory@20020000 { + reg = <0x20020000 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54l15dk_nrf54l15_cpuflpr_icbmsg.overlay b/samples/ipc/ipc_service/remote/boards/nrf54l15dk_nrf54l15_cpuflpr_icbmsg.overlay index d56c31ee003b..0aeb497ab1ba 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf54l15dk_nrf54l15_cpuflpr_icbmsg.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf54l15dk_nrf54l15_cpuflpr_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20018000 { - reg = <0x20018000 0x8000>; - }; + sram_tx: memory@20018000 { + reg = <0x20018000 0x8000>; + }; - sram_rx: memory@20020000 { - reg = <0x20020000 0x8000>; - }; + sram_rx: memory@20020000 { + reg = <0x20020000 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay b/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay index d547e8617887..a00225d06d20 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay b/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay index 30a93ff5167a..ce34e38125ff 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay b/samples/ipc/ipc_service/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay index d11ccba2bc17..999e983e2d3b 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_tx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_rx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_rx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay b/samples/ipc/ipc_service/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay index 97640f81c22a..25227b0f80a5 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_tx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_rx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_rx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay b/samples/ipc/ipc_service/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay index eceab6d9442d..f94b6121f87d 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay b/samples/ipc/ipc_service/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay index 3cd570ce24d3..f0973b483ef3 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/ipc/ipc_service/remote/boards/nrf7002dk_nrf5340_cpunet_icbmsg.overlay b/samples/ipc/ipc_service/remote/boards/nrf7002dk_nrf5340_cpunet_icbmsg.overlay index 15b029d3e465..80a161caabbc 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf7002dk_nrf5340_cpunet_icbmsg.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf7002dk_nrf5340_cpunet_icbmsg.overlay @@ -15,6 +15,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/samples/ipc/ipc_service/remote/boards/nrf7002dk_nrf5340_cpunet_icmsg.overlay b/samples/ipc/ipc_service/remote/boards/nrf7002dk_nrf5340_cpunet_icmsg.overlay index ea76fc1eabee..422f9a68805b 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf7002dk_nrf5340_cpunet_icmsg.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf7002dk_nrf5340_cpunet_icmsg.overlay @@ -15,6 +15,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/samples/ipc/ipc_service/remote/boards/nrf7120dk_nrf7120_cpuflpr.overlay b/samples/ipc/ipc_service/remote/boards/nrf7120dk_nrf7120_cpuflpr.overlay index f112175d48b0..9c1665ac604e 100644 --- a/samples/ipc/ipc_service/remote/boards/nrf7120dk_nrf7120_cpuflpr.overlay +++ b/samples/ipc/ipc_service/remote/boards/nrf7120dk_nrf7120_cpuflpr.overlay @@ -5,18 +5,13 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; - - sram_tx: memory@20080000 { - reg = <0x20080000 0x8000>; - }; + reserved-memory { + sram_tx: memory@20080000 { + reg = <0x20080000 0x8000>; + }; - sram_rx: memory@20088000 { - reg = <0x20088000 0x8000>; - }; + sram_rx: memory@20088000 { + reg = <0x20088000 0x8000>; }; }; From ffa471f52f07b19a076d99a726f02602c31144a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Wed, 20 May 2026 11:08:08 +0200 Subject: [PATCH 24/37] samples: bluetooth: nrf_dm: Add ranges property to reserved-memory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Property "ranges" is required for "reserved-memory" node. Set it unless already done at the board definition level. Signed-off-by: Sebastian Głąb --- samples/bluetooth/nrf_dm/boards/nrf5340dk_nrf5340_cpuapp.overlay | 1 + .../sysbuild/ipc_radio/boards/nrf5340dk_nrf5340_cpunet.overlay | 1 + 2 files changed, 2 insertions(+) diff --git a/samples/bluetooth/nrf_dm/boards/nrf5340dk_nrf5340_cpuapp.overlay b/samples/bluetooth/nrf_dm/boards/nrf5340dk_nrf5340_cpuapp.overlay index 5d5e81ff20bc..fa316b1f2512 100644 --- a/samples/bluetooth/nrf_dm/boards/nrf5340dk_nrf5340_cpuapp.overlay +++ b/samples/bluetooth/nrf_dm/boards/nrf5340dk_nrf5340_cpuapp.overlay @@ -16,6 +16,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_ipc0: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/samples/bluetooth/nrf_dm/sysbuild/ipc_radio/boards/nrf5340dk_nrf5340_cpunet.overlay b/samples/bluetooth/nrf_dm/sysbuild/ipc_radio/boards/nrf5340dk_nrf5340_cpunet.overlay index e1fae4eacd78..855959071588 100644 --- a/samples/bluetooth/nrf_dm/sysbuild/ipc_radio/boards/nrf5340dk_nrf5340_cpunet.overlay +++ b/samples/bluetooth/nrf_dm/sysbuild/ipc_radio/boards/nrf5340dk_nrf5340_cpunet.overlay @@ -21,6 +21,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_ipc0: memory@20070000 { reg = <0x20070000 0x8000>; From bb7be4e0f526b3804e942ec724a9e81442640a6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Wed, 20 May 2026 11:30:08 +0200 Subject: [PATCH 25/37] samples: caf_sensor_manager: Add ranges property to reserved-memory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Property "ranges" is required for "reserved-memory" node. Set it unless already done at the board definition level. Signed-off-by: Sebastian Głąb --- .../remote/boards/nrf5340dk_nrf5340_cpunet.overlay | 1 + 1 file changed, 1 insertion(+) diff --git a/samples/caf_sensor_manager/remote/boards/nrf5340dk_nrf5340_cpunet.overlay b/samples/caf_sensor_manager/remote/boards/nrf5340dk_nrf5340_cpunet.overlay index 6302853056a7..837422b24221 100644 --- a/samples/caf_sensor_manager/remote/boards/nrf5340dk_nrf5340_cpunet.overlay +++ b/samples/caf_sensor_manager/remote/boards/nrf5340dk_nrf5340_cpunet.overlay @@ -8,6 +8,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram0_aggregator_area0: memory@2007f000 { reg = <0x2007f000 0x1000>; From aac528fd769d1ff03799899f366391596422d1bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Wed, 20 May 2026 11:32:08 +0200 Subject: [PATCH 26/37] samples: event_manager_proxy: Add ranges property to reserved-memory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Property "ranges" is required for "reserved-memory" node. Set it unless already done at the board definition level. "reserved-memory" node must be placed under root node. Fix overlays for all platforms. Signed-off-by: Sebastian Głąb --- .../nrf5340dk_nrf5340_cpuapp_icmsg.overlay | 1 + .../boards/nrf54l15dk_nrf54l15_cpuapp.overlay | 19 +++++++++---------- .../nrf54lc10dk_nrf54lc10a_cpuapp.overlay | 19 +++++++++---------- .../nrf54lm20dk_nrf54lm20a_cpuapp.overlay | 19 +++++++++---------- .../nrf54lv10dk_nrf54lv10a_cpuapp.overlay | 19 +++++++++---------- .../nrf5340dk_nrf5340_cpunet_icmsg.overlay | 1 + .../nrf54l15dk_nrf54l15_cpuflpr.overlay | 19 +++++++++---------- .../nrf54lc10dk_nrf54lc10a_cpuflpr.overlay | 19 +++++++++---------- .../nrf54lm20dk_nrf54lm20a_cpuflpr.overlay | 19 +++++++++---------- .../nrf54lv10dk_nrf54lv10a_cpuflpr.overlay | 19 +++++++++---------- 10 files changed, 74 insertions(+), 80 deletions(-) diff --git a/samples/event_manager_proxy/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay b/samples/event_manager_proxy/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay index 54a07de6e88b..bea02cde8cf5 100644 --- a/samples/event_manager_proxy/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay +++ b/samples/event_manager_proxy/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay @@ -16,6 +16,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_tx: memory@20070000 { reg = <0x20070000 0x0800>; diff --git a/samples/event_manager_proxy/boards/nrf54l15dk_nrf54l15_cpuapp.overlay b/samples/event_manager_proxy/boards/nrf54l15dk_nrf54l15_cpuapp.overlay index e6ab04a8114a..7d0a720f13b0 100644 --- a/samples/event_manager_proxy/boards/nrf54l15dk_nrf54l15_cpuapp.overlay +++ b/samples/event_manager_proxy/boards/nrf54l15dk_nrf54l15_cpuapp.overlay @@ -9,18 +9,17 @@ /delete-property/ zephyr,bt-hci; }; - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20018000 { - reg = <0x20018000 0x8000>; - }; + sram_rx: memory@20018000 { + reg = <0x20018000 0x8000>; + }; - sram_tx: memory@20020000 { - reg = <0x20020000 0x8000>; - }; + sram_tx: memory@20020000 { + reg = <0x20020000 0x8000>; }; }; diff --git a/samples/event_manager_proxy/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay b/samples/event_manager_proxy/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay index caae937b1a90..7027e6f86b67 100644 --- a/samples/event_manager_proxy/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay +++ b/samples/event_manager_proxy/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay @@ -9,18 +9,17 @@ /delete-property/ zephyr,bt-hci; }; - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/event_manager_proxy/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay b/samples/event_manager_proxy/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay index 5cbdb661acc3..0d215a1bafaa 100644 --- a/samples/event_manager_proxy/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay +++ b/samples/event_manager_proxy/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay @@ -9,18 +9,17 @@ /delete-property/ zephyr,bt-hci; }; - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_rx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_tx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_tx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/event_manager_proxy/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay b/samples/event_manager_proxy/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay index 3fb6b5644450..52c2e8f81bd6 100644 --- a/samples/event_manager_proxy/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay +++ b/samples/event_manager_proxy/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay @@ -9,18 +9,17 @@ /delete-property/ zephyr,bt-hci; }; - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/event_manager_proxy/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay b/samples/event_manager_proxy/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay index 4be2cd2bd177..671da574a797 100644 --- a/samples/event_manager_proxy/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay +++ b/samples/event_manager_proxy/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay @@ -15,6 +15,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@20070000 { reg = <0x20070000 0x0800>; diff --git a/samples/event_manager_proxy/remote/boards/nrf54l15dk_nrf54l15_cpuflpr.overlay b/samples/event_manager_proxy/remote/boards/nrf54l15dk_nrf54l15_cpuflpr.overlay index 123038696e97..1d878aa80bc0 100644 --- a/samples/event_manager_proxy/remote/boards/nrf54l15dk_nrf54l15_cpuflpr.overlay +++ b/samples/event_manager_proxy/remote/boards/nrf54l15dk_nrf54l15_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20018000 { - reg = <0x20018000 0x8000>; - }; + sram_tx: memory@20018000 { + reg = <0x20018000 0x8000>; + }; - sram_rx: memory@20020000 { - reg = <0x20020000 0x8000>; - }; + sram_rx: memory@20020000 { + reg = <0x20020000 0x8000>; }; }; diff --git a/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay b/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay index d547e8617887..a00225d06d20 100644 --- a/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay +++ b/samples/event_manager_proxy/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/event_manager_proxy/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay b/samples/event_manager_proxy/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay index d11ccba2bc17..999e983e2d3b 100644 --- a/samples/event_manager_proxy/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay +++ b/samples/event_manager_proxy/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_tx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_rx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_rx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/event_manager_proxy/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay b/samples/event_manager_proxy/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay index eceab6d9442d..f94b6121f87d 100644 --- a/samples/event_manager_proxy/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay +++ b/samples/event_manager_proxy/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; From fdba9b4c4faeac8844849e655f44cf451634f586 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Wed, 20 May 2026 11:33:36 +0200 Subject: [PATCH 27/37] samples: zephyr: subsys: ipc: Add ranges property to reserved-memory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Property "ranges" is required for "reserved-memory" node. Set it unless already done at the board definition level. "reserved-memory" node must be placed under root node. Fix overlays for all platforms. Signed-off-by: Sebastian Głąb --- .../nrf54lc10dk_nrf54lc10a_cpuapp.overlay | 19 +++++++++---------- ...f54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay | 19 +++++++++---------- .../nrf54lm20dk_nrf54lm20a_cpuapp.overlay | 19 +++++++++---------- ...f54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay | 19 +++++++++---------- .../nrf54lv10dk_nrf54lv10a_cpuapp.overlay | 19 +++++++++---------- ...f54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay | 19 +++++++++---------- .../nrf54lc10dk_nrf54lc10a_cpuflpr.overlay | 19 +++++++++---------- ...54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay | 19 +++++++++---------- .../nrf54lm20dk_nrf54lm20a_cpuflpr.overlay | 19 +++++++++---------- ...54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay | 19 +++++++++---------- .../nrf54lv10dk_nrf54lv10a_cpuflpr.overlay | 19 +++++++++---------- ...54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay | 19 +++++++++---------- 12 files changed, 108 insertions(+), 120 deletions(-) diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay index 32d2a9d75043..968175efa2e1 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay index 270560eceed4..8f4a11ee3179 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lc10dk_nrf54lc10a_cpuapp_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay index 33afb300d789..77ab15ed6d90 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lm20dk_nrf54lm20a_cpuapp.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_rx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_tx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_tx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay index c2f345bfcb26..cb44f1ee29b9 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_rx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_tx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_tx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay index cc5b63d4e16f..20839bdd93c1 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lv10dk_nrf54lv10a_cpuapp.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay index d3e9f325b997..a7cec5db8eba 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay index d547e8617887..a00225d06d20 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay index 30a93ff5167a..ce34e38125ff 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lc10dk_nrf54lc10a_cpuflpr_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay index 7aa2e5fa557b..772b0544f8c8 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_tx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_rx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_rx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay index 3c79d1ae9d62..916d54b81dbc 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_tx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_rx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_rx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay index eceab6d9442d..f94b6121f87d 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay index 3cd570ce24d3..f0973b483ef3 100644 --- a/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay +++ b/samples/zephyr/subsys/ipc/ipc_service/icmsg/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icbmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; From 385e7d5fd9de70c0273edb6e0349cd33c9dd7d1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Wed, 20 May 2026 11:35:11 +0200 Subject: [PATCH 28/37] tests: subsys: event_manager_proxy: Add ranges to reserved-memory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Property "ranges" is required for "reserved-memory" node. Set it unless already done at the board definition level. "reserved-memory" node must be placed under root node. Fix overlays for all platforms. Signed-off-by: Sebastian Głąb --- .../nrf5340dk_nrf5340_cpuapp_icmsg.overlay | 1 + .../nrf54l15dk_nrf54l15_cpuapp_icmsg.overlay | 19 +++++++++---------- ...rf54lm20dk_nrf54lm20a_cpuapp_icmsg.overlay | 19 +++++++++---------- ...rf54lv10dk_nrf54lv10a_cpuapp_icmsg.overlay | 19 +++++++++---------- .../nrf5340dk_nrf5340_cpunet_icmsg.overlay | 1 + .../nrf54l15dk_nrf54l15_cpuflpr_icmsg.overlay | 19 +++++++++---------- ...f54lm20dk_nrf54lm20a_cpuflpr_icmsg.overlay | 19 +++++++++---------- ...f54lv10dk_nrf54lv10a_cpuflpr_icmsg.overlay | 19 +++++++++---------- 8 files changed, 56 insertions(+), 60 deletions(-) diff --git a/tests/subsys/event_manager_proxy/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay b/tests/subsys/event_manager_proxy/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay index 54a07de6e88b..bea02cde8cf5 100644 --- a/tests/subsys/event_manager_proxy/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay +++ b/tests/subsys/event_manager_proxy/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay @@ -16,6 +16,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_tx: memory@20070000 { reg = <0x20070000 0x0800>; diff --git a/tests/subsys/event_manager_proxy/boards/nrf54l15dk_nrf54l15_cpuapp_icmsg.overlay b/tests/subsys/event_manager_proxy/boards/nrf54l15dk_nrf54l15_cpuapp_icmsg.overlay index e6ab04a8114a..7d0a720f13b0 100644 --- a/tests/subsys/event_manager_proxy/boards/nrf54l15dk_nrf54l15_cpuapp_icmsg.overlay +++ b/tests/subsys/event_manager_proxy/boards/nrf54l15dk_nrf54l15_cpuapp_icmsg.overlay @@ -9,18 +9,17 @@ /delete-property/ zephyr,bt-hci; }; - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20018000 { - reg = <0x20018000 0x8000>; - }; + sram_rx: memory@20018000 { + reg = <0x20018000 0x8000>; + }; - sram_tx: memory@20020000 { - reg = <0x20020000 0x8000>; - }; + sram_tx: memory@20020000 { + reg = <0x20020000 0x8000>; }; }; diff --git a/tests/subsys/event_manager_proxy/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icmsg.overlay b/tests/subsys/event_manager_proxy/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icmsg.overlay index 5cbdb661acc3..0d215a1bafaa 100644 --- a/tests/subsys/event_manager_proxy/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icmsg.overlay +++ b/tests/subsys/event_manager_proxy/boards/nrf54lm20dk_nrf54lm20a_cpuapp_icmsg.overlay @@ -9,18 +9,17 @@ /delete-property/ zephyr,bt-hci; }; - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_rx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_tx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_tx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/tests/subsys/event_manager_proxy/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icmsg.overlay b/tests/subsys/event_manager_proxy/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icmsg.overlay index 3fb6b5644450..52c2e8f81bd6 100644 --- a/tests/subsys/event_manager_proxy/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icmsg.overlay +++ b/tests/subsys/event_manager_proxy/boards/nrf54lv10dk_nrf54lv10a_cpuapp_icmsg.overlay @@ -9,18 +9,17 @@ /delete-property/ zephyr,bt-hci; }; - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_rx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_tx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_tx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; diff --git a/tests/subsys/event_manager_proxy/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay b/tests/subsys/event_manager_proxy/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay index 4be2cd2bd177..671da574a797 100644 --- a/tests/subsys/event_manager_proxy/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay +++ b/tests/subsys/event_manager_proxy/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay @@ -15,6 +15,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@20070000 { reg = <0x20070000 0x0800>; diff --git a/tests/subsys/event_manager_proxy/remote/boards/nrf54l15dk_nrf54l15_cpuflpr_icmsg.overlay b/tests/subsys/event_manager_proxy/remote/boards/nrf54l15dk_nrf54l15_cpuflpr_icmsg.overlay index 123038696e97..1d878aa80bc0 100644 --- a/tests/subsys/event_manager_proxy/remote/boards/nrf54l15dk_nrf54l15_cpuflpr_icmsg.overlay +++ b/tests/subsys/event_manager_proxy/remote/boards/nrf54l15dk_nrf54l15_cpuflpr_icmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20018000 { - reg = <0x20018000 0x8000>; - }; + sram_tx: memory@20018000 { + reg = <0x20018000 0x8000>; + }; - sram_rx: memory@20020000 { - reg = <0x20020000 0x8000>; - }; + sram_rx: memory@20020000 { + reg = <0x20020000 0x8000>; }; }; diff --git a/tests/subsys/event_manager_proxy/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icmsg.overlay b/tests/subsys/event_manager_proxy/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icmsg.overlay index d11ccba2bc17..999e983e2d3b 100644 --- a/tests/subsys/event_manager_proxy/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icmsg.overlay +++ b/tests/subsys/event_manager_proxy/remote/boards/nrf54lm20dk_nrf54lm20a_cpuflpr_icmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20057c00 { - reg = <0x20057c00 0x8000>; - }; + sram_tx: memory@20057c00 { + reg = <0x20057c00 0x8000>; + }; - sram_rx: memory@2005fc00 { - reg = <0x2005fc00 0x8000>; - }; + sram_rx: memory@2005fc00 { + reg = <0x2005fc00 0x8000>; }; }; diff --git a/tests/subsys/event_manager_proxy/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icmsg.overlay b/tests/subsys/event_manager_proxy/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icmsg.overlay index eceab6d9442d..f94b6121f87d 100644 --- a/tests/subsys/event_manager_proxy/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icmsg.overlay +++ b/tests/subsys/event_manager_proxy/remote/boards/nrf54lv10dk_nrf54lv10a_cpuflpr_icmsg.overlay @@ -5,18 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@2000fc00 { - reg = <0x2000fc00 0x8000>; - }; + sram_tx: memory@2000fc00 { + reg = <0x2000fc00 0x8000>; + }; - sram_rx: memory@20017c00 { - reg = <0x20017c00 0x8000>; - }; + sram_rx: memory@20017c00 { + reg = <0x20017c00 0x8000>; }; }; From 3b28d03a631a59e9768264971464eb99bf4b31cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Wed, 20 May 2026 11:36:06 +0200 Subject: [PATCH 29/37] tests: subsys: ipc: ipc_latency: Add ranges to reserved-memory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Property "ranges" is required for "reserved-memory" node. Set it unless already done at the board definition level. Signed-off-by: Sebastian Głąb --- .../ipc_latency/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay | 1 + .../remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay | 1 + 2 files changed, 2 insertions(+) diff --git a/tests/subsys/ipc/ipc_latency/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay b/tests/subsys/ipc/ipc_latency/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay index 08965de1d7df..d82942f43ebf 100644 --- a/tests/subsys/ipc/ipc_latency/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay +++ b/tests/subsys/ipc/ipc_latency/boards/nrf5340dk_nrf5340_cpuapp_icmsg.overlay @@ -22,6 +22,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_tx: memory@20070000 { reg = <0x20070000 0x8000>; diff --git a/tests/subsys/ipc/ipc_latency/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay b/tests/subsys/ipc/ipc_latency/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay index 2f54e7fcac33..566737d44d9e 100644 --- a/tests/subsys/ipc/ipc_latency/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay +++ b/tests/subsys/ipc/ipc_latency/remote/boards/nrf5340dk_nrf5340_cpunet_icmsg.overlay @@ -15,6 +15,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@20070000 { reg = <0x20070000 0x8000>; From 620110373256ed23e5a82571761936f4f026aa6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Wed, 20 May 2026 11:37:16 +0200 Subject: [PATCH 30/37] snippets: hpf: mspi: Add ranges property to reserved-memory MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Property "ranges" is required for "reserved-memory" node. Set it unless already done at the board definition level. Signed-off-by: Sebastian Głąb --- snippets/hpf/mspi/soc/nrf54l15_cpuapp.overlay | 1 + snippets/hpf/mspi/soc/nrf54lm20a_cpuapp.overlay | 1 + snippets/hpf/mspi/soc/nrf54lv10a_cpuapp.overlay | 1 + 3 files changed, 3 insertions(+) diff --git a/snippets/hpf/mspi/soc/nrf54l15_cpuapp.overlay b/snippets/hpf/mspi/soc/nrf54l15_cpuapp.overlay index 475820317647..f2ea7a3d500f 100644 --- a/snippets/hpf/mspi/soc/nrf54l15_cpuapp.overlay +++ b/snippets/hpf/mspi/soc/nrf54l15_cpuapp.overlay @@ -8,6 +8,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@2003b400 { reg = <0x2003b400 0x07f0>; diff --git a/snippets/hpf/mspi/soc/nrf54lm20a_cpuapp.overlay b/snippets/hpf/mspi/soc/nrf54lm20a_cpuapp.overlay index 40a1c164d77d..d0bb3ca53687 100644 --- a/snippets/hpf/mspi/soc/nrf54lm20a_cpuapp.overlay +++ b/snippets/hpf/mspi/soc/nrf54lm20a_cpuapp.overlay @@ -12,6 +12,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@2007a800 { reg = <0x2007a800 0x0c00>; diff --git a/snippets/hpf/mspi/soc/nrf54lv10a_cpuapp.overlay b/snippets/hpf/mspi/soc/nrf54lv10a_cpuapp.overlay index bbbc3e8af2a6..016dd90bd121 100644 --- a/snippets/hpf/mspi/soc/nrf54lv10a_cpuapp.overlay +++ b/snippets/hpf/mspi/soc/nrf54lv10a_cpuapp.overlay @@ -8,6 +8,7 @@ reserved-memory { #address-cells = <1>; #size-cells = <1>; + ranges; sram_rx: memory@2002b000 { reg = <0x2002b000 0x07f0>; From ec2978666faa470fab85c1292b5acaea521aa850 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Wed, 20 May 2026 11:38:23 +0200 Subject: [PATCH 31/37] snippets: hpf: gpio: Improve "reserved-memory" node MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit "reserved-memory" node must be placed under root node. Signed-off-by: Sebastian Głąb --- .../gpio/icbmsg/soc/nrf7120_cpuapp.overlay | 20 +++++++++---------- .../gpio/icbmsg/soc/nrf7120_cpuflpr.overlay | 20 +++++++++---------- .../hpf/gpio/icmsg/soc/nrf7120_cpuapp.overlay | 20 +++++++++---------- .../gpio/icmsg/soc/nrf7120_cpuflpr.overlay | 20 +++++++++---------- .../hpf/gpio/mbox/soc/nrf7120_cpuapp.overlay | 20 +++++++++---------- .../hpf/gpio/mbox/soc/nrf7120_cpuflpr.overlay | 20 +++++++++---------- 6 files changed, 54 insertions(+), 66 deletions(-) diff --git a/snippets/hpf/gpio/icbmsg/soc/nrf7120_cpuapp.overlay b/snippets/hpf/gpio/icbmsg/soc/nrf7120_cpuapp.overlay index bf10749031da..a816cd21984e 100644 --- a/snippets/hpf/gpio/icbmsg/soc/nrf7120_cpuapp.overlay +++ b/snippets/hpf/gpio/icbmsg/soc/nrf7120_cpuapp.overlay @@ -7,19 +7,17 @@ #include "../../hpf-gpio-app.overlay" / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; - ranges; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20080000 { - reg = <0x20080000 0x0800>; - }; + sram_rx: memory@20080000 { + reg = <0x20080000 0x0800>; + }; - sram_tx: memory@20080800 { - reg = <0x20080800 0x0800>; - }; + sram_tx: memory@20080800 { + reg = <0x20080800 0x0800>; }; }; diff --git a/snippets/hpf/gpio/icbmsg/soc/nrf7120_cpuflpr.overlay b/snippets/hpf/gpio/icbmsg/soc/nrf7120_cpuflpr.overlay index a1ac57239f91..c88110bf2507 100644 --- a/snippets/hpf/gpio/icbmsg/soc/nrf7120_cpuflpr.overlay +++ b/snippets/hpf/gpio/icbmsg/soc/nrf7120_cpuflpr.overlay @@ -5,19 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; - ranges; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20080000 { - reg = <0x20080000 0x0800>; - }; + sram_tx: memory@20080000 { + reg = <0x20080000 0x0800>; + }; - sram_rx: memory@20080800 { - reg = <0x20080800 0x0800>; - }; + sram_rx: memory@20080800 { + reg = <0x20080800 0x0800>; }; }; diff --git a/snippets/hpf/gpio/icmsg/soc/nrf7120_cpuapp.overlay b/snippets/hpf/gpio/icmsg/soc/nrf7120_cpuapp.overlay index e4abddff69f1..b275f6ae8d00 100644 --- a/snippets/hpf/gpio/icmsg/soc/nrf7120_cpuapp.overlay +++ b/snippets/hpf/gpio/icmsg/soc/nrf7120_cpuapp.overlay @@ -7,19 +7,17 @@ #include "../../hpf-gpio-app.overlay" / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; - ranges; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20080000 { - reg = <0x20080000 0x0800>; - }; + sram_rx: memory@20080000 { + reg = <0x20080000 0x0800>; + }; - sram_tx: memory@20080800 { - reg = <0x20080800 0x0800>; - }; + sram_tx: memory@20080800 { + reg = <0x20080800 0x0800>; }; }; diff --git a/snippets/hpf/gpio/icmsg/soc/nrf7120_cpuflpr.overlay b/snippets/hpf/gpio/icmsg/soc/nrf7120_cpuflpr.overlay index 974f7706b0da..c58ac0a89bd0 100644 --- a/snippets/hpf/gpio/icmsg/soc/nrf7120_cpuflpr.overlay +++ b/snippets/hpf/gpio/icmsg/soc/nrf7120_cpuflpr.overlay @@ -5,19 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; - ranges; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20080000 { - reg = <0x20080000 0x0800>; - }; + sram_tx: memory@20080000 { + reg = <0x20080000 0x0800>; + }; - sram_rx: memory@20080800 { - reg = <0x20080800 0x0800>; - }; + sram_rx: memory@20080800 { + reg = <0x20080800 0x0800>; }; }; diff --git a/snippets/hpf/gpio/mbox/soc/nrf7120_cpuapp.overlay b/snippets/hpf/gpio/mbox/soc/nrf7120_cpuapp.overlay index 3e4d9e99dc7e..e9fc343f699a 100644 --- a/snippets/hpf/gpio/mbox/soc/nrf7120_cpuapp.overlay +++ b/snippets/hpf/gpio/mbox/soc/nrf7120_cpuapp.overlay @@ -7,19 +7,17 @@ #include "../../hpf-gpio-app.overlay" / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; - ranges; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_rx: memory@20080000 { - reg = <0x20080000 0x0800>; - }; + sram_rx: memory@20080000 { + reg = <0x20080000 0x0800>; + }; - sram_tx: memory@20080800 { - reg = <0x20080800 0x0800>; - }; + sram_tx: memory@20080800 { + reg = <0x20080800 0x0800>; }; }; diff --git a/snippets/hpf/gpio/mbox/soc/nrf7120_cpuflpr.overlay b/snippets/hpf/gpio/mbox/soc/nrf7120_cpuflpr.overlay index 5972bc257a23..db2cd48ad2f4 100644 --- a/snippets/hpf/gpio/mbox/soc/nrf7120_cpuflpr.overlay +++ b/snippets/hpf/gpio/mbox/soc/nrf7120_cpuflpr.overlay @@ -5,19 +5,17 @@ */ / { - soc { - reserved-memory { - #address-cells = <1>; - #size-cells = <1>; - ranges; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; - sram_tx: memory@20080000 { - reg = <0x20080000 0x0800>; - }; + sram_tx: memory@20080000 { + reg = <0x20080000 0x0800>; + }; - sram_rx: memory@20080800 { - reg = <0x20080800 0x0800>; - }; + sram_rx: memory@20080800 { + reg = <0x20080800 0x0800>; }; }; From fd531aba258f86b539b9c24d52fc10225b1d7916 Mon Sep 17 00:00:00 2001 From: Uma Praseeda Date: Thu, 21 May 2026 14:13:46 +0200 Subject: [PATCH 32/37] doc: Temp revert for theme Temp revert PR for theme Signed-off-by: Uma Praseeda --- doc/kconfig/conf.py | 2 -- doc/matter/conf.py | 2 -- doc/mcuboot/conf.py | 3 --- doc/nrf/conf.py | 3 +-- doc/nrfxlib/conf.py | 3 +-- doc/requirements.txt | 2 +- doc/tfm/conf.py | 2 -- doc/zephyr/conf.py | 2 -- 8 files changed, 3 insertions(+), 16 deletions(-) diff --git a/doc/kconfig/conf.py b/doc/kconfig/conf.py index 042c7fae87b4..922666a49899 100644 --- a/doc/kconfig/conf.py +++ b/doc/kconfig/conf.py @@ -43,8 +43,6 @@ html_theme_options = { "docset": "kconfig", "docsets": utils.ALL_DOCSETS, - "prev_next_buttons_location": None, - "logo_url": "https://docs.nordicsemi.com" } # Options for external_content ------------------------------------------------- diff --git a/doc/matter/conf.py b/doc/matter/conf.py index 3b088962e632..d29b3f8674a0 100644 --- a/doc/matter/conf.py +++ b/doc/matter/conf.py @@ -49,8 +49,6 @@ "docset": "matter", "docsets": utils.ALL_DOCSETS, "subtitle": "nRF Connect SDK", - "collapse_navigation": False, - "logo_url": "https://docs.nordicsemi.com" } # Options for warnings_filter -------------------------------------------------- diff --git a/doc/mcuboot/conf.py b/doc/mcuboot/conf.py index 069488315f10..13613a1cf3e9 100644 --- a/doc/mcuboot/conf.py +++ b/doc/mcuboot/conf.py @@ -34,7 +34,6 @@ "sphinx.ext.intersphinx", "recommonmark", "sphinx_markdown_tables", - "sphinxcontrib.jquery", "zephyr.external_content" ] source_suffix = [".rst", ".md"] @@ -60,8 +59,6 @@ "docset": "mcuboot", "docsets": utils.ALL_DOCSETS, "subtitle": "nRF Connect SDK", - "collapse_navigation": False, - "logo_url": "https://docs.nordicsemi.com" } # Options for intersphinx ------------------------------------------------------ diff --git a/doc/nrf/conf.py b/doc/nrf/conf.py index 5df30562e8f6..a67eee2e7d93 100644 --- a/doc/nrf/conf.py +++ b/doc/nrf/conf.py @@ -57,7 +57,6 @@ "page_filter", "sphinxcontrib.plantuml", "sphinxcontrib.programoutput", - "sphinxcontrib.jquery" ] linkcheck_ignore = [ @@ -92,7 +91,7 @@ html_show_sourcelink = True html_show_sphinx = False -html_theme_options = {"docset": "nrf", "docsets": utils.ALL_DOCSETS, "logo_url": "https://docs.nordicsemi.com/"} +html_theme_options = {"docset": "nrf", "docsets": utils.ALL_DOCSETS} # Options for intersphinx ------------------------------------------------------ diff --git a/doc/nrfxlib/conf.py b/doc/nrfxlib/conf.py index b4bfbd09ba25..f3bd880df043 100644 --- a/doc/nrfxlib/conf.py +++ b/doc/nrfxlib/conf.py @@ -32,7 +32,6 @@ extensions = [ "sphinx.ext.intersphinx", - "sphinxcontrib.jquery", "sphinxcontrib.mscgen", "inventory_builder", "warnings_filter", @@ -60,7 +59,7 @@ html_show_sourcelink = True html_show_sphinx = False -html_theme_options = {"docset": "nrfxlib", "docsets": utils.ALL_DOCSETS, "logo_url": "https://docs.nordicsemi.com/"} +html_theme_options = {"docset": "nrfxlib", "docsets": utils.ALL_DOCSETS} # Options for intersphinx ------------------------------------------------------ diff --git a/doc/requirements.txt b/doc/requirements.txt index 973430027492..fc0c47283c40 100644 --- a/doc/requirements.txt +++ b/doc/requirements.txt @@ -20,7 +20,7 @@ snowballstemmer<3.0.0 # https://github.com/snowballstem/snowball/issue sphinx>=8.1,<8.2 # | X | X | X | X | X | X | X | sphinx-autobuild # | X | X | X | X | X | X | X | sphinx-copybutton # | X | | | | | | X | -sphinx-ncs-theme<2.1 # | X | | | | | | | +sphinx-ncs-theme<1.1 # | X | | | | | | | sphinx-notfound-page>=1.0.0 # | X | | | | | | X | sphinx-tabs>=3.4 # | X | | | | | | X | sphinx-togglebutton # | X | | | | | | X | diff --git a/doc/tfm/conf.py b/doc/tfm/conf.py index a74daf03c305..bf8769170a1d 100644 --- a/doc/tfm/conf.py +++ b/doc/tfm/conf.py @@ -68,8 +68,6 @@ "docset": "tfm", "docsets": utils.ALL_DOCSETS, "subtitle": "nRF Connect SDK", - "collapse_navigation": False, - "logo_url": "https://docs.nordicsemi.com/" } # Options for autosectionlabel ------------------------------------------------- diff --git a/doc/zephyr/conf.py b/doc/zephyr/conf.py index 7bbdd41eea9e..bcba8e4451c5 100644 --- a/doc/zephyr/conf.py +++ b/doc/zephyr/conf.py @@ -59,8 +59,6 @@ "docset": "zephyr", "docsets": utils.ALL_DOCSETS, "subtitle": "nRF Connect SDK", - "collapse_navigation": False, - "logo_url": "https://docs.nordicsemi.com/" } # Options for intersphinx ------------------------------------------------------ From c4cdd5b7a91eb60163377b16bc2e1a3b493fdeb5 Mon Sep 17 00:00:00 2001 From: Nordic Builder Date: Wed, 13 May 2026 08:54:37 +0000 Subject: [PATCH 33/37] 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/4076 Signed-off-by: Nordic Builder --- west.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/west.yml b/west.yml index 00818c13b05a..519e7a553d7c 100644 --- a/west.yml +++ b/west.yml @@ -65,7 +65,7 @@ manifest: # https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/guides/modules.html - name: zephyr repo-path: sdk-zephyr - revision: 76c2f9407d6caaa66a148321b3618fc8b5f993a6 + revision: ecbc745ca398363d241e71af35ce643c73cc6bd3 import: # In addition to the zephyr repository itself, NCS also # imports the contents of zephyr/west.yml at the above From 1d29fa5a94ace29e788e18edec7ed628a3a42136 Mon Sep 17 00:00:00 2001 From: Nordic Builder Date: Thu, 21 May 2026 08:38:54 +0000 Subject: [PATCH 34/37] manifest: Update sdk-connectedhomeip revision (auto-manifest PR) Automatically created by action-manifest-pr GH action from PR: https://github.com/nrfconnect/sdk-connectedhomeip/pull/721 Signed-off-by: Nordic Builder --- west.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/west.yml b/west.yml index 519e7a553d7c..312e9a8fcdb8 100644 --- a/west.yml +++ b/west.yml @@ -156,7 +156,7 @@ manifest: - name: matter repo-path: sdk-connectedhomeip path: modules/lib/matter - revision: 50a2175e80c5d6a7752083a08887fa8360ae7a7f + revision: 4ad89bf237fff34d7f2195bd027f906d750f2637 west-commands: scripts/west/west-commands.yml submodules: - name: nlio From 032927bd5e108158b9c591c9b8467c057c60b3b4 Mon Sep 17 00:00:00 2001 From: Artur Hadasz Date: Fri, 8 May 2026 10:24:22 +0200 Subject: [PATCH 35/37] bluetooth: hids: Add support for HID SCI Add support for HID Shorter Connection Intervals on the HID device side. Signed-off-by: Artur Hadasz --- doc/nrf/links.txt | 2 +- include/bluetooth/services/hids.h | 150 +++++- subsys/bluetooth/services/Kconfig.hids | 2 + subsys/bluetooth/services/Kconfig.hids.sci | 78 +++ .../services/Kconfig.template.hids.sci_mode | 72 +++ subsys/bluetooth/services/hids.c | 480 +++++++++++++++++- 6 files changed, 763 insertions(+), 21 deletions(-) create mode 100644 subsys/bluetooth/services/Kconfig.hids.sci create mode 100644 subsys/bluetooth/services/Kconfig.template.hids.sci_mode diff --git a/doc/nrf/links.txt b/doc/nrf/links.txt index 26ceaf569a7c..8bc725edaf4c 100644 --- a/doc/nrf/links.txt +++ b/doc/nrf/links.txt @@ -1286,7 +1286,7 @@ .. _`Join Bluetooth SIG`: https://www.bluetooth.com/develop-with-bluetooth/join/ -.. _`HID Service Specification`: https://www.bluetooth.org/docman/handlers/downloaddoc.ashx?doc_id=245140 +.. _`HID Service Specification`: https://www.bluetooth.com/specifications/specs/hid-service-specification/ .. _`Battery Service Specification`: https://www.bluetooth.org/docman/handlers/downloaddoc.ashx?doc_id=245138 .. _`Bluetooth Low Energy RF PHY Test Specification`: https://www.bluetooth.org/docman/handlers/DownloadDoc.ashx?doc_id=225827 .. _`Bond Management Service Specification`: https://www.bluetooth.org/docman/handlers/downloaddoc.ashx?doc_id=293524 diff --git a/include/bluetooth/services/hids.h b/include/bluetooth/services/hids.h index de469fab967c..1063c7e07685 100644 --- a/include/bluetooth/services/hids.h +++ b/include/bluetooth/services/hids.h @@ -44,6 +44,21 @@ extern "C" { /** Length of encoded HID Information. */ #define BT_HIDS_INFORMATION_LEN 4 +/** Maximum number of connection interval groups in HID SCI Information. */ +#define BT_HIDS_SCI_INFORMATION_MAX_GROUPS BT_CONN_LE_MAX_CONN_INTERVAL_GROUPS + +/** Max length of encoded HID SCI Information based on the HIDS specification: + * Minimum supported conn interval (1 B) + Num groups (1 B) + + * Num groups * (Group Min (2 B) + Group Max (2 B) + Group Stride (2 B)). + */ +#define BT_HIDS_SCI_INFORMATION_MAX_LEN (1 + 1 + BT_HIDS_SCI_INFORMATION_MAX_GROUPS * (2 + 2 + 2)) +#define BT_HIDS_SCI_INFORMATION_MIN_LEN 2 + +/** The transport interval which the device must support to be compliant + * with the HID over GATT Profile specification (chapter 7.4). + */ +#define BT_HIDS_MAX_MINIMAL_TRANSPORT_INTERVAL_US 1250 + /** * @brief Declare a HIDS instance. * @@ -116,15 +131,37 @@ enum bt_hids_flags { BT_HIDS_REMOTE_WAKE = BIT(0), /** Device advertises when bonded but not connected. */ BT_HIDS_NORMALLY_CONNECTABLE = BIT(1), + /** Device is capable of supporting the HID SCI feature */ + BT_HIDS_SCI_SUPPORTED = BIT(2), + /** Device is capable of supporting the HID SCI Low Power mode feature */ + BT_HIDS_SCI_LOW_POWER_MODE_SUPPORTED = BIT(3), }; -/** @brief HID Control Point settings. */ -enum bt_hids_control_point { +/** + * @brief HID Control Point settings. + * + * @deprecated Use @ref bt_hids_cp_evt instead + */ +__deprecated enum bt_hids_control_point { /** Suspend value for Control Point. */ BT_HIDS_CONTROL_POINT_SUSPEND = 0x00, /** Exit suspend value for Control Point.*/ - BT_HIDS_CONTROL_POINT_EXIT_SUSPEND = 0x01 + BT_HIDS_CONTROL_POINT_EXIT_SUSPEND = 0x01, +}; + +/** @brief HID SCI Mode values */ +enum bt_hids_sci_mode_value { + /** SCI None mode. */ + BT_HIDS_SCI_MODE_NONE = 0x00, + /** SCI Default mode. */ + BT_HIDS_SCI_MODE_DEFAULT = 0x02, + /** SCI Fast mode. */ + BT_HIDS_SCI_MODE_FAST = 0x03, + /** SCI Low Power mode. */ + BT_HIDS_SCI_MODE_LOW_POWER = 0x04, + /** SCI Full Range mode. */ + BT_HIDS_SCI_MODE_FULL_RANGE = 0x05, }; /** HID Service Protocol Mode events. */ @@ -137,10 +174,18 @@ enum bt_hids_pm_evt { /** HID Service Control Point events. */ enum bt_hids_cp_evt { - /** Suspend command received. */ - BT_HIDS_CP_EVT_HOST_SUSP, - /** Exit suspend command received. */ - BT_HIDS_CP_EVT_HOST_EXIT_SUSP, + /** Suspend command. */ + BT_HIDS_CP_EVT_HOST_SUSP = 0x00, + /** Exit suspend command. */ + BT_HIDS_CP_EVT_HOST_EXIT_SUSP = 0x01, + /** SCI Default mode request. */ + BT_HIDS_CP_EVT_HOST_SCI_DEFAULT_REQ = 0x02, + /** SCI Fast mode request. */ + BT_HIDS_CP_EVT_HOST_SCI_FAST_REQ = 0x03, + /** SCI Low Power mode request. */ + BT_HIDS_CP_EVT_HOST_SCI_LOW_POWER_REQ = 0x04, + /** SCI Full Range mode request. */ + BT_HIDS_CP_EVT_HOST_SCI_FULL_RANGE_REQ = 0x05, }; /** HID notification events. */ @@ -377,12 +422,22 @@ struct bt_hids_pm_data { }; /** @brief HID Control Point event handler. + * + * @deprecated Use @ref bt_hids_conn_cp_evt_handler_t instead * * @param evt Event indicating that the Control Point value has changed. * (see @ref bt_hids_cp_evt). */ typedef void (*bt_hids_cp_evt_handler_t) (enum bt_hids_cp_evt evt); +/** @brief HID Control Point event handler. + * + * @param evt Event indicating that the Control Point value has changed. + * (see @ref bt_hids_cp_evt). + * @param conn Pointer to Connection Object. + */ +typedef void (*bt_hids_conn_cp_evt_handler_t) (enum bt_hids_cp_evt evt, struct bt_conn *conn); + /** @brief Control Point. */ struct bt_hids_cp { @@ -391,7 +446,22 @@ struct bt_hids_cp { /** Callback with new Control Point state.*/ bt_hids_cp_evt_handler_t evt_handler; + + /** Callback with new Control Point state.*/ + bt_hids_conn_cp_evt_handler_t conn_evt_handler; +}; + +#if defined(CONFIG_BT_HIDS_SCI) +/** @brief SCI mode. + */ +struct bt_hids_sci_mode_data { + /** CCC descriptor. */ + struct bt_gatt_ccc_managed_user_data ccc; + + /** Index in the service attribute array. */ + uint8_t att_ind; }; +#endif /* CONFIG_BT_HIDS_SCI */ /** @brief HID initialization. */ @@ -414,9 +484,15 @@ struct bt_hids_init_param { /** Callback for Protocol Mode characteristic. */ bt_hids_pm_evt_handler_t pm_evt_handler; - /** Callback for Control Point characteristic. */ + /** Callback for Control Point event. + * + * @deprecated Use @ref conn_cp_evt_handler instead + */ bt_hids_cp_evt_handler_t cp_evt_handler; + /** Callback for Control Point event. */ + bt_hids_conn_cp_evt_handler_t conn_cp_evt_handler; + /** Callback for Boot Mouse Input Report. */ bt_hids_notify_handler_t boot_mouse_notif_handler; @@ -466,6 +542,10 @@ struct bt_hids { /** Control Point. */ struct bt_hids_cp cp; +#if defined(CONFIG_BT_HIDS_SCI) + /** SCI mode data. */ + struct bt_hids_sci_mode_data sci_mode_data; +#endif /** Buffer with encoded HID Information. */ uint8_t info[BT_HIDS_INFORMATION_LEN]; @@ -502,6 +582,11 @@ struct bt_hids_conn_data { /** Pointer to Feature Reports Context data. */ uint8_t *feat_rep_ctx; + +#if defined(CONFIG_BT_HIDS_SCI) + /** SCI mode value. */ + uint8_t sci_mode; +#endif }; @@ -631,6 +716,55 @@ int bt_hids_boot_kb_inp_rep_send(struct bt_hids *hids_obj, struct bt_conn *conn, uint8_t const *rep, uint16_t len, bt_gatt_complete_func_t cb); +/** @brief Get the current SCI mode. + * + * @param conn Pointer to Connection Object. + * @param mode Output parameter for the SCI mode. + * + * @return 0 If the operation was successful. Otherwise, a (negative) error code is returned. + */ +int bt_hids_sci_mode_get(struct bt_conn *conn, enum bt_hids_sci_mode_value *mode); + +/** @brief Request a new HID SCI mode. + * This function will request connection parameters for the mode. + * To actually change the mode @ref bt_hids_sci_mode_updated needs to be called + * when the connection rate change event is received from the Bluetooth stack + * (conn_rate_changed callback). + * + * @note The function is not thread safe. + * + * @param conn Pointer to Connection Object. + * @param mode New SCI mode. + * + * @return 0 If the operation was successful. + * Otherwise, a (negative) error code is returned. + */ +int bt_hids_sci_mode_change_request(struct bt_conn *conn, + enum bt_hids_sci_mode_value mode); + +/** @brief Validate the new connection parameters against their allowed values + * for the given SCI mode. + * Run this after a connection rate change notification is received + * from the Bluetooth stack. + * + * @param mode SCI mode. + * @param params Connection parameters. + * + * @return True if the connection parameters are valid. Otherwise, false. + */ +bool bt_hids_sci_mode_validate(enum bt_hids_sci_mode_value mode, + const struct bt_conn_le_conn_rate_changed *params); + +/** @brief Update the SCI mode. + * + * @param conn Pointer to Connection Object. + * @param mode SCI mode. + * + * @note The function is not thread safe. + * + * @return 0 If the operation was successful. Otherwise, a (negative) error code is returned. + */ +int bt_hids_sci_mode_updated(struct bt_conn *conn, enum bt_hids_sci_mode_value mode); #ifdef __cplusplus } diff --git a/subsys/bluetooth/services/Kconfig.hids b/subsys/bluetooth/services/Kconfig.hids index ea55e30fccd6..4e2a5fbd1f3a 100644 --- a/subsys/bluetooth/services/Kconfig.hids +++ b/subsys/bluetooth/services/Kconfig.hids @@ -68,6 +68,8 @@ config BT_HIDS_DEFAULT_PERM_RW_AUTHEN endchoice +rsource "Kconfig.hids.sci" + module = BT_HIDS module-str = HIDS source "$(ZEPHYR_BASE)/subsys/logging/Kconfig.template.log_config" diff --git a/subsys/bluetooth/services/Kconfig.hids.sci b/subsys/bluetooth/services/Kconfig.hids.sci new file mode 100644 index 000000000000..3539731cc2b0 --- /dev/null +++ b/subsys/bluetooth/services/Kconfig.hids.sci @@ -0,0 +1,78 @@ +# +# Copyright (c) 2026 Nordic Semiconductor ASA +# +# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause +# + +menuconfig BT_HIDS_SCI + bool "HID Shorter Connection Intervals (SCI) for HIDS service" + depends on BT_SHORTER_CONNECTION_INTERVALS + select EXPERIMENTAL + +if BT_HIDS_SCI + +config BT_HIDS_SCI_LOW_POWER_MODE + bool "HID SCI low power mode" + default y + help + Enable HID Shorter Connection Intervals (SCI) low power mode. + +# The default values below are based on the recommended values from +# the HID over GATT Profile specification (chapter 7.4.1), except +# supervision timeout defaults: smallest HCI-legal value (10 = 100 ms, +# Core Vol 4 Part E) that still satisfies Link Layer §4.5.2 for each +# mode's default interval_max, subrate_max, and max_latency. + +# Default mode +MODE = DEFAULT +MODE_PRETTY = Default +sci_interval_min_default = 60 +sci_interval_max_default = 120 +sci_subrate_min_default = 1 +sci_subrate_max_default = 4 +sci_max_peripheral_latency_default = 0 +sci_continuation_number_default = 0 +sci_supervision_timeout_10ms_default = 13 +rsource "Kconfig.template.hids.sci_mode" + +# Fast mode +MODE = FAST +MODE_PRETTY = Fast +sci_interval_min_default = 10 +sci_interval_max_default = 40 +sci_subrate_min_default = 1 +sci_subrate_max_default = 4 +sci_max_peripheral_latency_default = 0 +sci_continuation_number_default = 3 +sci_supervision_timeout_10ms_default = 10 +rsource "Kconfig.template.hids.sci_mode" + +if BT_HIDS_SCI_LOW_POWER_MODE + +# Low power mode +MODE = LOW_POWER +MODE_PRETTY = Low_Power +sci_interval_min_default = 60 +sci_interval_max_default = 120 +sci_subrate_min_default = 1 +sci_subrate_max_default = 4 +sci_max_peripheral_latency_default = 100 +sci_continuation_number_default = 0 +sci_supervision_timeout_10ms_default = 1213 +rsource "Kconfig.template.hids.sci_mode" + +endif + +# Full range mode +MODE = FULL_RANGE +MODE_PRETTY = Full_Range +sci_interval_min_default = 10 +sci_interval_max_default = 120 +sci_subrate_min_default = 1 +sci_subrate_max_default = 4 +sci_max_peripheral_latency_default = 0 +sci_continuation_number_default = 1 +sci_supervision_timeout_10ms_default = 13 +rsource "Kconfig.template.hids.sci_mode" + +endif diff --git a/subsys/bluetooth/services/Kconfig.template.hids.sci_mode b/subsys/bluetooth/services/Kconfig.template.hids.sci_mode new file mode 100644 index 000000000000..253ab46da2f3 --- /dev/null +++ b/subsys/bluetooth/services/Kconfig.template.hids.sci_mode @@ -0,0 +1,72 @@ +# +# Copyright (c) 2026 Nordic Semiconductor ASA +# +# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause +# +# Kconfig variable template for one HID SCI mode. Set before sourcing: +# MODE Symbol segment, e.g. DEFAULT, FAST, LOW_POWER, FULL_RANGE +# MODE_PRETTY Label for prompts (e.g. Default, Fast, Low_Power, Full_Range) +# sci_interval_min_default +# — min interval (125 us units) default; range low is always 3 +# sci_interval_max_default +# — max interval (125 us units) default +# sci_subrate_min_default, sci_subrate_max_default +# sci_max_peripheral_latency_default +# sci_continuation_number_default +# sci_supervision_timeout_10ms_default +# + +menu "HID SCI: $(MODE_PRETTY) mode" + +config BT_HIDS_SCI_$(MODE)_INTERVAL_MIN_125US + int "Minimum connection interval (125 microsecond units)" + default $(sci_interval_min_default) + range 3 32000 + help + Minimum connection interval in 125 microsecond units (LE connection interval + quantum), matching struct bt_conn_le_conn_rate_param.interval_min_125us. + +config BT_HIDS_SCI_$(MODE)_INTERVAL_MAX_125US + int "Maximum connection interval (125 microsecond units)" + default $(sci_interval_max_default) + range BT_HIDS_SCI_$(MODE)_INTERVAL_MIN_125US 32000 + help + Maximum connection interval in 125 microsecond units (LE connection interval + quantum), matching struct bt_conn_le_conn_rate_param.interval_max_125us. + +config BT_HIDS_SCI_$(MODE)_SUBRATE_MIN + int "Subrate factor minimum" + default $(sci_subrate_min_default) + range 1 500 + help + Minimum subrate factor for SCI $(MODE_PRETTY) mode. + +config BT_HIDS_SCI_$(MODE)_SUBRATE_MAX + int "Subrate factor maximum" + default $(sci_subrate_max_default) + range BT_HIDS_SCI_$(MODE)_SUBRATE_MIN 500 + help + Maximum subrate factor for SCI $(MODE_PRETTY) mode. + +config BT_HIDS_SCI_$(MODE)_MAX_LATENCY + int "Maximum peripheral latency" + default $(sci_max_peripheral_latency_default) + range 0 499 + help + Maximum peripheral latency for SCI $(MODE_PRETTY) mode. + +config BT_HIDS_SCI_$(MODE)_CONTINUATION_NUM + int "Continuation number" + default $(sci_continuation_number_default) + range 0 499 + help + Continuation number for SCI $(MODE_PRETTY) mode. + +config BT_HIDS_SCI_$(MODE)_SUPERVISION_TIMEOUT_10MS + int "Supervision timeout (units of 10 ms)" + default $(sci_supervision_timeout_10ms_default) + range 10 3200 + help + Link supervision timeout for SCI $(MODE_PRETTY) mode. + +endmenu diff --git a/subsys/bluetooth/services/hids.c b/subsys/bluetooth/services/hids.c index af86b0374521..f0dec9b61c10 100644 --- a/subsys/bluetooth/services/hids.c +++ b/subsys/bluetooth/services/hids.c @@ -10,6 +10,7 @@ #include #include #include +#include #include #include @@ -18,6 +19,7 @@ #include #include #include +#include #include @@ -48,6 +50,63 @@ (BT_GATT_PERM_READ | BT_GATT_PERM_WRITE) \ ) +#if defined(CONFIG_BT_HIDS_SCI) + +/** Expands to CONFIG_BT_HIDS_SCI_{mode}{suffix} via token pasting. + * Example: CONFIG_BT_HIDS_SCI_DEFAULT_INTERVAL_MIN_125US. + */ +#define HIDS_SCI_KCONFIG(mode, suffix) CONFIG_BT_HIDS_SCI_##mode##suffix + +/** Expands to a static const struct bt_conn_le_conn_rate_param for the given mode. + * BUILD_ASSERTs mirror Zephyr @c le_conn_rate_common_params_valid() in + * @c conn.c (Core 6.2 Vol 4 Part E §7.8.154) plus Link Layer supervision pacing + * (Vol 6 Part B §§4.5.1–4.5.2). + */ +#define HIDS_SCI_DEFINE_CONN_RATE_PARAM(name, mode) \ + BUILD_ASSERT( \ + HIDS_SCI_KCONFIG(mode, _SUBRATE_MAX) * \ + (1 + HIDS_SCI_KCONFIG(mode, _MAX_LATENCY)) \ + <= 500, \ + "HIDS SCI " #mode ": Core connSubrate*(latency+1) must be <= 500"); \ + BUILD_ASSERT(HIDS_SCI_KCONFIG(mode, _CONTINUATION_NUM) \ + < HIDS_SCI_KCONFIG(mode, _SUBRATE_MAX), \ + "HIDS SCI " #mode ": continuation number must be less than subrate maximum"); \ + BUILD_ASSERT( \ + HIDS_SCI_KCONFIG(mode, _SUPERVISION_TIMEOUT_10MS) * 10000 > \ + (uint64_t)(1 + HIDS_SCI_KCONFIG(mode, _MAX_LATENCY)) * \ + HIDS_SCI_KCONFIG(mode, _SUBRATE_MAX) * \ + HIDS_SCI_KCONFIG(mode, _INTERVAL_MAX_125US) * 250, \ + "HIDS SCI " #mode ": supervision timeout must exceed " \ + "2*(1+latency)*subrate*interval (Vol 6 Part B §4.5.2)"); \ + static const struct bt_conn_le_conn_rate_param (name) = { \ + .interval_min_125us = (uint16_t)HIDS_SCI_KCONFIG(mode, _INTERVAL_MIN_125US), \ + .interval_max_125us = (uint16_t)HIDS_SCI_KCONFIG(mode, _INTERVAL_MAX_125US), \ + .subrate_min = (uint16_t)HIDS_SCI_KCONFIG(mode, _SUBRATE_MIN), \ + .subrate_max = (uint16_t)HIDS_SCI_KCONFIG(mode, _SUBRATE_MAX), \ + .max_latency = (uint16_t)HIDS_SCI_KCONFIG(mode, _MAX_LATENCY), \ + .continuation_number = (uint16_t)HIDS_SCI_KCONFIG( \ + mode, _CONTINUATION_NUM), \ + .supervision_timeout_10ms = (uint16_t)HIDS_SCI_KCONFIG( \ + mode, _SUPERVISION_TIMEOUT_10MS), \ + .min_ce_len_125us = BT_HCI_LE_SCI_CE_LEN_MIN_125US, \ + .max_ce_len_125us = BT_HCI_LE_SCI_CE_LEN_MAX_125US, \ + } + +HIDS_SCI_DEFINE_CONN_RATE_PARAM(hids_sci_conn_rate_default, DEFAULT); +HIDS_SCI_DEFINE_CONN_RATE_PARAM(hids_sci_conn_rate_fast, FAST); +#if defined(CONFIG_BT_HIDS_SCI_LOW_POWER_MODE) +HIDS_SCI_DEFINE_CONN_RATE_PARAM(hids_sci_conn_rate_low_power, LOW_POWER); +#endif +HIDS_SCI_DEFINE_CONN_RATE_PARAM(hids_sci_conn_rate_full_range, FULL_RANGE); + +/* TODO: Currently only a single HID service supporting SCI is supported. + * Fix this in NCSDK-38984 + * + * A pointer to the HID service is stored to be able to notify the service about + * SCI mode changes and make sure that only one SCI-supporting HID service is present. + */ +static struct bt_hids *sci_mode_hids_obj; +#endif /* CONFIG_BT_HIDS_SCI */ LOG_MODULE_REGISTER(bt_hids, CONFIG_BT_HIDS_LOG_LEVEL); @@ -56,6 +115,21 @@ int bt_hids_connected(struct bt_hids *hids_obj, struct bt_conn *conn) __ASSERT_NO_MSG(conn != NULL); __ASSERT_NO_MSG(hids_obj != NULL); +#if defined(CONFIG_BT_HIDS_SCI) + /* TODO: NCSDK-38983: Remove this loop once multiple connections are supported */ + for (size_t i = 0; i < bt_conn_ctx_count(hids_obj->conn_ctx); i++) { + const struct bt_conn_ctx *ctx = + bt_conn_ctx_get_by_id(hids_obj->conn_ctx, i); + + if (ctx) { + LOG_WRN("Currently only one connection " + "per HID service supporting SCI is supported. " + "Using HID SCI modes might produce unexpected results."); + bt_conn_ctx_release(hids_obj->conn_ctx, ctx->data); + } + } +#endif + struct bt_hids_conn_data *conn_data = bt_conn_ctx_alloc(hids_obj->conn_ctx, conn); @@ -92,6 +166,10 @@ int bt_hids_connected(struct bt_hids *hids_obj, struct bt_conn *conn) hids_obj->outp_rep_group.reports[i].size; } +#if defined(CONFIG_BT_HIDS_SCI) + conn_data->sci_mode = BT_HIDS_SCI_MODE_NONE; +#endif + bt_conn_ctx_release(hids_obj->conn_ctx, (void *)conn_data); return 0; @@ -701,6 +779,301 @@ static ssize_t hids_info_read(struct bt_conn *conn, BT_HIDS_INFORMATION_LEN); } +#if defined(CONFIG_BT_HIDS_SCI) +static ssize_t hid_sci_information_load(struct net_buf_simple *sbuf) +{ + int err = 0; + + struct bt_conn_le_min_conn_interval_info sci_info; + + err = bt_conn_le_read_min_conn_interval_groups(&sci_info); + + if (err) { + LOG_ERR("Failed to read connection interval info: %d", err); + switch (err) { + case -ENOMEM: + case -ENOBUFS: + return BT_GATT_ERR(BT_ATT_ERR_INSUFFICIENT_RESOURCES); + default: + return BT_GATT_ERR(BT_ATT_ERR_UNLIKELY); + } + } + + if (sci_info.num_groups > BT_HIDS_SCI_INFORMATION_MAX_GROUPS) { + LOG_WRN("Number of connection interval groups exceeds max allowed group count " + "in SCI Information: %u > %u. Truncating to %u groups.", + sci_info.num_groups, BT_HIDS_SCI_INFORMATION_MAX_GROUPS, + BT_HIDS_SCI_INFORMATION_MAX_GROUPS); + sci_info.num_groups = BT_HIDS_SCI_INFORMATION_MAX_GROUPS; + } + + net_buf_simple_add_u8(sbuf, (uint8_t)(sci_info.min_supported_conn_interval_us + / BT_HCI_LE_SCI_INTERVAL_UNIT_US)); + LOG_DBG("min_supported_conn_interval_us: %u", + sci_info.min_supported_conn_interval_us); + net_buf_simple_add_u8(sbuf, sci_info.num_groups); + LOG_DBG("num_groups: %u", sci_info.num_groups); + + for (size_t i = 0; i < sci_info.num_groups; i++) { + net_buf_simple_add_le16(sbuf, sci_info.groups[i].min_125us); + LOG_DBG("group[%zu] min_125us: %u", + i, + sci_info.groups[i].min_125us); + net_buf_simple_add_le16(sbuf, sci_info.groups[i].max_125us); + LOG_DBG("group[%zu] max_125us: %u", + i, + sci_info.groups[i].max_125us); + net_buf_simple_add_le16(sbuf, sci_info.groups[i].stride_125us); + LOG_DBG("group[%zu] stride_125us: %u", + i, + sci_info.groups[i].stride_125us); + } + + return (ssize_t)sbuf->len; +} + +static ssize_t hids_sci_info_read(struct bt_conn *conn, + struct bt_gatt_attr const *attr, void *buf, + uint16_t len, uint16_t offset) +{ + LOG_DBG("Reading from HID SCI information characteristic."); + + NET_BUF_SIMPLE_DEFINE(sci_sbuf, BT_HIDS_SCI_INFORMATION_MAX_LEN); + ssize_t sci_info_len = 0; + + sci_info_len = hid_sci_information_load(&sci_sbuf); + + if (sci_info_len < 0) { + LOG_ERR("Failed to load SCI information"); + return sci_info_len; + } + + return bt_gatt_attr_read(conn, attr, buf, len, offset, sci_sbuf.data, sci_info_len); +} + +static ssize_t hids_sci_mode_read(struct bt_conn *conn, + struct bt_gatt_attr const *attr, + void *buf, uint16_t len, + uint16_t offset) +{ + LOG_DBG("Reading from SCI Mode characteristic."); + + if (!sci_mode_hids_obj) { + LOG_ERR("No HID service found"); + return BT_GATT_ERR(BT_ATT_ERR_INSUFFICIENT_RESOURCES); + } + + ssize_t ret_len; + + struct bt_hids_conn_data *conn_data = + bt_conn_ctx_get(sci_mode_hids_obj->conn_ctx, conn); + + if (!conn_data) { + LOG_ERR("The context was not found"); + return BT_GATT_ERR(BT_ATT_ERR_INSUFFICIENT_RESOURCES); + } + + ret_len = bt_gatt_attr_read(conn, attr, buf, len, offset, &conn_data->sci_mode, + sizeof(uint8_t)); + + bt_conn_ctx_release(sci_mode_hids_obj->conn_ctx, (void *)conn_data); + + return ret_len; + +} + +static void hids_sci_mode_ccc_changed(struct bt_gatt_attr const *attr, uint16_t value) +{ + LOG_DBG("SCI Mode CCCD has changed."); + + if (value == BT_GATT_CCC_NOTIFY) { + LOG_DBG("Notification for SCI Mode has been turned on"); + } else { + LOG_DBG("Notification for SCI Mode has been turned off"); + } +} + +static const struct bt_conn_le_conn_rate_param *get_sci_conn_rate_param_for_mode( + enum bt_hids_sci_mode_value mode) +{ + switch (mode) { + case BT_HIDS_SCI_MODE_DEFAULT: + return &hids_sci_conn_rate_default; + case BT_HIDS_SCI_MODE_FAST: + return &hids_sci_conn_rate_fast; +#if defined(CONFIG_BT_HIDS_SCI_LOW_POWER_MODE) + case BT_HIDS_SCI_MODE_LOW_POWER: + return &hids_sci_conn_rate_low_power; +#endif + case BT_HIDS_SCI_MODE_FULL_RANGE: + return &hids_sci_conn_rate_full_range; + default: + LOG_ERR("Invalid SCI mode: %d", mode); + return NULL; + } +} + +int bt_hids_sci_mode_get(struct bt_conn *conn, enum bt_hids_sci_mode_value *mode) +{ + if (conn == NULL || mode == NULL) { + return -EINVAL; + } + + if (sci_mode_hids_obj == NULL) { + LOG_ERR("No HID service found"); + return -ENOENT; + } + + struct bt_hids_conn_data *conn_data = bt_conn_ctx_get(sci_mode_hids_obj->conn_ctx, conn); + + if (!conn_data) { + LOG_WRN("The context was not found"); + return -ENOENT; + } + + *mode = conn_data->sci_mode; + + bt_conn_ctx_release(sci_mode_hids_obj->conn_ctx, (void *)conn_data); + + return 0; +} + +int bt_hids_sci_mode_change_request(struct bt_conn *conn, + enum bt_hids_sci_mode_value mode) +{ + struct bt_conn_le_conn_rate_param const *params = NULL; + int err = 0; + + if (conn == NULL) { + return -EINVAL; + } + + if (sci_mode_hids_obj == NULL) { + LOG_ERR("No HID service found"); + return -ENOENT; + } + + struct bt_hids_conn_data *conn_data = bt_conn_ctx_get(sci_mode_hids_obj->conn_ctx, conn); + + if (!conn_data) { + LOG_WRN("The context was not found"); + return -ENOENT; + } + + params = get_sci_conn_rate_param_for_mode(mode); + if (params == NULL) { + bt_conn_ctx_release(sci_mode_hids_obj->conn_ctx, (void *)conn_data); + return -EINVAL; + } + + err = bt_conn_le_conn_rate_request(conn, params); + + if (err) { + LOG_ERR("SCI conn rate request failed (%d)", err); + } + + bt_conn_ctx_release(sci_mode_hids_obj->conn_ctx, (void *)conn_data); + + return err; +} + +bool bt_hids_sci_mode_validate(enum bt_hids_sci_mode_value mode, + const struct bt_conn_le_conn_rate_changed *params) +{ + const struct bt_conn_le_conn_rate_param *mode_params = + get_sci_conn_rate_param_for_mode(mode); + + if (params == NULL || mode_params == NULL) { + return false; + } + + const uint64_t interval_min_us = + (uint64_t)mode_params->interval_min_125us * 125; + const uint64_t interval_max_us = + (uint64_t)mode_params->interval_max_125us * 125; + + if (params->interval_us < interval_min_us || params->interval_us > interval_max_us) { + LOG_WRN("Interval: %u us is outside allowed range %llu-%llu us for mode %d", + params->interval_us, (unsigned long long)interval_min_us, + (unsigned long long)interval_max_us, mode); + return false; + } + + if (params->subrate_factor < mode_params->subrate_min || + params->subrate_factor > mode_params->subrate_max) { + LOG_WRN("Subrate factor: %u is outside allowed range %u-%u for mode %d", + params->subrate_factor, mode_params->subrate_min, + mode_params->subrate_max, mode); + return false; + } + + if (params->peripheral_latency > mode_params->max_latency) { + LOG_WRN("Peripheral latency: %u is outside allowed range 0-%u for mode %d", + params->peripheral_latency, mode_params->max_latency, mode); + return false; + } + + return true; +} + +static void sci_mode_update_notify(struct bt_hids *hids_obj, struct bt_conn *conn, + uint8_t mode) +{ + int err = 0; + struct bt_gatt_attr *sci_mode_attr = + &hids_obj->gp.svc.attrs[hids_obj->sci_mode_data.att_ind]; + + if (bt_gatt_is_subscribed(conn, sci_mode_attr, BT_GATT_CCC_NOTIFY)) { + err = bt_gatt_notify(conn, sci_mode_attr, &mode, sizeof(mode)); + if (err) { + LOG_ERR("Failed to notify SCI mode update: %d", err); + } + } +} + +int bt_hids_sci_mode_updated(struct bt_conn *conn, enum bt_hids_sci_mode_value mode) +{ + int err = 0; + + if (!sci_mode_hids_obj) { + LOG_WRN("SCI mode updated, but no HID service found"); + return -ENOENT; + } + if (conn == NULL) { + return -EINVAL; + } + + if (mode != BT_HIDS_SCI_MODE_NONE + && mode != BT_HIDS_SCI_MODE_DEFAULT + && mode != BT_HIDS_SCI_MODE_FAST +#if defined(CONFIG_BT_HIDS_SCI_LOW_POWER_MODE) + && mode != BT_HIDS_SCI_MODE_LOW_POWER +#endif + && mode != BT_HIDS_SCI_MODE_FULL_RANGE) { + LOG_ERR("Invalid SCI mode: %d", mode); + return -EINVAL; + } + + struct bt_hids_conn_data *conn_data = + bt_conn_ctx_get(sci_mode_hids_obj->conn_ctx, conn); + if (!conn_data) { + LOG_ERR("The context was not found"); + return -ENOENT; + } + + if (conn_data->sci_mode != mode) { + conn_data->sci_mode = mode; + LOG_DBG("SCI mode updated to: %d", conn_data->sci_mode); + + sci_mode_update_notify(sci_mode_hids_obj, conn, (uint8_t) conn_data->sci_mode); + } + + bt_conn_ctx_release(sci_mode_hids_obj->conn_ctx, (void *)conn_data); + + return err; +} +#endif + static ssize_t hids_ctrl_point_write(struct bt_conn *conn, struct bt_gatt_attr const *attr, void const *buf, uint16_t len, @@ -709,6 +1082,7 @@ static ssize_t hids_ctrl_point_write(struct bt_conn *conn, LOG_DBG("Writing to Control Point characteristic."); struct bt_hids_cp *cp = (struct bt_hids_cp *)attr->user_data; + ssize_t ret = 0; uint8_t *cur_cp = &cp->value; uint8_t const *new_cp = (uint8_t const *)buf; @@ -722,35 +1096,55 @@ static ssize_t hids_ctrl_point_write(struct bt_conn *conn, } switch (*new_cp) { - case BT_HIDS_CONTROL_POINT_SUSPEND: - if (cp->evt_handler) { - cp->evt_handler(BT_HIDS_CP_EVT_HOST_SUSP); + case BT_HIDS_CP_EVT_HOST_SUSP: + case BT_HIDS_CP_EVT_HOST_EXIT_SUSP: + if (cp->conn_evt_handler) { + cp->conn_evt_handler(*new_cp, conn); + } else if (cp->evt_handler) { + cp->evt_handler(*new_cp); } break; - case BT_HIDS_CONTROL_POINT_EXIT_SUSPEND: - if (cp->evt_handler) { - cp->evt_handler(BT_HIDS_CP_EVT_HOST_EXIT_SUSP); +#if defined(CONFIG_BT_HIDS_SCI) + case BT_HIDS_CP_EVT_HOST_SCI_DEFAULT_REQ: + case BT_HIDS_CP_EVT_HOST_SCI_FAST_REQ: +#if defined(CONFIG_BT_HIDS_SCI_LOW_POWER_MODE) + case BT_HIDS_CP_EVT_HOST_SCI_LOW_POWER_REQ: +#endif + case BT_HIDS_CP_EVT_HOST_SCI_FULL_RANGE_REQ: + if (cp->conn_evt_handler) { + cp->conn_evt_handler(*new_cp, conn); } - break; +#endif + default: return BT_GATT_ERR(BT_ATT_ERR_NOT_SUPPORTED); } - *cur_cp = *new_cp; + if (ret == BT_GATT_ERR(BT_ATT_ERR_SUCCESS)) { + *cur_cp = *new_cp; + ret = len; + } - return len; + return ret; } static uint8_t hid_information_encode(uint8_t *buffer, struct bt_hids_info const *hid_info) { uint8_t len = 0; + uint8_t flags_extra = 0; +#if defined(CONFIG_BT_HIDS_SCI) + flags_extra |= BT_HIDS_SCI_SUPPORTED; +#endif +#if defined(CONFIG_BT_HIDS_SCI_LOW_POWER_MODE) + flags_extra |= BT_HIDS_SCI_LOW_POWER_MODE_SUPPORTED; +#endif sys_put_le16(hid_info->bcd_hid, buffer); len += sizeof(uint16_t); buffer[len++] = hid_info->b_country_code; - buffer[len++] = hid_info->flags; + buffer[len++] = hid_info->flags | flags_extra; __ASSERT(len == BT_HIDS_INFORMATION_LEN, "HIDS Information encoding failed"); @@ -900,13 +1294,30 @@ int bt_hids_init(struct bt_hids *hids_obj, { LOG_DBG("Initializing HIDS."); + int err = 0; + +#if defined(CONFIG_BT_HIDS_SCI) + if (sci_mode_hids_obj) { + /* TODO: NCSDK-38984: This should be fixed, + * more services should be allowed + */ + LOG_ERR("Currently only one HID service supporting SCI is supported"); + bt_gatt_pool_free(&hids_obj->gp); + return -EALREADY; + } +#endif + if (init_param->rep_map.size > BT_ATT_MAX_ATTRIBUTE_LEN) { LOG_WRN("Report map size exceeds max ATT attribute length"); return -EMSGSIZE; } hids_obj->pm.evt_handler = init_param->pm_evt_handler; - hids_obj->cp.evt_handler = init_param->cp_evt_handler; + if (init_param->cp_evt_handler) { + LOG_WRN("cp_evt_handler is deprecated, use conn_cp_evt_handler instead"); + hids_obj->cp.evt_handler = init_param->cp_evt_handler; + } + hids_obj->cp.conn_evt_handler = init_param->conn_cp_evt_handler; /* Register primary service. */ BT_GATT_POOL_SVC(&hids_obj->gp, BT_UUID_HIDS); @@ -1017,8 +1428,47 @@ int bt_hids_init(struct bt_hids *hids_obj, HIDS_GATT_PERM_DEFAULT & GATT_PERM_WRITE_MASK, NULL, hids_ctrl_point_write, &hids_obj->cp); +#if defined(CONFIG_BT_HIDS_SCI) + /* Register HID SCI Information characteristic and its descriptor. + * Note this characteristic does not contain valid data for now, + * as this function is called before bt_enable() + * Thus, there is no way to acquire the supported connection intervals. + * The value of the SCI Information will be updated on the first attempt + * to read from the characteristic. + */ + BT_GATT_POOL_CHRC(&hids_obj->gp, + BT_UUID_HIDS_SCI_INFO, + BT_GATT_CHRC_READ, + HIDS_GATT_PERM_DEFAULT & GATT_PERM_READ_MASK, + hids_sci_info_read, NULL, NULL); + + /* Register HID SCI Mode Characteristic, its descriptor and CCC. */ + BT_GATT_POOL_CHRC(&hids_obj->gp, + BT_UUID_HIDS_SCI_MODE, + BT_GATT_CHRC_READ | BT_GATT_CHRC_NOTIFY, + HIDS_GATT_PERM_DEFAULT & GATT_PERM_READ_MASK, + hids_sci_mode_read, NULL, NULL); + + hids_obj->sci_mode_data.att_ind = hids_obj->gp.svc.attr_count - 1; + BT_GATT_POOL_CCC(&hids_obj->gp, + hids_obj->sci_mode_data.ccc, + hids_sci_mode_ccc_changed, + HIDS_GATT_PERM_DEFAULT); + + sci_mode_hids_obj = hids_obj; +#endif + /* Register HIDS attributes in GATT database. */ - return bt_gatt_service_register(&hids_obj->gp.svc); + err = bt_gatt_service_register(&hids_obj->gp.svc); + if (err) { +#if defined(CONFIG_BT_HIDS_SCI) + sci_mode_hids_obj = NULL; +#endif + bt_gatt_pool_free(&hids_obj->gp); + return err; + } + + return err; } int bt_hids_uninit(struct bt_hids *hids_obj) @@ -1045,6 +1495,12 @@ int bt_hids_uninit(struct bt_hids *hids_obj) hids_obj->gp.svc.attrs = attr_start; hids_obj->conn_ctx = conn_ctx; +#if defined(CONFIG_BT_HIDS_SCI) + if (sci_mode_hids_obj == hids_obj) { + sci_mode_hids_obj = NULL; + } +#endif + return 0; } From 49f57a1986faba667d115e580e62ef855fa9d601 Mon Sep 17 00:00:00 2001 From: Artur Hadasz Date: Fri, 8 May 2026 10:24:22 +0200 Subject: [PATCH 36/37] bluetooth: hogp: Add support for HID SCI Add support for HID Shorter Connection Intervals on the HID host side. Signed-off-by: Artur Hadasz --- doc/nrf/links.txt | 2 +- .../releases/release-notes-changelog.rst | 1 + include/bluetooth/services/hogp.h | 151 +++++ subsys/bluetooth/services/Kconfig.hogp | 5 + subsys/bluetooth/services/hogp.c | 536 +++++++++++++++++- 5 files changed, 692 insertions(+), 3 deletions(-) diff --git a/doc/nrf/links.txt b/doc/nrf/links.txt index 8bc725edaf4c..050d04ec7252 100644 --- a/doc/nrf/links.txt +++ b/doc/nrf/links.txt @@ -1293,7 +1293,7 @@ .. _`Current Time Service Specification`: https://www.bluetooth.org/docman/handlers/downloaddoc.ashx?doc_id=292957 .. _`Running Speed and Cadence Service Specification`: https://www.bluetooth.com/specifications/specs/running-speed-and-cadence-service-1-0/ .. _`Continuous Glucose Monitoring Service Specification`: https://www.bluetooth.org/DocMan/handlers/DownloadDoc.ashx?doc_id=531249 -.. _`HID Over GATT Profile Specification`: https://www.bluetooth.com/specifications/specs/hid-over-gatt-profile/ +.. _`HID Over GATT Profile Specification`: https://www.bluetooth.com/specifications/specs/hid-over-gatt-profile-hogp/ .. _`Ranging Profile Specification`: https://files.bluetooth.com/download/rap_v1-0/ .. _`Ranging Service Specification`: https://files.bluetooth.com/download/ras_v1-0/ 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 e0413355f576..e893a0dd48dc 100644 --- a/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst +++ b/doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst @@ -598,6 +598,7 @@ Bluetooth libraries and services * :ref:`hogp_readme` library: * Fixed an issue where the :c:func:`bt_hogp_rep_unsubscribe` function did not clear the notification callback, which prevented the :c:func:`bt_hogp_rep_subscribe` function from succeeding after unsubscribing. + * Added support for Bluetooth HID Shorter Connection Intervals (SCI) on the HID device and HID host sides (:kconfig:option:`CONFIG_BT_HIDS_SCI`, :kconfig:option:`CONFIG_BT_HOGP_SCI`). Common Application Framework ---------------------------- diff --git a/include/bluetooth/services/hogp.h b/include/bluetooth/services/hogp.h index e2a577493c39..fb25540e5f64 100644 --- a/include/bluetooth/services/hogp.h +++ b/include/bluetooth/services/hogp.h @@ -143,6 +143,54 @@ struct bt_hogp_init_params { */ struct bt_hogp_rep_info; +/** @brief Callback function that is called when the HID SCI mode changed GATT + * notification is received. + * + * @param conn Connection object. + * @param mode New SCI mode value. + */ +typedef void (*bt_hogp_sci_mode_changed_cb)(struct bt_conn *conn, + enum bt_hids_sci_mode_value mode); + +/** + * @brief Callback function that is called when a HID SCI mode read is completed. + * + * @param hogp HOGP object. + * @param err ATT error code. + * @param mode SCI mode value. + */ +typedef void (*bt_hogp_sci_mode_read_cb)(struct bt_hogp *hogp, int err, + enum bt_hids_sci_mode_value mode); + +/** @brief SCI mode data. + * + * This structure is defined here as it is needed in the bt_hogp structure definition. + * Do not use any of the fields here directly. + */ +struct bt_hogp_sci_mode_data { + /** Function to call when the SCI mode is changed (@ref bt_hogp_sci_mode_subscribe). */ + bt_hogp_sci_mode_changed_cb notify_cb; + + /** Notify params. */ + struct bt_gatt_subscribe_params notify_params; + + /** One-shot read callback for @ref bt_hogp_sci_mode_read. */ + bt_hogp_sci_mode_read_cb read_cb; +}; + +/** @brief SCI Information. + */ +struct bt_hogp_sci_info { + /** Minimum supported connection interval in units of 125us. */ + uint8_t min_supported_conn_interval_125us; + + /** Number of connection interval groups. */ + uint8_t num_groups; + + /** Connection interval groups. */ + struct bt_conn_le_min_conn_interval_group groups[BT_CONN_LE_MAX_CONN_INTERVAL_GROUPS]; +}; + /** * @brief HOGP object. * @@ -157,6 +205,15 @@ struct bt_hogp { struct bt_conn *conn; /** HIDS client information. */ struct bt_hids_info info_val; + +#if defined(CONFIG_BT_HOGP_SCI) + /** HID SCI Mode data. */ + struct bt_hogp_sci_mode_data sci_mode_data; + + /** Cached HID SCI Information. */ + struct bt_hogp_sci_info sci_info; +#endif + /** Handlers for descriptors */ struct bt_hogp_handlers { /** Protocol Mode Characteristic value handle. */ @@ -167,6 +224,14 @@ struct bt_hogp { uint16_t info; /** HID Control Point Characteristic handle. */ uint16_t cp; +#if defined(CONFIG_BT_HOGP_SCI) + /** HID SCI Information Characteristic handle. */ + uint16_t sci_info; + /** HID SCI Mode Characteristic handle. */ + uint16_t sci_mode; + /** HID SCI Mode CCC handle. */ + uint16_t sci_mode_ccc; +#endif } handlers; /** * @brief Callback for HIDS client ready @@ -193,6 +258,7 @@ struct bt_hogp { * @sa bt_hogp::read_params_sem */ struct bt_gatt_read_params read_params; + /** * @brief The semaphore for common read parameters protection. * @@ -530,6 +596,91 @@ int bt_hogp_suspend(struct bt_hogp *hogp); */ int bt_hogp_exit_suspend(struct bt_hogp *hogp); +/** + * @brief Check if the HID device supports SCI. + * + * @note This function will return false both if the HID information does + * not contain the SCI supported flag as well as if an error occurred + * during the HID SCI initialization. + * + * @param hogp HOGP object. + * + * @return true if the HID device supports SCI, false otherwise. + */ +bool bt_hogp_sci_supported(const struct bt_hogp *hogp); + +/** + * @brief Check if the HID device supports SCI Low Power mode. + * + * @param hogp HOGP object. + * + * @return true if the HID device supports SCI Low Power mode, false otherwise. + */ +bool bt_hogp_sci_low_power_mode_supported(const struct bt_hogp *hogp); + +/** + * @brief Read the current HID SCI mode from the HID device. + * @param hogp HOGP object. + * @param func Callback invoked when read completes. + * + * @retval 0 If the operation was successful. + * Otherwise, a (negative) error code is returned. + */ +int bt_hogp_sci_mode_read(struct bt_hogp *hogp, bt_hogp_sci_mode_read_cb func); + +/** + * @brief Request HID SCI mode activation. + * + * This function is used to request that the HID device enters a specific + * HID SCI mode. + * + * @param hogp HOGP object. + * @param mode HID SCI mode to enable + * + * @retval 0 If the operation was successful. + * Otherwise, a (negative) error code is returned. + */ +int bt_hogp_sci_mode_req(struct bt_hogp *hogp, enum bt_hids_sci_mode_value mode); + +/** + * @brief Subscribe to HID SCI mode changed notifications. + * + * @param hogp HOGP object. + * @param func Function to call when the SCI mode changes. + * + * @retval 0 If the operation was successful. + * Otherwise, a (negative) error code is returned. + */ +int bt_hogp_sci_mode_subscribe(struct bt_hogp *hogp, bt_hogp_sci_mode_changed_cb func); + +/** + * @brief Unsubscribe from SCI mode changed notifications. + * + * @param hogp HOGP object. + * + * @retval 0 If the operation was successful. + * Otherwise, a (negative) error code is returned. + */ +int bt_hogp_sci_mode_unsubscribe(struct bt_hogp *hogp); + +/** + * @brief Get the cached HID SCI Information. + * + * This function fills the SCI Information structure with the cached SCI Information. + * It does not generate any traffic on the radio. + * The SCI Information is read once after connection to the HID device and cached + * in the HOGP object. + * + * @param hogp HOGP object. + * @param sci_info Pointer to the SCI Information structure to fill. + * + * @retval 0 If the operation was successful. + * @retval -ENOTSUP The HID SCI Device does not support mandatory connection intervals. + * The sci_info will be filled with values and usable. + * It is up to the upper layer what to do with this information. + * @retval -EINVAL The passed parameters are invalid. + */ +int bt_hogp_sci_info_get(struct bt_hogp *hogp, struct bt_hogp_sci_info *sci_info); /** * @brief Get the connection object from the HIDS client. diff --git a/subsys/bluetooth/services/Kconfig.hogp b/subsys/bluetooth/services/Kconfig.hogp index 999fec31554c..057d446fdc20 100644 --- a/subsys/bluetooth/services/Kconfig.hogp +++ b/subsys/bluetooth/services/Kconfig.hogp @@ -12,6 +12,11 @@ menuconfig BT_HOGP if BT_HOGP +config BT_HOGP_SCI + bool "HID Shorter Connection Intervals (SCI) support in HOGP" + depends on BT_SHORTER_CONNECTION_INTERVALS + select EXPERIMENTAL + module = BT_HOGP module-str = HIDS Client source "$(ZEPHYR_BASE)/subsys/logging/Kconfig.template.log_config" diff --git a/subsys/bluetooth/services/hogp.c b/subsys/bluetooth/services/hogp.c index e18bc738a056..17924fa9a77a 100644 --- a/subsys/bluetooth/services/hogp.c +++ b/subsys/bluetooth/services/hogp.c @@ -273,6 +273,185 @@ static void hids_prep_error(struct bt_hogp *hogp, int err) } } +#if defined(CONFIG_BT_HOGP_SCI) +static void invalidate_sci_handles(struct bt_hogp *hogp) +{ + hogp->handlers.sci_info = 0; + hogp->handlers.sci_mode = 0; + hogp->handlers.sci_mode_ccc = 0; +} + +/** + * @brief HIDS SCI information read + * + * HIDS SCI information read is automatically started after connection to HID server. + * + * @param conn Connection handler. + * @param err Read ATT error code. + * @param params Notification parameters structure - the pointer + * to the structure provided to read function. + * @param data Pointer to the data buffer. + * @param length The size of the received data. + * + * @retval BT_GATT_ITER_STOP Stop notification + * @retval BT_GATT_ITER_CONTINUE Continue notification + */ +static uint8_t hid_sci_info_read_process(struct bt_conn *conn, uint8_t err, + struct bt_gatt_read_params *params, + const void *data, uint16_t length); + +static int hid_sci_info_read_start(struct bt_hogp *hogp) +{ + int err = 0; + struct bt_gatt_read_params *params; + + __ASSERT_NO_MSG(hogp); + /* This function is only called from pm_read_process, the check was already done there */ + __ASSERT_NO_MSG(hogp->handlers.sci_info != 0); + + LOG_DBG("HID SCI information read start"); + params = &hogp->read_params; + params->func = hid_sci_info_read_process; + params->handle_count = 1; + params->single.handle = hogp->handlers.sci_info; + params->single.offset = 0; + err = bt_gatt_read(hogp->conn, params); + if (err) { + LOG_ERR("HID SCI information read error (err: %d)", err); + } + return err; +} + +static bool interval_in_conn_group(uint32_t interval_us, + const struct bt_conn_le_min_conn_interval_group *group) +{ + uint32_t interval_125us = interval_us / 125; + + return interval_125us >= group->min_125us && interval_125us <= group->max_125us && + (interval_125us - group->min_125us) % group->stride_125us == 0; +} + +static bool hid_sci_info_supported_intervals_present(const struct bt_hogp_sci_info *sci_info) +{ + /** According to HID over GATT Profile specification Table 7.2 the + * support of 1.25ms, 2.5 ms and 5ms is mandatory for a HID device + * supporting HID SCI. + */ + bool interval_1_25ms_present = false; + bool interval_2_5ms_present = false; + bool interval_5ms_present = false; + + for (size_t i = 0; i < sci_info->num_groups; i++) { + if (sci_info->groups[i].stride_125us == 0) { + LOG_ERR("SCI Information group %d has a stride of 0", i); + continue; + } + + if (interval_in_conn_group(1250, + &sci_info->groups[i])) { + interval_1_25ms_present = true; + } + if (interval_in_conn_group(2500, + &sci_info->groups[i])) { + interval_2_5ms_present = true; + } + if (interval_in_conn_group(5000, + &sci_info->groups[i])) { + interval_5ms_present = true; + } + } + + if (!interval_1_25ms_present) { + LOG_ERR("HID SCI Device does not support mandatory 1.25ms connection interval"); + } + + if (!interval_2_5ms_present) { + LOG_ERR("HID SCI Device does not support mandatory 2.5ms connection interval"); + } + + if (!interval_5ms_present) { + LOG_ERR("HID SCI Device does not support mandatory 5ms connection interval"); + } + + return interval_1_25ms_present && interval_2_5ms_present && interval_5ms_present; +} + +static uint8_t hid_sci_info_read_process(struct bt_conn *conn, uint8_t err, + struct bt_gatt_read_params *params, + const void *data, uint16_t length) +{ + struct bt_hogp *hogp; + const uint8_t *bdata = data; + + hogp = CONTAINER_OF(params, struct bt_hogp, read_params); + + if (err) { + LOG_ERR("HID SCI information read error"); + hids_prep_error(hogp, err); + invalidate_sci_handles(hogp); + return BT_GATT_ITER_STOP; + } + if ((length < BT_HIDS_SCI_INFORMATION_MIN_LEN || length > BT_HIDS_SCI_INFORMATION_MAX_LEN) + || !data) { + LOG_ERR("Unexpected HID SCI information size: %u", length); + hids_prep_error(hogp, -ENOTSUP); + invalidate_sci_handles(hogp); + return BT_GATT_ITER_STOP; + } + + hogp->sci_info.min_supported_conn_interval_125us = bdata[0]; + hogp->sci_info.num_groups = bdata[1]; + LOG_DBG("HID SCI information: min_supported_conn_interval_125us: %u, num_groups: %u", + hogp->sci_info.min_supported_conn_interval_125us, hogp->sci_info.num_groups); + + if (hogp->sci_info.num_groups > BT_HIDS_SCI_INFORMATION_MAX_GROUPS) { + LOG_ERR("Number of connection interval groups exceeds max allowed group count " + "in SCI Information: %u > %u", + hogp->sci_info.num_groups, BT_HIDS_SCI_INFORMATION_MAX_GROUPS); + hids_prep_error(hogp, -EMSGSIZE); + invalidate_sci_handles(hogp); + return BT_GATT_ITER_STOP; + } + + + size_t offset = sizeof(hogp->sci_info.min_supported_conn_interval_125us) + + sizeof(hogp->sci_info.num_groups); + size_t group_size = sizeof(uint16_t) * 3; + size_t expected_length = offset + hogp->sci_info.num_groups * group_size; + + if (length < expected_length) { + LOG_ERR("Data is too short to contain all the SCI information"); + hids_prep_error(hogp, -EMSGSIZE); + return BT_GATT_ITER_STOP; + } + + for (size_t i = 0; i < hogp->sci_info.num_groups; i++) { + hogp->sci_info.groups[i].min_125us = sys_get_le16(&bdata[offset]); + offset += sizeof(uint16_t); + hogp->sci_info.groups[i].max_125us = sys_get_le16(&bdata[offset]); + offset += sizeof(uint16_t); + hogp->sci_info.groups[i].stride_125us = sys_get_le16(&bdata[offset]); + offset += sizeof(uint16_t); + LOG_DBG(" HID SCI information: group[%zu]: min_125us: %u, max_125us: %u, " + "stride_125us: %u", i, hogp->sci_info.groups[i].min_125us, + hogp->sci_info.groups[i].max_125us, hogp->sci_info.groups[i].stride_125us); + } + + LOG_DBG("Read SCI Information success"); + + /* Do not break the flow if the supported intervals are not present. + * Let the application decide what to do with this information. + * This code is here only for logging purposes. + */ + (void) hid_sci_info_supported_intervals_present(&hogp->sci_info); + + hids_mark_ready(hogp); + + return BT_GATT_ITER_STOP; +} + +#endif + /** * @brief Process protocol mode read * @@ -348,6 +527,22 @@ static uint8_t pm_read_process(struct bt_conn *conn, uint8_t err, hogp->pm = (enum bt_hids_pm)((uint8_t *)data)[0]; LOG_DBG("Read PM success: %d", (int)hogp->pm); + +#if defined(CONFIG_BT_HOGP_SCI) + if (hogp->handlers.sci_info != 0) { + int err; + + err = hid_sci_info_read_start(hogp); + if (err) { + hids_prep_error(hogp, err); + } + + return BT_GATT_ITER_STOP; + } + + LOG_DBG("Device ready without SCI information characteristic"); +#endif + hids_mark_ready(hogp); return BT_GATT_ITER_STOP; } @@ -530,6 +725,13 @@ static uint8_t hid_info_read_process(struct bt_conn *conn, uint8_t err, LOG_DBG(" bCountryCode: 0x%x", hogp->info_val.b_country_code); LOG_DBG(" Flags: 0x%x", hogp->info_val.flags); +#if defined(CONFIG_BT_HOGP_SCI) + if (!(hogp->info_val.flags & BT_HIDS_SCI_SUPPORTED)) { + LOG_DBG("HID device does not support SCI"); + invalidate_sci_handles(hogp); + } +#endif /* CONFIG_BT_HOGP_SCI */ + err = repref_read_start(hogp, 0); if (err) { hids_prep_error(hogp, err); @@ -568,6 +770,72 @@ static int post_discovery_start(struct bt_hogp *hogp) return 0; } +#if defined(CONFIG_BT_HOGP_SCI) +static int hid_sci_handles_assign(struct bt_gatt_dm *dm, struct bt_hogp *hogp) +{ + uint16_t handle; + const struct bt_gatt_dm_attr *gatt_chrc; + const struct bt_gatt_dm_attr *gatt_desc; + const struct bt_gatt_chrc *chrc_val; + + __ASSERT_NO_MSG(hogp); + + handle = chrc_value_handle_by_uuid(dm, hogp, + BT_UUID_HIDS_SCI_INFO); + if (handle != 0) { + LOG_DBG("Found handle for SCI Info characteristic: 0x%x.", handle); + } + + hogp->handlers.sci_info = handle; + + gatt_chrc = bt_gatt_dm_char_by_uuid(dm, BT_UUID_HIDS_SCI_MODE); + + /* Valid case - HID service simply does not support SCI. */ + if (!gatt_chrc && hogp->handlers.sci_info == 0) { + LOG_INF("SCI characteristics not found on HID service. " + "SCI will not be supported."); + return 0; + } + + if (!gatt_chrc || hogp->handlers.sci_info == 0) { + LOG_ERR("Invalid SCI configuration on HID service." + "Characteristics partially missing."); + return -EINVAL; + } + + chrc_val = bt_gatt_dm_attr_chrc_val(gatt_chrc); + __ASSERT_NO_MSG(chrc_val); + if ((chrc_val->properties & BT_GATT_CHRC_READ) == 0U) { + LOG_ERR("SCI Mode characteristic missing read property."); + return -EINVAL; + } + if ((chrc_val->properties & BT_GATT_CHRC_NOTIFY) == 0U) { + LOG_ERR("SCI Mode characteristic missing notify property."); + return -EINVAL; + } + + LOG_DBG("SCI Mode characteristic found."); + gatt_desc = bt_gatt_dm_desc_by_uuid(dm, gatt_chrc, BT_UUID_HIDS_SCI_MODE); + if (!gatt_desc) { + LOG_ERR("SCI Mode characteristic value not found."); + return -EINVAL; + } + + LOG_DBG("SCI Mode characteristic desc found."); + hogp->handlers.sci_mode = gatt_desc->handle; + gatt_desc = bt_gatt_dm_desc_by_uuid(dm, gatt_chrc, BT_UUID_GATT_CCC); + if (!gatt_desc) { + LOG_ERR("SCI Mode CCC descriptor not found."); + return -EINVAL; + } + + LOG_DBG("SCI Mode CCC descriptor found."); + hogp->handlers.sci_mode_ccc = gatt_desc->handle; + + return 0; +} +#endif + /** * @brief Auxiliary internal function for handles assign * @@ -632,6 +900,16 @@ static int handles_assign_internal(struct bt_gatt_dm *dm, LOG_DBG("Found handle for Report Map characteristic: 0x%x.", handle); hogp->handlers.rep_map = handle; +#if defined(CONFIG_BT_HOGP_SCI) + /* HID SCI Info Characteristic */ + ret = hid_sci_handles_assign(dm, hogp); + if (ret) { + LOG_ERR("Failed to assign SCI handles: %d", ret); + LOG_WRN("HID SCI will not be supported."); + invalidate_sci_handles(hogp); + } +#endif + /* If we have any of the boot report - protocol mode is mandatory, * otherwise optional, but it does not make any sense to keep it */ @@ -800,6 +1078,11 @@ void bt_hogp_release(struct bt_hogp *hogp) LOG_DBG("Report memory released, entities used: %u", k_mem_slab_num_used_get(&bt_hogp_reports_mem)); +#if defined(CONFIG_BT_HOGP_SCI) + memset(&hogp->sci_info, 0, sizeof(hogp->sci_info)); + hogp->sci_mode_data.read_cb = NULL; +#endif + memset(&hogp->info_val, 0, sizeof(hogp->info_val)); memset(&hogp->handlers, 0, sizeof(hogp->handlers)); hogp->map_cb = NULL; @@ -1049,6 +1332,40 @@ static uint8_t rep_notify_process(struct bt_conn *conn, return err; } +#if defined(CONFIG_BT_HOGP_SCI) +static uint8_t sci_mode_notify_process(struct bt_conn *conn, + struct bt_gatt_subscribe_params *params, + const void *data, uint16_t length) +{ + const uint8_t *bdata = data; + struct bt_hogp_sci_mode_data *sci_mode_data; + + sci_mode_data = CONTAINER_OF(params, + struct bt_hogp_sci_mode_data, + notify_params); + + if (data == NULL) { + /* data==NULL means that the client was unsubscribed from SCI mode notifications */ + sci_mode_data->notify_cb = NULL; + return BT_GATT_ITER_STOP; + } + + if (!sci_mode_data->notify_cb) { + LOG_ERR("No notification callback present"); + return BT_GATT_ITER_STOP; + } + + if (length != sizeof(uint8_t)) { + LOG_ERR("Unexpected SCI mode notification size: %u", length); + return BT_GATT_ITER_STOP; + } + + sci_mode_data->notify_cb(conn, (enum bt_hids_sci_mode_value) bdata[0]); + + return BT_GATT_ITER_CONTINUE; +} +#endif + int bt_hogp_rep_subscribe(struct bt_hogp *hogp, struct bt_hogp_rep_info *rep, bt_hogp_read_cb func) @@ -1096,6 +1413,59 @@ int bt_hogp_rep_unsubscribe(struct bt_hogp *hogp, return bt_gatt_unsubscribe(hogp->conn, &rep->notify_params); } +#if defined(CONFIG_BT_HOGP_SCI) +int bt_hogp_sci_mode_subscribe(struct bt_hogp *hogp, bt_hogp_sci_mode_changed_cb func) +{ + int err; + struct bt_gatt_subscribe_params *params; + + if (!hogp || !func) { + return -EINVAL; + } + + if (hogp->handlers.sci_mode == 0U) { + LOG_ERR("HID device does not support SCI"); + return -ENOTSUP; + } + + if (hogp->sci_mode_data.notify_cb) { + return -EALREADY; + } + + hogp->sci_mode_data.notify_cb = func; + + params = &hogp->sci_mode_data.notify_params; + params->notify = sci_mode_notify_process; + params->value = BT_GATT_CCC_NOTIFY; + params->value_handle = hogp->handlers.sci_mode; + params->ccc_handle = hogp->handlers.sci_mode_ccc; + atomic_set_bit(params->flags, BT_GATT_SUBSCRIBE_FLAG_VOLATILE); + + err = bt_gatt_subscribe(hogp->conn, params); + if (err) { + LOG_ERR("Report notification subscribe error: %d.", err); + hogp->sci_mode_data.notify_cb = NULL; + return err; + } + LOG_DBG("SCI mode subscribed."); + return err; +} + +int bt_hogp_sci_mode_unsubscribe(struct bt_hogp *hogp) +{ + if (!hogp) { + return -EINVAL; + } + + if (hogp->handlers.sci_mode == 0U) { + LOG_ERR("HID device does not support SCI"); + return -ENOTSUP; + } + + return bt_gatt_unsubscribe(hogp->conn, &hogp->sci_mode_data.notify_params); +} +#endif + /** * @brief Process map read * @@ -1252,7 +1622,7 @@ int bt_hogp_pm_write(struct bt_hogp *hogp, enum bt_hids_pm pm) int bt_hogp_suspend(struct bt_hogp *hogp) { int err; - uint8_t data[] = {BT_HIDS_CONTROL_POINT_SUSPEND}; + uint8_t data[] = {(uint8_t)BT_HIDS_CP_EVT_HOST_SUSP}; err = bt_gatt_write_without_response(hogp->conn, hogp->handlers.cp, @@ -1265,7 +1635,7 @@ int bt_hogp_suspend(struct bt_hogp *hogp) int bt_hogp_exit_suspend(struct bt_hogp *hogp) { int err; - uint8_t data[] = {BT_HIDS_CONTROL_POINT_EXIT_SUSPEND}; + uint8_t data[] = {(uint8_t)BT_HIDS_CP_EVT_HOST_EXIT_SUSP}; err = bt_gatt_write_without_response(hogp->conn, hogp->handlers.cp, @@ -1275,6 +1645,168 @@ int bt_hogp_exit_suspend(struct bt_hogp *hogp) return err; } +#if defined(CONFIG_BT_HOGP_SCI) +bool bt_hogp_sci_supported(const struct bt_hogp *hogp) +{ + return (hogp->handlers.sci_info != 0U) && (hogp->handlers.sci_mode != 0U) + && (hogp->handlers.sci_mode_ccc != 0U); +} + +bool bt_hogp_sci_low_power_mode_supported(const struct bt_hogp *hogp) +{ + if (bt_hogp_sci_supported(hogp)) { + return (hogp->info_val.flags & BT_HIDS_SCI_LOW_POWER_MODE_SUPPORTED) != 0U; + } + + return false; +} + +static uint8_t sci_mode_read_process(struct bt_conn *conn, uint8_t err, + struct bt_gatt_read_params *params, + const void *data, uint16_t length) +{ + (void)conn; + + struct bt_hogp *hogp; + struct bt_hogp_sci_mode_data *sci_mode_data; + const uint8_t *bdata = data; + + hogp = CONTAINER_OF(params, struct bt_hogp, read_params); + sci_mode_data = &hogp->sci_mode_data; + + k_sem_give(&hogp->read_params_sem); + + if (!sci_mode_data->read_cb) { + LOG_ERR("No SCI mode read callback present"); + return BT_GATT_ITER_STOP; + } + + bt_hogp_sci_mode_read_cb cb = sci_mode_data->read_cb; + + + if (err) { + LOG_ERR("HID SCI mode read error"); + cb(hogp, err, BT_HIDS_SCI_MODE_NONE); + return BT_GATT_ITER_STOP; + } + if (length != sizeof(uint8_t) || !data) { + LOG_ERR("Unexpected HID SCI mode size: %u", length); + cb(hogp, -ENOTSUP, BT_HIDS_SCI_MODE_NONE); + return BT_GATT_ITER_STOP; + } + + cb(hogp, err, (enum bt_hids_sci_mode_value)bdata[0]); + + sci_mode_data->read_cb = NULL; + + return BT_GATT_ITER_STOP; + +} + +int bt_hogp_sci_mode_read(struct bt_hogp *hogp, bt_hogp_sci_mode_read_cb func) +{ + int err; + struct bt_gatt_read_params *params; + + if (!hogp || !func) { + return -EINVAL; + } + + if (hogp->handlers.sci_mode == 0U || hogp->handlers.sci_mode_ccc == 0U) { + LOG_ERR("SCI mode handles not assigned"); + return -ENOTSUP; + } + + err = k_sem_take(&hogp->read_params_sem, K_FOREVER); + if (err) { + return err; + } + + if (hogp->sci_mode_data.read_cb != NULL) { + k_sem_give(&hogp->read_params_sem); + return -EBUSY; + } + + params = &hogp->read_params; + hogp->sci_mode_data.read_cb = func; + params->func = sci_mode_read_process; + params->handle_count = 1; + params->single.handle = hogp->handlers.sci_mode; + params->single.offset = 0; + + err = bt_gatt_read(hogp->conn, params); + + if (err) { + hogp->sci_mode_data.read_cb = NULL; + k_sem_give(&hogp->read_params_sem); + return err; + } + + return 0; +} + +int bt_hogp_sci_mode_req(struct bt_hogp *hogp, enum bt_hids_sci_mode_value mode) +{ + uint8_t data = (uint8_t)BT_HIDS_CP_EVT_HOST_SCI_DEFAULT_REQ; + + if (!hogp) { + return -EINVAL; + } + + if (hogp->handlers.sci_mode == 0U) { + LOG_ERR("HID Device does not support SCI"); + return -ENOTSUP; + } + + switch (mode) { + case BT_HIDS_SCI_MODE_DEFAULT: + data = (uint8_t)BT_HIDS_CP_EVT_HOST_SCI_DEFAULT_REQ; + break; + case BT_HIDS_SCI_MODE_FAST: + data = (uint8_t)BT_HIDS_CP_EVT_HOST_SCI_FAST_REQ; + break; + case BT_HIDS_SCI_MODE_LOW_POWER: + if (!bt_hogp_sci_low_power_mode_supported(hogp)) { + LOG_ERR("HID Device does not support SCI Low Power mode"); + return -ENOTSUP; + } + data = (uint8_t)BT_HIDS_CP_EVT_HOST_SCI_LOW_POWER_REQ; + break; + case BT_HIDS_SCI_MODE_FULL_RANGE: + data = (uint8_t)BT_HIDS_CP_EVT_HOST_SCI_FULL_RANGE_REQ; + break; + default: + return -EINVAL; + } + + return bt_gatt_write_without_response(hogp->conn, + hogp->handlers.cp, + &data, + sizeof(data), + false); +} + +int bt_hogp_sci_info_get(struct bt_hogp *hogp, struct bt_hogp_sci_info *sci_info) +{ + if (!hogp || !sci_info) { + return -EINVAL; + } + + if (hogp->handlers.sci_info == 0U) { + LOG_ERR("SCI information handle not assigned"); + return -EINVAL; + } + + memcpy(sci_info, &hogp->sci_info, sizeof(hogp->sci_info)); + + if (!hid_sci_info_supported_intervals_present(&hogp->sci_info)) { + return -ENOTSUP; + } + + return 0; +} +#endif + struct bt_conn *bt_hogp_conn(const struct bt_hogp *hogp) { return hogp->conn; From e4470cf4b59fc18e50b7012fb3bd5de195f96b9f Mon Sep 17 00:00:00 2001 From: Artur Hadasz Date: Wed, 20 May 2026 20:31:54 +0200 Subject: [PATCH 37/37] samples: bluetooth: HID SCI support in central_hids This commit adds usage of the HID SCI feature in the central_hids sample. Signed-off-by: Artur Hadasz --- samples/bluetooth/central_hids/Kconfig | 6 + samples/bluetooth/central_hids/Kconfig.sci | 67 +++++ samples/bluetooth/central_hids/README.rst | 66 +++++ .../bluetooth/central_hids/prj_hid_sci.conf | 46 ++++ samples/bluetooth/central_hids/sample.yaml | 43 ++- samples/bluetooth/central_hids/src/main.c | 253 +++++++++++++++++- .../sysbuild/ipc_radio_hid_sci.conf | 13 + 7 files changed, 474 insertions(+), 20 deletions(-) create mode 100644 samples/bluetooth/central_hids/Kconfig.sci create mode 100644 samples/bluetooth/central_hids/prj_hid_sci.conf create mode 100644 samples/bluetooth/central_hids/sysbuild/ipc_radio_hid_sci.conf diff --git a/samples/bluetooth/central_hids/Kconfig b/samples/bluetooth/central_hids/Kconfig index 2c4a50b3a76a..bd5377d63a88 100644 --- a/samples/bluetooth/central_hids/Kconfig +++ b/samples/bluetooth/central_hids/Kconfig @@ -34,3 +34,9 @@ config SAMPLE_BT_CENTRAL_HIDS_CONTINUOUS_REPORT_RX_STATS_RATE instead of logging every payload. source "Kconfig.zephyr" + +if BT_HOGP_SCI + +rsource "Kconfig.sci" + +endif # BT_HOGP_SCI diff --git a/samples/bluetooth/central_hids/Kconfig.sci b/samples/bluetooth/central_hids/Kconfig.sci new file mode 100644 index 000000000000..98c95d8b79fa --- /dev/null +++ b/samples/bluetooth/central_hids/Kconfig.sci @@ -0,0 +1,67 @@ +# +# Copyright (c) 2026 Nordic Semiconductor ASA +# +# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause +# + +menu "Central HIDS SCI default connection rate parameters" + +# Do not confuse the central default connection rate parameters +# with the HIDS SCI default mode parameters. +# Central default rate parameters (bt_conn_le_conn_rate_set_defaults) apply to future +# connections as the host's default window +# HID SCI default (and other) mode link parameters are chosen in procedures +# with the peripheral and typically differ from these local defaults. + +config CENTRAL_HIDS_SCI_INTERVAL_MIN_125US + int "Minimum connection interval (125 microsecond units)" + default 7 + range 3 32000 + help + Minimum connection interval in 125 microsecond units (LE connection interval + quantum), matching struct bt_conn_le_conn_rate_param.interval_min_125us. + +config CENTRAL_HIDS_SCI_INTERVAL_MAX_125US + int "Maximum connection interval (125 microsecond units)" + default 120 + range CENTRAL_HIDS_SCI_INTERVAL_MIN_125US 32000 + help + Maximum connection interval in 125 microsecond units (LE connection interval + quantum), matching struct bt_conn_le_conn_rate_param.interval_max_125us. + +config CENTRAL_HIDS_SCI_SUBRATE_MIN + int "Subrate factor minimum" + default 1 + range 1 500 + help + Minimum subrate factor, matching struct bt_conn_le_conn_rate_param.subrate_min. + +config CENTRAL_HIDS_SCI_SUBRATE_MAX + int "Subrate factor maximum" + default 4 + range CENTRAL_HIDS_SCI_SUBRATE_MIN 500 + help + Maximum subrate factor, matching struct bt_conn_le_conn_rate_param.subrate_max. + +config CENTRAL_HIDS_SCI_MAX_LATENCY + int "Maximum peripheral latency" + default 100 + range 0 499 + help + Maximum peripheral latency, matching struct bt_conn_le_conn_rate_param.max_latency. + +config CENTRAL_HIDS_SCI_CONTINUATION_NUM + int "Continuation number" + default 0 + range 0 499 + help + Continuation number, matching struct bt_conn_le_conn_rate_param.continuation_number. + +config CENTRAL_HIDS_SCI_SUPERVISION_TIMEOUT_10MS + int "Supervision timeout (units of 10 ms)" + default 3200 + range 10 3200 + help + Link supervision timeout, matching struct bt_conn_le_conn_rate_param.supervision_timeout_10ms. + +endmenu diff --git a/samples/bluetooth/central_hids/README.rst b/samples/bluetooth/central_hids/README.rst index 86b1d12aa976..2e135aa621dc 100644 --- a/samples/bluetooth/central_hids/README.rst +++ b/samples/bluetooth/central_hids/README.rst @@ -92,6 +92,11 @@ User interface In this mode, the buttons have different functionalities than in the normal mode. The available functionalities depend on the sample configuration and are printed in the terminal window after button press. + Currently the following functionalities are available: + + * **Button 2**: Request the next HID SCI mode. Only available if :kconfig:option:`CONFIG_BT_HOGP_SCI` is enabled. + * **Button 4**: Exit the "Alternative button functions" mode. + .. group-tab:: nRF54 DKs Button 0: @@ -116,6 +121,12 @@ User interface In this mode, the buttons have different functionalities than in the normal mode. The available functionalities depend on the sample configuration and are printed in the terminal window after button press. + Currently the following functionalities are available: + + * **Button 1**: Request the next HID SCI mode. Only available if :kconfig:option:`CONFIG_BT_HOGP_SCI` is enabled. + * **Button 3**: Exit the "Alternative button functions" mode. + + Configuration ************* @@ -135,6 +146,8 @@ Building and Running .. include:: /includes/build_and_run_ns.txt +To build the sample with HID SCI support, build with ``-DFILE_SUFFIX=hid_sci`` + Testing ======= @@ -151,6 +164,7 @@ Testing with another development kit 1. |connect_terminal_specific| #. Reset the kit. #. Program the other kit with the :ref:`peripheral_hids_keyboard` sample and reset it. + #. If you see "NFC configuration done" on the peripheral kit, press **Button 4** on the peripheral kit in order for it to start advertising. #. When connected, press **Button 1** on both devices to confirm the passkey value used for bonding, or press **Button 2** to reject it. #. Wait until the HIDS keyboard is detected by the central. All detected descriptors are listed. @@ -194,6 +208,7 @@ Testing with another development kit 1. |connect_terminal_specific| #. Reset the kit. #. Program the other kit with the :ref:`peripheral_hids_keyboard` sample and reset it. + #. If you see "NFC configuration done" on the peripheral kit, press **Button 3** on the peripheral kit in order for it to start advertising. #. When connected, press **Button 0** on both devices to confirm the passkey value used for bonding, or press **Button 1** to reject it. #. Wait until the HIDS keyboard is detected by the central. All detected descriptors are listed. @@ -332,6 +347,57 @@ Testing with Bluetooth Low Energy app #. Press **Button 1** on the kit and observe that the **Protocol Mode** value changes from ``01`` to ``00``. #. Press **Button 0** and **Button 2** one after another and observe that the **Boot Keyboard Output Report** value toggles between ``00`` and ``02``. +Testing with HID SCI support +---------------------------- + +To test the sample with HID SCI support, both the central and the peripheral must be built with ``-DFILE_SUFFIX=hid_sci``. + +.. tabs:: + + .. group-tab:: nRF52 and nRF53 DKs + + 1. |connect_terminal_specific| + #. Reset the kit. + #. Program the other kit with the :ref:`peripheral_hids_keyboard` sample and reset it. + #. If you see "NFC configuration done" on the peripheral kit, press **Button 4** on the peripheral kit in order for it to start advertising. + #. When connected, press **Button 1** on both devices to confirm the passkey value used for bonding, or press **Button 2** to reject it. + #. Wait until the HIDS keyboard is detected by the central. + Check for information similar to the following:: + + HIDS is ready to work + Subscribe in report id: 1 + Subscribe in boot keyboard report + #. Press **Button 4** on the central kit to enter the "Alternative button functions" mode. + #. Press **Button 2** on the central kit and wait for the SCI mode to change to DEFAULT. + #. Cycle through the HID SCI modes by pressing **Button 2** on the central kit. + The HID SCI mode will change to FAST, LOW POWER, FULL RANGE, and DEFAULT again. + You might need to wait a few seconds for the mode to change each time. + You will see a message similar to the following:: + + SCI mode changed notification received, new mode: + + .. group-tab:: nRF54 DKs + + 1. |connect_terminal_specific| + #. Reset the kit. + #. Program the other kit with the :ref:`peripheral_hids_keyboard` sample and reset it. + #. If you see "NFC configuration done" on the peripheral kit, press **Button 3** on the peripheral kit in order for it to start advertising. + #. When connected, press **Button 0** on both devices to confirm the passkey value used for bonding, or press **Button 1** to reject it. + #. Wait until the HIDS keyboard is detected by the central. + Check for information similar to the following:: + + HIDS is ready to work + Subscribe in report id: 1 + Subscribe in boot keyboard report + #. Press **Button 3** on the central kit to enter the "Alternative button functions" mode. + #. Press **Button 1** on the central kit and wait for the SCI mode to change to DEFAULT. + #. Cycle through the HID SCI modes by pressing **Button 1** on the central kit. + The HID SCI mode will change to FAST, LOW POWER, FULL RANGE, and DEFAULT again. + You might need to wait a few seconds for the mode to change each time. + You will see a message similar to the following:: + + SCI mode changed notification received, new mode: + Dependencies ************* diff --git a/samples/bluetooth/central_hids/prj_hid_sci.conf b/samples/bluetooth/central_hids/prj_hid_sci.conf new file mode 100644 index 000000000000..d92a91646625 --- /dev/null +++ b/samples/bluetooth/central_hids/prj_hid_sci.conf @@ -0,0 +1,46 @@ +# +# Copyright (c) 2026 Nordic Semiconductor ASA +# +# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause +# +CONFIG_NCS_SAMPLES_DEFAULTS=y + +CONFIG_BT=y +CONFIG_BT_CENTRAL=y +CONFIG_BT_SMP=y +CONFIG_BT_ATT_TX_COUNT=5 +CONFIG_BT_GATT_CLIENT=y +CONFIG_BT_GATT_DM=y +CONFIG_HEAP_MEM_POOL_SIZE=2048 +CONFIG_BT_HOGP=y + +CONFIG_BT_SCAN=y +CONFIG_BT_SCAN_FILTER_ENABLE=y +CONFIG_BT_SCAN_UUID_CNT=1 +CONFIG_BT_PRIVACY=y + +# Increase BT TX processor thread stack size to prevent stack overflow when receiving directed +# advertising right after boot. On nRF54L15 the maximum measured stack usage is 936 bytes. +CONFIG_BT_TX_PROCESSOR_STACK_SIZE=1024 + +CONFIG_MAIN_STACK_SIZE=2048 +CONFIG_SYSTEM_WORKQUEUE_STACK_SIZE=2048 + +CONFIG_BT_SETTINGS=y +CONFIG_FLASH=y +CONFIG_FLASH_PAGE_LAYOUT=y +CONFIG_FLASH_MAP=y + +CONFIG_DK_LIBRARY=y + +CONFIG_LOG_MODE_DEFERRED=y +CONFIG_LOG_PROCESS_THREAD_SLEEP_MS=100 + +CONFIG_BT_GAP_PERIPHERAL_PREF_PARAMS=n + +# HOGP SCI configuration +CONFIG_BT_SUBRATING=y +CONFIG_BT_LE_EXTENDED_FEAT_SET=y +CONFIG_BT_SHORTER_CONNECTION_INTERVALS=y + +CONFIG_BT_HOGP_SCI=y diff --git a/samples/bluetooth/central_hids/sample.yaml b/samples/bluetooth/central_hids/sample.yaml index 7e9934c096b3..24c9eb0165e4 100644 --- a/samples/bluetooth/central_hids/sample.yaml +++ b/samples/bluetooth/central_hids/sample.yaml @@ -1,6 +1,22 @@ sample: description: Bluetooth Low Energy central Human Interface Device sample name: Bluetooth LE Central HIDS +common: + sysbuild: true + harness: console + harness_config: + type: multi_line + ordered: true + regex: + - "Starting Bluetooth Central HIDS sample" + - "Bluetooth initialized" + - "Scanning successfully started" + timeout: 15 + tags: + - bluetooth + - ci_build + - sysbuild + - ci_samples_bluetooth tests: sample.bluetooth.central_hids: sysbuild: true @@ -25,17 +41,16 @@ tests: - nrf54lv10dk/nrf54lv10a/cpuapp - nrf54lv10dk/nrf54lv10a/cpuapp/ns - nrf54h20dk/nrf54h20/cpuapp - tags: - - bluetooth - - ci_build - - sysbuild - - ci_samples_bluetooth - harness: console - harness_config: - type: multi_line - ordered: true - regex: - - "Starting Bluetooth Central HIDS sample" - - "Bluetooth initialized" - - "Scanning successfully started" - timeout: 15 + sample.bluetooth.central_hids.hid_sci: + sysbuild: true + integration_platforms: + - nrf54l15dk/nrf54l05/cpuapp + - nrf54lm20dk/nrf54lm20a/cpuapp + - nrf54lm20dk/nrf54lm20b/cpuapp + - nrf54lv10dk/nrf54lv10a/cpuapp + platform_allow: + - nrf54l15dk/nrf54l05/cpuapp + - nrf54lm20dk/nrf54lm20a/cpuapp + - nrf54lm20dk/nrf54lm20b/cpuapp + - nrf54lv10dk/nrf54lv10a/cpuapp + extra_args: FILE_SUFFIX=hid_sci diff --git a/samples/bluetooth/central_hids/src/main.c b/samples/bluetooth/central_hids/src/main.c index c49316d7a6da..8d26367b2946 100644 --- a/samples/bluetooth/central_hids/src/main.c +++ b/samples/bluetooth/central_hids/src/main.c @@ -60,6 +60,10 @@ #define KEY_ALTERNATIVE_FUNCTIONS_NUM DK_BTN4 #define KEY_ALTERNATIVE_FUNCTIONS_MASK DK_BTN4_MSK +/* Key used to request next SCI mode */ +#define KEY_ALTERNATIVE_1_SCI_MODE_NEXT_NUM DK_BTN2 +#define KEY_ALTERNATIVE_1_SCI_MODE_NEXT_MASK DK_BTN2_MSK + enum button_functions_mode { BUTTON_FUNCTIONS_MODE_DEFAULT, BUTTON_FUNCTIONS_MODE_AUTHENTICATION, @@ -95,11 +99,28 @@ enum button_functions_mode { */ #define CONTINUOUS_REPORT_RECEIVING_WINDOW_DELTA_US 200 +#define HID_SCI_MODE_CHANGE_TIMEOUT_MS 10000 + +#ifdef CONFIG_BT_HOGP_SCI + +BUILD_ASSERT(CONFIG_CENTRAL_HIDS_SCI_SUBRATE_MAX * (1 + CONFIG_CENTRAL_HIDS_SCI_MAX_LATENCY) <= + 500, + "Core connSubrate*(latency+1) must be <= 500"); +BUILD_ASSERT(CONFIG_CENTRAL_HIDS_SCI_CONTINUATION_NUM < CONFIG_CENTRAL_HIDS_SCI_SUBRATE_MAX, + "continuation number must be less than subrate maximum"); +BUILD_ASSERT(CONFIG_CENTRAL_HIDS_SCI_SUPERVISION_TIMEOUT_10MS * 10000ULL > + (uint64_t)(1 + CONFIG_CENTRAL_HIDS_SCI_MAX_LATENCY) * + CONFIG_CENTRAL_HIDS_SCI_SUBRATE_MAX * + CONFIG_CENTRAL_HIDS_SCI_INTERVAL_MAX_125US * 250, + "supervision timeout must exceed 2*(1+latency)*subrate*interval"); +#endif + static struct bt_conn *default_conn; static struct bt_hogp hogp; static struct bt_conn *auth_conn; static uint8_t capslock_state; static enum button_functions_mode button_functions_mode = BUTTON_FUNCTIONS_MODE_DEFAULT; +static enum bt_hids_sci_mode_value sci_mode_requested = BT_HIDS_SCI_MODE_NONE; static atomic_t cont_report_rx_on = ATOMIC_INIT(0); static uint32_t cont_report_rx_previous_report_cycles; @@ -115,6 +136,9 @@ static uint32_t report_cnt; static void hids_on_ready(struct k_work *work); static K_WORK_DEFINE(hids_ready_work, hids_on_ready); +static void sci_mode_change_timeout_fn(struct k_work *work); +static K_WORK_DELAYABLE_DEFINE(sci_mode_change_timeout, sci_mode_change_timeout_fn); + static void cont_report_rx_exit_work_fn(struct k_work *work); K_WORK_DELAYABLE_DEFINE(cont_report_rx_exit_work, cont_report_rx_exit_work_fn); @@ -157,7 +181,7 @@ static void cont_report_rx_stats_print(uint32_t batch_end_cycles) cont_report_rx_min_interval_us); if (cont_report_rx_interval_us > 0) { - printk("Expected report interval: %" PRIu32 " us\n", cont_report_rx_interval_us); + printk("Report interval: %" PRIu32 " us\n", cont_report_rx_interval_us); printk("Intervals above %" PRIu32 " us: %" PRIu32 "\n", cont_report_rx_interval_us + CONTINUOUS_REPORT_RECEIVING_WINDOW_DELTA_US, @@ -393,6 +417,10 @@ static void disconnected(struct bt_conn *conn, uint8_t reason) bt_conn_unref(default_conn); default_conn = NULL; + if (IS_ENABLED(CONFIG_BT_HOGP_SCI) && sci_mode_requested != BT_HIDS_SCI_MODE_NONE) { + (void) k_work_cancel_delayable(&sci_mode_change_timeout); + sci_mode_requested = BT_HIDS_SCI_MODE_NONE; + } /* This demo doesn't require active scan */ err = bt_scan_start(BT_SCAN_TYPE_SCAN_ACTIVE); @@ -429,13 +457,55 @@ static void le_param_updated(struct bt_conn *conn, uint16_t interval, return; } - cont_report_rx_stats_print(cont_report_rx_previous_report_cycles); + if (atomic_get(&cont_report_rx_on)) { + cont_report_rx_stats_print(cont_report_rx_previous_report_cycles); + } cont_report_rx_data_reset(cont_report_rx_previous_report_cycles); cont_report_rx_interval_us = BT_CONN_INTERVAL_TO_US(interval); printk("Connection interval updated to %" PRIu32 " us\n", cont_report_rx_interval_us); } + +#if CONFIG_BT_HOGP_SCI +static uint32_t conn_rate_effective_report_interval_us(uint32_t interval_us, uint16_t subrate, + uint16_t continuation_number) +{ + __ASSERT(subrate > 0, "Subrate must be greater than 0"); + + uint32_t events_per_period = continuation_number + 1U; + + if (events_per_period > subrate) { + events_per_period = subrate; + } + + return (interval_us * subrate) / events_per_period; +} + +static void conn_rate_changed(struct bt_conn *conn, uint8_t status, + const struct bt_conn_le_conn_rate_changed *params) +{ + ARG_UNUSED(status); + + if (conn != default_conn) { + return; + } + + if (atomic_get(&cont_report_rx_on)) { + cont_report_rx_stats_print(cont_report_rx_previous_report_cycles); + } + cont_report_rx_data_reset(cont_report_rx_previous_report_cycles); + printk("Connection rate changed: interval %u us, subrate factor %u, " + "continuation number %u\n", + params->interval_us, params->subrate_factor, + params->continuation_number); + cont_report_rx_interval_us = conn_rate_effective_report_interval_us(params->interval_us, + params->subrate_factor, params->continuation_number); + printk("Expected report interval: %u us\n", + cont_report_rx_interval_us); +} +#endif + #endif BT_CONN_CB_DEFINE(conn_callbacks) = { @@ -444,6 +514,9 @@ BT_CONN_CB_DEFINE(conn_callbacks) = { .security_changed = security_changed, #ifdef CONFIG_SAMPLE_BT_CENTRAL_HIDS_CONTINUOUS_REPORT_RX .le_param_updated = le_param_updated, +#ifdef CONFIG_BT_HOGP_SCI + .conn_rate_changed = conn_rate_changed, +#endif #endif }; @@ -653,6 +726,44 @@ static void hogp_ready_cb(struct bt_hogp *hogp) k_work_submit(&hids_ready_work); } +static const char *sci_mode_to_string(enum bt_hids_sci_mode_value mode) +{ + switch (mode) { + case BT_HIDS_SCI_MODE_NONE: + return "NONE"; + case BT_HIDS_SCI_MODE_DEFAULT: + return "DEFAULT"; + case BT_HIDS_SCI_MODE_FAST: + return "FAST"; + case BT_HIDS_SCI_MODE_LOW_POWER: + return "LOW_POWER"; + case BT_HIDS_SCI_MODE_FULL_RANGE: + return "FULL_RANGE"; + } + + return "UNKNOWN"; +} + +static void sci_mode_change_timeout_fn(struct k_work *work) +{ + printk("SCI mode change timeout occurred.\n"); + sci_mode_requested = BT_HIDS_SCI_MODE_NONE; +} + +static void sci_mode_notify_cb(struct bt_conn *conn, const uint8_t mode) +{ + const char *mode_str = sci_mode_to_string(mode); + + printk("SCI mode changed notification received, new mode: %s\n", mode_str); + + if (mode == sci_mode_requested) { + (void) k_work_cancel_delayable(&sci_mode_change_timeout); + sci_mode_requested = BT_HIDS_SCI_MODE_NONE; + } else { + printk("The new SCI mode does not match the requested one\n"); + } +} + static void hids_on_ready(struct k_work *work) { int err; @@ -690,6 +801,13 @@ static void hids_on_ready(struct k_work *work) printk("Subscribe error (%d)\n", err); } } + + if (IS_ENABLED(CONFIG_BT_HOGP_SCI)) { + err = bt_hogp_sci_mode_subscribe(&hogp, sci_mode_notify_cb); + if (err) { + printk("SCI mode subscribe error (%d)\n", err); + } + } } static void hogp_prep_fail_cb(struct bt_hogp *hogp, int err) @@ -842,6 +960,116 @@ static void num_comp_reply(bool accept) button_functions_mode = BUTTON_FUNCTIONS_MODE_DEFAULT; } +#ifdef CONFIG_BT_HOGP_SCI +static int set_default_conn_rate(void) +{ + int err; + uint16_t local_min_interval_us; + uint16_t interval_min_125us = CONFIG_CENTRAL_HIDS_SCI_INTERVAL_MIN_125US; + + err = bt_conn_le_read_min_conn_interval(&local_min_interval_us); + if (err) { + printk("Failed to read min conn interval (err %d)\n", err); + } + + if (!err && interval_min_125us < local_min_interval_us / 125U) { + printk("Configured minimum connection interval (%u) is below controller " + "minimum %u; using %u\n", + interval_min_125us, local_min_interval_us / 125U, + local_min_interval_us / 125U); + + interval_min_125us = local_min_interval_us / 125U; + if (interval_min_125us > CONFIG_CENTRAL_HIDS_SCI_INTERVAL_MAX_125US) { + printk("ERROR: controller connection interval minimum is larger " + "than configured maximum (%u > %u)!\n", + interval_min_125us, CONFIG_CENTRAL_HIDS_SCI_INTERVAL_MAX_125US); + return -EINVAL; + } + } + + const struct bt_conn_le_conn_rate_param params = { + .interval_min_125us = interval_min_125us, + .interval_max_125us = CONFIG_CENTRAL_HIDS_SCI_INTERVAL_MAX_125US, + .subrate_min = CONFIG_CENTRAL_HIDS_SCI_SUBRATE_MIN, + .subrate_max = CONFIG_CENTRAL_HIDS_SCI_SUBRATE_MAX, + .max_latency = CONFIG_CENTRAL_HIDS_SCI_MAX_LATENCY, + .continuation_number = CONFIG_CENTRAL_HIDS_SCI_CONTINUATION_NUM, + .supervision_timeout_10ms = CONFIG_CENTRAL_HIDS_SCI_SUPERVISION_TIMEOUT_10MS, + .min_ce_len_125us = BT_HCI_LE_SCI_CE_LEN_MIN_125US, + .max_ce_len_125us = BT_HCI_LE_SCI_CE_LEN_MAX_125US, + }; + + return bt_conn_le_conn_rate_set_defaults(¶ms); +} +#endif + +static void button_sci_mode_next(void) +{ + static uint8_t sci_mode_idx; + static const uint8_t mode_val[] = { + BT_HIDS_SCI_MODE_DEFAULT, + BT_HIDS_SCI_MODE_FAST, + BT_HIDS_SCI_MODE_LOW_POWER, + BT_HIDS_SCI_MODE_FULL_RANGE, + }; + int err = 0; + + if (!bt_hogp_ready_check(&hogp)) { + printk("HID device not ready\n"); + return; + } + + if (!bt_hogp_sci_supported(&hogp)) { + printk("HID device does not support SCI\n"); + return; + } + + if (sci_mode_requested != BT_HIDS_SCI_MODE_NONE) { + printk("SCI mode request already in progress!\n"); + return; + } + + switch (mode_val[sci_mode_idx]) { + case BT_HIDS_SCI_MODE_DEFAULT: + printk("Sending SCI DEFAULT mode request\n"); + break; + case BT_HIDS_SCI_MODE_FAST: + printk("Sending SCI FAST mode request\n"); + break; + case BT_HIDS_SCI_MODE_LOW_POWER: + if (!bt_hogp_sci_low_power_mode_supported(&hogp)) { + printk("The connected Device doesn't support the SCI LOW POWER mode\n"); + err = -ENOTSUP; + break; + } + printk("Sending SCI LOW POWER mode request\n"); + break; + case BT_HIDS_SCI_MODE_FULL_RANGE: + printk("Sending SCI FULL RANGE mode request\n"); + break; + default: + /* Should never get here */ + __ASSERT(0, "Unknown SCI mode"); + return; + } + + if (!err) { + err = bt_hogp_sci_mode_req(&hogp, mode_val[sci_mode_idx]); + } + + if (!err) { + printk("Sent %s SCI mode request to the device\n", + sci_mode_to_string(mode_val[sci_mode_idx])); + sci_mode_requested = mode_val[sci_mode_idx]; + (void) k_work_schedule(&sci_mode_change_timeout, + K_MSEC(HID_SCI_MODE_CHANGE_TIMEOUT_MS)); + } else { + printk("SCI mode request failed (err: %d)\n", err); + } + + sci_mode_idx = (sci_mode_idx + 1) % ARRAY_SIZE(mode_val); +} + static void button_authentication_mode_handler(uint32_t button) { __ASSERT(auth_conn, "No authentication connection"); @@ -868,16 +1096,21 @@ static void button_default_mode_handler(uint32_t button) button_functions_mode = BUTTON_FUNCTIONS_MODE_ALTERNATIVE_1; printk("Alternative button functions activated.\n"); - /* Print the available alternative button functions here. */ - - printk("Button %d: exit alternative button functions\n", + if (IS_ENABLED(CONFIG_BT_HOGP_SCI)) { + printk("Button %d: Next SCI mode\n", + BUTTON_NUM_FOR_BOARD(KEY_ALTERNATIVE_1_SCI_MODE_NEXT_NUM)); + } + printk("Button %d: Exit alternative button functions\n", BUTTON_NUM_FOR_BOARD(KEY_ALTERNATIVE_FUNCTIONS_NUM)); } } static void button_alternative_1_mode_handler(uint32_t button) { - if (button & KEY_ALTERNATIVE_FUNCTIONS_MASK) { + if (IS_ENABLED(CONFIG_BT_HOGP_SCI) && + (button & KEY_ALTERNATIVE_1_SCI_MODE_NEXT_MASK)) { + button_sci_mode_next(); + } else if (button & KEY_ALTERNATIVE_FUNCTIONS_MASK) { button_functions_mode = BUTTON_FUNCTIONS_MODE_DEFAULT; printk("Alternative button functions deactivated.\n"); } @@ -1004,6 +1237,14 @@ int main(void) printk("Bluetooth initialized\n"); +#ifdef CONFIG_BT_HOGP_SCI + err = set_default_conn_rate(); + if (err) { + printk("Failed to set the default connection rate (err %d)\n", err); + return 0; + } +#endif + if (IS_ENABLED(CONFIG_SETTINGS)) { settings_load(); } diff --git a/samples/bluetooth/central_hids/sysbuild/ipc_radio_hid_sci.conf b/samples/bluetooth/central_hids/sysbuild/ipc_radio_hid_sci.conf new file mode 100644 index 000000000000..900d657b2d39 --- /dev/null +++ b/samples/bluetooth/central_hids/sysbuild/ipc_radio_hid_sci.conf @@ -0,0 +1,13 @@ +# +# Copyright (c) 2026 Nordic Semiconductor ASA +# +# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause +# + +CONFIG_BT_CTLR_EXTENDED_FEAT_SET=y +CONFIG_BT_CTLR_SUBRATING=y +CONFIG_BT_CTLR_SHORTER_CONNECTION_INTERVALS=y + +# 254 is the minimum required CONFIG_BT_BUF_EVT_RX_SIZE to support +# HID SCI information read. +CONFIG_BT_BUF_EVT_RX_SIZE=254