From d59b1a4d651aea2bdcf865a76e08d8ee0e9b6c20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simen=20S=2E=20R=C3=B8stad?= Date: Mon, 14 Oct 2024 16:15:14 +0200 Subject: [PATCH] projectwide: Update sdk-nrf MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Update sdk-nrf Signed-off-by: Simen S. Røstad --- .github/workflows/build.yml | 4 ---- .github/workflows/dfu_check.yml | 1 + .github/workflows/sonarcloud.yml | 1 + app/Kconfig.sysbuild | 10 ---------- app/boards/thingy91x_nrf9151_ns.overlay | 7 +++++++ app/overlay-memfault.conf | 1 + app/prj.conf | 19 +++++++++++-------- app/sample.yaml | 2 +- app/src/modules/battery/battery.c | 2 +- app/src/modules/memfault/Kconfig.memfault | 2 +- app/src/modules/transport/Kconfig.transport | 2 +- app/sysbuild.conf | 8 ++++++++ app/sysbuild/mcuboot/prj.conf | 1 - scripts/nrf_wifi_hal_memory_leak_fix.patch | 12 ------------ west.yml | 2 +- 15 files changed, 34 insertions(+), 40 deletions(-) delete mode 100644 app/Kconfig.sysbuild create mode 100644 app/sysbuild.conf delete mode 100644 scripts/nrf_wifi_hal_memory_leak_fix.patch diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f48529d3..9620579a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -93,9 +93,6 @@ jobs: echo "MEMFAULT_SW_TYPE=${{ inputs.memfault_sw_type }}" >> $GITHUB_ENV fi - - name: Apply nrf_wifi HAL patch - run: git apply thingy91x-oob/scripts/nrf_wifi_hal_memory_leak_fix.patch --directory=nrfxlib - # Out-of-box firmware build - name: Build nrf91 firmware @@ -189,7 +186,6 @@ jobs: - name: Apply Connectivity Bridge patch for debug feature run: | git apply thingy91x-oob/scripts/debug_feature_nrf.patch --directory=nrf - git apply thingy91x-oob/scripts/debug_feature_zephyr.patch --directory=zephyr - name: Build nrf53 firmware working-directory: nrf/applications/connectivity_bridge diff --git a/.github/workflows/dfu_check.yml b/.github/workflows/dfu_check.yml index 18e415fa..21bb57af 100644 --- a/.github/workflows/dfu_check.yml +++ b/.github/workflows/dfu_check.yml @@ -35,6 +35,7 @@ jobs: west config manifest.group-filter +bsec west config build.sysbuild True west update -o=--depth=1 -n + west blobs fetch hal_nordic - name: Install dependencies run: | diff --git a/.github/workflows/sonarcloud.yml b/.github/workflows/sonarcloud.yml index d8cf9cc8..e74ed86f 100644 --- a/.github/workflows/sonarcloud.yml +++ b/.github/workflows/sonarcloud.yml @@ -40,6 +40,7 @@ jobs: west config manifest.group-filter +bsec west config build.sysbuild True west update -o=--depth=1 -n + west blobs fetch hal_nordic - name: Install dependencies run: | diff --git a/app/Kconfig.sysbuild b/app/Kconfig.sysbuild deleted file mode 100644 index 29af9c4a..00000000 --- a/app/Kconfig.sysbuild +++ /dev/null @@ -1,10 +0,0 @@ -# -# Copyright (c) 2024 Nordic Semiconductor -# -# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause -# - -config WIFI_NRF700X - default y if BOARD_THINGY91X_NRF9151_NS - -source "${ZEPHYR_BASE}/share/sysbuild/Kconfig" diff --git a/app/boards/thingy91x_nrf9151_ns.overlay b/app/boards/thingy91x_nrf9151_ns.overlay index e41a9600..7cc42d5a 100644 --- a/app/boards/thingy91x_nrf9151_ns.overlay +++ b/app/boards/thingy91x_nrf9151_ns.overlay @@ -17,9 +17,16 @@ chosen { nordic,modem-trace-uart = &uart1; + zephyr,wifi = &nordic_wlan0; }; }; &uart1 { status = "okay"; }; + + +/* Switch to nrf7000 emulation so that scan-only mode is used. */ +&nrf70 { + compatible = "nordic,nrf7000-spi"; +}; diff --git a/app/overlay-memfault.conf b/app/overlay-memfault.conf index 42ff38b1..33be234c 100644 --- a/app/overlay-memfault.conf +++ b/app/overlay-memfault.conf @@ -10,4 +10,5 @@ CONFIG_MEMFAULT_NCS_DEVICE_ID_IMEI=y CONFIG_MEMFAULT_NCS_PROJECT_KEY="" CONFIG_MEMFAULT_LOGGING_RAM_SIZE=4096 CONFIG_MEMFAULT_HEAP_STATS=y +CONFIG_MEMFAULT_NCS_LOCATION_METRICS=y CONFIG_MEMFAULT_HTTP_DEDICATED_WORKQUEUE_STACK_SIZE=1560 diff --git a/app/prj.conf b/app/prj.conf index 670705dc..69386a6f 100644 --- a/app/prj.conf +++ b/app/prj.conf @@ -10,7 +10,8 @@ CONFIG_RESET_ON_FATAL_ERROR=y CONFIG_LOG_MODE_DEFERRED=y CONFIG_LOG_BUFFER_SIZE=4096 CONFIG_DK_LIBRARY=y -CONFIG_POSIX_MAX_FDS=10 +CONFIG_ZVFS_OPEN_MAX=10 +# CONFIG_COMMON_LIBC_MALLOC_ARENA_SIZE=3808 ? CONFIG_PWM=y # Heap and stacks @@ -19,6 +20,7 @@ CONFIG_MAIN_STACK_SIZE=4096 CONFIG_AT_MONITOR_HEAP_SIZE=2048 # Wifi scan requires extended heap size CONFIG_HEAP_MEM_POOL_SIZE=40000 +CONFIG_HEAP_MEM_POOL_IGNORE_MIN=y CONFIG_SYSTEM_WORKQUEUE_STACK_SIZE=1280 # Enable Networking and Connection Manager. @@ -117,8 +119,8 @@ CONFIG_BUILD_S1_VARIANT=y CONFIG_COAP_CLIENT_THREAD_PRIORITY=0 CONFIG_COAP_CLIENT_BLOCK_SIZE=1024 CONFIG_COAP_CLIENT_MESSAGE_SIZE=1024 -CONFIG_COAP_CLIENT_STACK_SIZE=1024 -CONFIG_COAP_EXTENDED_OPTIONS_LEN_VALUE=40 +CONFIG_COAP_CLIENT_STACK_SIZE=1536 +CONFIG_COAP_EXTENDED_OPTIONS_LEN_VALUE=192 # nRF Cloud CONFIG_NRF_CLOUD_CLIENT_ID_PREFIX="oob-" @@ -158,10 +160,10 @@ CONFIG_LTE_NETWORK_MODE_LTE_M_NBIOT_GPS=y # configs for Wi-Fi CONFIG_WIFI=y -CONFIG_WIFI_NRF700X=y -CONFIG_WIFI_NRF700X_SKIP_LOCAL_ADMIN_MAC=y -CONFIG_NRF700X_BH_WQ_STACK_SIZE=1024 -CONFIG_NRF700X_IRQ_WQ_STACK_SIZE=1024 +CONFIG_WIFI_NRF70=y +CONFIG_WIFI_NRF70_SKIP_LOCAL_ADMIN_MAC=y +CONFIG_NRF70_BH_WQ_STACK_SIZE=1024 +CONFIG_NRF70_IRQ_WQ_STACK_SIZE=1024 # Align this with CONFIG_LOCATION_METHOD_WIFI_SCANNING_RESULTS_MAX_CNT CONFIG_NRF_WIFI_SCAN_MAX_BSS_CNT=10 @@ -179,7 +181,7 @@ CONFIG_NRF_MODEM_LIB_SHMEM_TX_SIZE=4096 CONFIG_NRF_MODEM_LIB_SHMEM_RX_SIZE=4096 # Scan only using offload API -CONFIG_WPA_SUPP=n +CONFIG_WIFI_NM_WPA_SUPPLICANT=n # For nRF9160 the default is socket interface CONFIG_NET_DEFAULT_IF_ETHERNET=y @@ -235,3 +237,4 @@ CONFIG_TASK_WDT_CHANNELS=9 # Device power management CONFIG_PM_DEVICE=y +CONFIG_PM_DEVICE_RUNTIME=n diff --git a/app/sample.yaml b/app/sample.yaml index 0d8b2612..9c74785c 100644 --- a/app/sample.yaml +++ b/app/sample.yaml @@ -18,7 +18,7 @@ tests: - thingy91x/nrf9151/ns extra_configs: - CONFIG_MEMFAULT_NCS_PROJECT_KEY="PROJECTKEY" - extra_args: EXTRA_CONF_FILE=overlay-memfault.conf + extra_args: EXTRA_CONF_FILE="overlay-memfault.conf;overlay-modemtrace.conf;overlay-etb.conf" tags: ci_build app.build.bootloader_update: build_only: true diff --git a/app/src/modules/battery/battery.c b/app/src/modules/battery/battery.c index cb161626..f366dd56 100644 --- a/app/src/modules/battery/battery.c +++ b/app/src/modules/battery/battery.c @@ -233,7 +233,7 @@ static void sample(int64_t *ref_time) NPM1300_CHG_STATUS_CC_MASK | NPM1300_CHG_STATUS_CV_MASK)) != 0; - state_of_charge = nrf_fuel_gauge_process(voltage, current, temp, delta, NULL); + state_of_charge = nrf_fuel_gauge_process(voltage, current, temp, delta, false, NULL); LOG_DBG("State of charge: %f", (double)roundf(state_of_charge)); LOG_DBG("The battery is %s", charging ? "charging" : "not charging"); diff --git a/app/src/modules/memfault/Kconfig.memfault b/app/src/modules/memfault/Kconfig.memfault index 597d21cd..dd587a41 100644 --- a/app/src/modules/memfault/Kconfig.memfault +++ b/app/src/modules/memfault/Kconfig.memfault @@ -19,7 +19,7 @@ if APP_MEMFAULT config APP_MEMFAULT_THREAD_STACK_SIZE int "Thread stack size" - default 2048 + default 1536 config APP_MEMFAULT_WATCHDOG_TIMEOUT_SECONDS int "Watchdog timeout seconds" diff --git a/app/src/modules/transport/Kconfig.transport b/app/src/modules/transport/Kconfig.transport index cf3f7219..f958ec1c 100644 --- a/app/src/modules/transport/Kconfig.transport +++ b/app/src/modules/transport/Kconfig.transport @@ -15,7 +15,7 @@ config APP_TRANSPORT_RECONNECTION_TIMEOUT_SECONDS config APP_TRANSPORT_THREAD_STACK_SIZE int "Thread stack size" - default 2048 + default 1536 config APP_TRANSPORT_MESSAGE_QUEUE_SIZE int "Message queue size" diff --git a/app/sysbuild.conf b/app/sysbuild.conf new file mode 100644 index 00000000..1f6da431 --- /dev/null +++ b/app/sysbuild.conf @@ -0,0 +1,8 @@ +# +# Copyright (c) 2024 Nordic Semiconductor ASA +# +# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause +# + +SB_CONFIG_WIFI_NRF70=y +SB_CONFIG_WIFI_NRF70_SCAN_ONLY=y diff --git a/app/sysbuild/mcuboot/prj.conf b/app/sysbuild/mcuboot/prj.conf index ae6a05e9..60f8d41b 100644 --- a/app/sysbuild/mcuboot/prj.conf +++ b/app/sysbuild/mcuboot/prj.conf @@ -1,7 +1,6 @@ CONFIG_PM=n CONFIG_MAIN_STACK_SIZE=10240 -CONFIG_MBEDTLS_CFG_FILE="mcuboot-mbedtls-cfg.h" CONFIG_BOOT_SWAP_SAVE_ENCTLV=n CONFIG_BOOT_ENCRYPT_IMAGE=n diff --git a/scripts/nrf_wifi_hal_memory_leak_fix.patch b/scripts/nrf_wifi_hal_memory_leak_fix.patch deleted file mode 100644 index aa88235a..00000000 --- a/scripts/nrf_wifi_hal_memory_leak_fix.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/nrf_wifi/hw_if/hal/src/hal_api.c b/nrf_wifi/hw_if/hal/src/hal_api.c -index 1b23fa42..5765e383 100644 ---- a/nrf_wifi/hw_if/hal/src/hal_api.c -+++ b/nrf_wifi/hw_if/hal/src/hal_api.c -@@ -1258,6 +1258,7 @@ void nrf_wifi_hal_dev_rem(struct nrf_wifi_hal_dev_ctx *hal_dev_ctx) - - nrf_wifi_osal_spinlock_free(hal_dev_ctx->lock_hal); - nrf_wifi_osal_spinlock_free(hal_dev_ctx->lock_rx); -+ nrf_wifi_osal_spinlock_free(hal_dev_ctx->lock_recovery); - - nrf_wifi_utils_q_free(hal_dev_ctx->event_q); - diff --git a/west.yml b/west.yml index 4d78065d..bbb390bc 100644 --- a/west.yml +++ b/west.yml @@ -14,5 +14,5 @@ manifest: - name: nrf remote: ncs repo-path: sdk-nrf - revision: cfb2a11d013959f2fa68a1dc9460a1cf1c6fda82 + revision: dd1b59877d3bf2aff976bc3c3a2a0dca135d9f85 import: true