Skip to content

Commit 765d598

Browse files
committed
[nrf toup][nrfconnect] Align OpenThread Kconfigs with Zephyr changes
Replace `NET_L2_OPENTHREAD` with `OPENTHREAD` as OpenThread Kconfigs were moved from L2 to OpenThread module. Keep `NET_L2_OPENTHREAD` if there is dependency to networking. Signed-off-by: Adrian Gielniewski <adrian.gielniewski@nordicsemi.no>
1 parent 9229594 commit 765d598

26 files changed

Lines changed: 75 additions & 59 deletions

File tree

config/nrfconnect/chip-module/CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ matter_add_gn_arg_string("zephyr_cc" ${CMAKE_C_COMP
147147
matter_add_gn_arg_string("zephyr_cxx" ${CMAKE_CXX_COMPILER})
148148
matter_add_gn_arg_string("chip_app_zap_dir" ${CHIP_APP_ZAP_DIR})
149149
matter_add_gn_arg_bool ("chip_logging" CONFIG_LOG)
150-
matter_add_gn_arg_bool ("chip_enable_openthread" CONFIG_NET_L2_OPENTHREAD)
150+
matter_add_gn_arg_bool ("chip_enable_openthread" CONFIG_OPENTHREAD)
151151
matter_add_gn_arg_bool ("chip_openthread_ftd" CONFIG_OPENTHREAD_FTD)
152152
matter_add_gn_arg_bool ("chip_config_network_layer_ble" CONFIG_BT)
153153
matter_add_gn_arg_bool ("chip_inet_config_enable_ipv4" CONFIG_CHIP_IPV4)
@@ -167,7 +167,7 @@ matter_add_gn_arg_bool ("chip_enable_icd_server" CONFIG_CHIP_EN
167167
matter_add_gn_arg_bool ("chip_enable_factory_data" CONFIG_CHIP_FACTORY_DATA)
168168
matter_add_gn_arg_bool ("chip_enable_read_client" CONFIG_CHIP_ENABLE_READ_CLIENT)
169169
matter_add_gn_arg_bool ("chip_mdns_minimal" CONFIG_WIFI_NRF70)
170-
matter_add_gn_arg_bool ("chip_mdns_platform" CONFIG_NET_L2_OPENTHREAD)
170+
matter_add_gn_arg_bool ("chip_mdns_platform" CONFIG_OPENTHREAD)
171171

172172
if (CONFIG_CHIP_ENABLE_ICD_SUPPORT)
173173
matter_add_gn_arg_bool ("chip_enable_icd_lit" CONFIG_CHIP_ICD_LIT_SUPPORT)
@@ -189,7 +189,7 @@ endif()
189189

190190
if(CONFIG_WIFI_NRF70)
191191
matter_add_gn_arg_string("chip_mdns" "minimal")
192-
elseif (CONFIG_NET_L2_OPENTHREAD)
192+
elseif (CONFIG_OPENTHREAD)
193193
matter_add_gn_arg_string("chip_mdns" "platform")
194194
else()
195195
matter_add_gn_arg_string("chip_mdns" "none")

config/nrfconnect/chip-module/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ config CHIP_IPV4
314314
config CHIP_OPENTHREAD_JOINER_ENABLED
315315
bool "Specify whether the Thread Joiner functionality is used when it is enabled"
316316
default n
317-
depends on NET_L2_OPENTHREAD
317+
depends on OPENTHREAD
318318
depends on OPENTHREAD_JOINER
319319
help
320320
If disabled, it allows to optimize memory usage even if Thread Joiner

config/nrfconnect/chip-module/Kconfig.defaults

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ config HEAP_MEM_POOL_IGNORE_MIN
7070

7171
config CHIP_MALLOC_SYS_HEAP_SIZE
7272
default 10240 if SOC_SERIES_NRF54LX # nRF54L requires more memory due to crypto backend
73-
default 8192 if NET_L2_OPENTHREAD
73+
default 8192 if OPENTHREAD
7474

7575
config MPSL_WORK_STACK_SIZE
7676
default 2048 if SOC_SERIES_NRF54LX # nRF54L requires more memory due to crypto backend
@@ -104,6 +104,8 @@ endif # MPSL
104104
# Zephyr networking configuration
105105
# ==============================================================================
106106

107+
if CONFIG_NETWORKING
108+
107109
config NET_IPV6_MLD
108110
default y
109111

@@ -135,6 +137,8 @@ config NET_BUF_TX_COUNT
135137
config NET_SOCKETS_POLL_MAX
136138
default 6 if CHIP_WIFI
137139

140+
endif # NETWORKING
141+
138142
# ==============================================================================
139143
# Bluetooth Low Energy configuration
140144
# ==============================================================================
@@ -260,7 +264,7 @@ config NRF_WIFI_FW_PATCH_DFU
260264
default y if NRF_WIFI_PATCHES_EXT_FLASH_STORE
261265

262266
# ==============================================================================
263-
# OpenThread configuration
267+
# OpenThread L2 configuration
264268
# ==============================================================================
265269

266270
config NET_L2_OPENTHREAD
@@ -272,6 +276,17 @@ if NET_L2_OPENTHREAD
272276
config IEEE802154_NRF5_RX_STACK_SIZE
273277
default 1024
274278

279+
endif # NET_L2_OPENTHREAD
280+
281+
# ==============================================================================
282+
# OpenThread configuration
283+
# ==============================================================================
284+
285+
config OPENTHREAD
286+
default y if !WIFI_NRF70
287+
288+
if OPENTHREAD
289+
275290
config OPENTHREAD_THREAD_STACK_SIZE
276291
default 6144 if (PSA_CRYPTO_DRIVER_CC3XX && PSA_CRYPTO_DRIVER_OBERON) || PSA_CRYPTO_DRIVER_CRACEN
277292
default 4096
@@ -281,7 +296,7 @@ config OPENTHREAD_DEFAULT_TX_POWER
281296
default 3 if SOC_SERIES_NRF53X
282297
default 8 if SOC_SERIES_NRF52X || SOC_SERIES_NRF54LX
283298

284-
endif # NET_L2_OPENTHREAD
299+
endif # OPENTHREAD
285300

286301
# ==============================================================================
287302
# Wi-Fi configuration

config/zephyr/Kconfig

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ config CHIP_PROJECT_CONFIG
329329
config CHIP_ENABLE_DNSSD_SRP
330330
bool "OpenThread Service Registration Protocol"
331331
default y
332-
depends on NET_L2_OPENTHREAD
332+
depends on OPENTHREAD
333333
imply OPENTHREAD_ECDSA
334334
imply OPENTHREAD_SRP_CLIENT
335335
help
@@ -339,15 +339,15 @@ config CHIP_ENABLE_DNSSD_SRP
339339
config CHIP_ENABLE_DNS_CLIENT
340340
bool "OpenThread DNS client"
341341
default y
342-
depends on NET_L2_OPENTHREAD
342+
depends on OPENTHREAD
343343
imply OPENTHREAD_DNS_CLIENT
344344
help
345345
Enables using the OpenThread DNS client for the Matter service discovery.
346346

347347
config CHIP_ENABLE_ICD_SUPPORT
348348
bool "Matter Intermittently Connected Devices support"
349349
default n
350-
imply OPENTHREAD_MTD_SED if NET_L2_OPENTHREAD
350+
imply OPENTHREAD_MTD_SED if OPENTHREAD
351351
help
352352
Enables the Intermittently Connected Device (ICD) support in Matter.
353353

@@ -456,7 +456,7 @@ config CHIP_THREAD_SSED
456456

457457
config CHIP_OPENTHREAD_CONFIG
458458
string "Custom OpenThread configuration file"
459-
depends on NET_L2_OPENTHREAD
459+
depends on OPENTHREAD
460460
help
461461
Provides a path to an OpenThread configuration file. The path can be
462462
either absolute or relative to the application directory. When this option

config/zephyr/chip-module/CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,14 +95,14 @@ if(CONFIG_CHIP)
9595
matter_add_gn_arg_bool("chip_progress_logging" CONFIG_MATTER_LOG_LEVEL GREATER_EQUAL 3)
9696
matter_add_gn_arg_bool("chip_detail_logging" CONFIG_MATTER_LOG_LEVEL GREATER_EQUAL 4)
9797
matter_add_gn_arg_bool("chip_automation_logging" FALSE)
98-
matter_add_gn_arg_bool("chip_enable_openthread" CONFIG_NET_L2_OPENTHREAD)
98+
matter_add_gn_arg_bool("chip_enable_openthread" CONFIG_OPENTHREAD)
9999
matter_add_gn_arg_bool("chip_openthread_ftd" CONFIG_OPENTHREAD_FTD)
100100
matter_add_gn_arg_bool("chip_inet_config_enable_ipv4" CONFIG_CHIP_IPV4)
101101
matter_add_gn_arg_bool("chip_enable_wifi" CONFIG_WIFI)
102102
matter_add_gn_arg_bool("chip_config_network_layer_ble" CONFIG_BT)
103103
matter_add_gn_arg_bool("chip_mdns_minimal" CONFIG_WIFI)
104104
matter_add_gn_arg_bool("chip_mdns_minimal" CONFIG_NET_L2_ETHERNET)
105-
matter_add_gn_arg_bool("chip_mdns_platform" CONFIG_NET_L2_OPENTHREAD)
105+
matter_add_gn_arg_bool("chip_mdns_platform" CONFIG_OPENTHREAD)
106106
matter_add_gn_arg_bool("chip_inet_config_enable_tcp_endpoint" CONFIG_CHIP_BUILD_TESTS)
107107
matter_add_gn_arg_bool("chip_malloc_sys_heap" CONFIG_CHIP_MALLOC_SYS_HEAP)
108108
matter_add_gn_arg_bool("chip_inet_config_enable_tcp_endpoint" FALSE)
@@ -122,7 +122,7 @@ if(CONFIG_CHIP)
122122
matter_add_gn_arg_string("chip_mdns" "minimal")
123123
elseif(CONFIG_NET_L2_ETHERNET)
124124
matter_add_gn_arg_string("chip_mdns" "minimal")
125-
elseif(CONFIG_NET_L2_OPENTHREAD)
125+
elseif(CONFIG_OPENTHREAD)
126126
matter_add_gn_arg_string("chip_mdns" "platform")
127127
else()
128128
matter_add_gn_arg_string("chip_mdns" "none")

examples/all-clusters-app/nrfconnect/Kconfig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ config STATE_LEDS
2323
the device into a network or the factory reset initiation.
2424

2525
# Sample configuration used for Thread networking
26-
if NET_L2_OPENTHREAD
26+
if OPENTHREAD
2727

2828
choice OPENTHREAD_NORDIC_LIBRARY_CONFIGURATION
2929
default OPENTHREAD_NORDIC_LIBRARY_MTD
@@ -33,7 +33,7 @@ choice OPENTHREAD_DEVICE_TYPE
3333
default OPENTHREAD_MTD
3434
endchoice
3535

36-
endif # NET_L2_OPENTHREAD
36+
endif # OPENTHREAD
3737

3838
rsource "../../../config/nrfconnect/chip-module/Kconfig.features"
3939
rsource "../../../config/nrfconnect/chip-module/Kconfig.defaults"

examples/all-clusters-app/nrfconnect/main/AppTask.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ CHIP_ERROR AppTask::Init()
142142
return err;
143143
}
144144

145-
#if defined(CONFIG_NET_L2_OPENTHREAD)
145+
#if defined(CONFIG_OPENTHREAD)
146146
err = ThreadStackMgr().InitThreadStack();
147147
if (err != CHIP_NO_ERROR)
148148
{
@@ -164,7 +164,7 @@ CHIP_ERROR AppTask::Init()
164164
sWiFiCommissioningInstance.Init();
165165
#else
166166
return CHIP_ERROR_INTERNAL;
167-
#endif // CONFIG_NET_L2_OPENTHREAD
167+
#endif // CONFIG_OPENTHREAD
168168

169169
// Initialize LEDs
170170
LEDWidget::InitGpio();
@@ -507,7 +507,7 @@ void AppTask::ChipEventHandler(const ChipDeviceEvent * event, intptr_t /* arg */
507507
sHaveBLEConnections = ConnectivityMgr().NumBLEConnections() != 0;
508508
UpdateStatusLED();
509509
break;
510-
#if defined(CONFIG_NET_L2_OPENTHREAD)
510+
#if defined(CONFIG_OPENTHREAD)
511511
case DeviceEventType::kDnssdInitialized:
512512
#if CONFIG_CHIP_OTA_REQUESTOR
513513
InitBasicOTARequestor();

examples/all-clusters-minimal-app/nrfconnect/Kconfig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ config STATE_LEDS
2323
the device into a network or the factory reset initiation.
2424

2525
# Sample configuration used for Thread networking
26-
if NET_L2_OPENTHREAD
26+
if OPENTHREAD
2727

2828
choice OPENTHREAD_NORDIC_LIBRARY_CONFIGURATION
2929
default OPENTHREAD_NORDIC_LIBRARY_MTD
@@ -33,7 +33,7 @@ choice OPENTHREAD_DEVICE_TYPE
3333
default OPENTHREAD_MTD
3434
endchoice
3535

36-
endif # NET_L2_OPENTHREAD
36+
endif # OPENTHREAD
3737

3838
rsource "../../../config/nrfconnect/chip-module/Kconfig.features"
3939
rsource "../../../config/nrfconnect/chip-module/Kconfig.defaults"

examples/light-switch-app/nrfconnect/Kconfig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ config STATE_LEDS
2424
'n' does not disable the LED indicating the state of the simulated bolt.
2525

2626
# Sample configuration used for Thread networking
27-
if NET_L2_OPENTHREAD
27+
if OPENTHREAD
2828

2929
choice OPENTHREAD_NORDIC_LIBRARY_CONFIGURATION
3030
default OPENTHREAD_NORDIC_LIBRARY_MTD
@@ -38,7 +38,7 @@ config CHIP_ENABLE_ICD_SUPPORT
3838
bool
3939
default y
4040

41-
endif # NET_L2_OPENTHREAD
41+
endif # OPENTHREAD
4242

4343
if CHIP_WIFI
4444

examples/light-switch-app/nrfconnect/main/AppTask.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ CHIP_ERROR AppTask::Init()
147147
return err;
148148
}
149149

150-
#if defined(CONFIG_NET_L2_OPENTHREAD)
150+
#if defined(CONFIG_OPENTHREAD)
151151
err = ThreadStackMgr().InitThreadStack();
152152
if (err != CHIP_NO_ERROR)
153153
{
@@ -486,7 +486,7 @@ void AppTask::ChipEventHandler(const ChipDeviceEvent * event, intptr_t /* arg */
486486
sHaveBLEConnections = ConnectivityMgr().NumBLEConnections() != 0;
487487
UpdateStatusLED();
488488
break;
489-
#if defined(CONFIG_NET_L2_OPENTHREAD)
489+
#if defined(CONFIG_OPENTHREAD)
490490
case DeviceEventType::kDnssdInitialized:
491491
#if CONFIG_CHIP_OTA_REQUESTOR
492492
InitBasicOTARequestor();

0 commit comments

Comments
 (0)