Skip to content

Commit b062985

Browse files
bama-nordicjukkar
authored andcommitted
[nrf fromlist] drivers: nrf_wifi: Restructure to carve out a new nrf70 bus lib
The nrf wifi drivers include code related to qspi/spi bus. This work moves bus related files to a new nrf70 bus library which is now independent of the core driver and facilitlates building applications directly using the bus APIs, agnostic to enabling wifi configs. Upstream PR #: 82372 Signed-off-by: Bansidhar P.M <[email protected]> (cherry picked from commit b515453)
1 parent 167370f commit b062985

File tree

23 files changed

+298
-635
lines changed

23 files changed

+298
-635
lines changed

drivers/wifi/nrf_wifi/CMakeLists.txt

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ set(FW_BINS_BASE ${ZEPHYR_NRF_WIFI_MODULE_DIR}/zephyr/blobs/wifi_fw_bins)
1111

1212
zephyr_include_directories(
1313
inc
14-
src/qspi/inc
1514
# for net_sprint_ll_addr
1615
${ZEPHYR_BASE}/subsys/net/ip
1716
)
@@ -24,12 +23,6 @@ zephyr_library_sources_ifdef(CONFIG_NRF70_SR_COEX
2423
src/coex.c
2524
)
2625

27-
zephyr_library_sources(
28-
src/qspi/src/device.c
29-
src/qspi/src/rpu_hw_if.c
30-
src/qspi/src/ficr_prog.c
31-
)
32-
3326
zephyr_library_sources_ifndef(CONFIG_NRF70_OFFLOADED_RAW_TX
3427
src/fmac_main.c
3528
)
@@ -65,14 +58,6 @@ zephyr_library_sources_ifdef(CONFIG_NRF70_STA_MODE
6558
zephyr_library_sources_ifdef(CONFIG_NRF70_STA_MODE
6659
src/wpa_supp_if.c)
6760

68-
zephyr_library_sources_ifdef(CONFIG_NRF70_ON_QSPI
69-
src/qspi/src/qspi_if.c
70-
)
71-
72-
zephyr_library_sources_ifdef(CONFIG_NRF70_ON_SPI
73-
src/qspi/src/spi_if.c
74-
)
75-
7661
zephyr_library_sources_ifdef(CONFIG_NRF70_UTIL
7762
src/wifi_util.c
7863
)
@@ -88,6 +73,8 @@ zephyr_compile_definitions_ifdef(CONFIG_NRF70_ON_QSPI
8873
-DNRF53_ERRATA_159_ENABLE_WORKAROUND=0
8974
)
9075

76+
target_link_libraries(nrf_wifi PRIVATE nrf70-buslib)
77+
9178
if (CONFIG_NRF_WIFI_BUILD_ONLY_MODE)
9279
message(WARNING "
9380
------------------------------------------------------------------------

drivers/wifi/nrf_wifi/Kconfig.nrfwifi

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ menuconfig WIFI_NRF70
1111
select NET_L2_ETHERNET_MGMT if NETWORKING && NET_L2_ETHERNET
1212
select WIFI_USE_NATIVE_NETWORKING if NETWORKING
1313
select EXPERIMENTAL if !SOC_SERIES_NRF53X && !SOC_SERIES_NRF91X
14+
select NRF70_BUSLIB
1415
default y
1516
depends on \
1617
DT_HAS_NORDIC_NRF7002_SPI_ENABLED || DT_HAS_NORDIC_NRF7002_QSPI_ENABLED || \
@@ -33,16 +34,9 @@ config WIFI_NRF7000
3334
bool
3435
default y if DT_HAS_NORDIC_NRF7000_SPI_ENABLED || DT_HAS_NORDIC_NRF7000_QSPI_ENABLED
3536

36-
37-
module = WIFI_NRF70_BUS
38-
module-dep = LOG
39-
module-str = Log level for Wi-Fi nRF70 bus layers
40-
module-help = Sets log level for Wi-Fi nRF70 bus layers
41-
source "subsys/net/Kconfig.template.log_config.net"
42-
43-
config WIFI_NRF70_BUS_LOG_LEVEL
44-
# Enable error by default
45-
default 1
37+
config NRF70_QSPI_LOW_POWER
38+
bool "low power mode in QSPI"
39+
default y if NRF_WIFI_LOW_POWER
4640

4741
choice NRF70_OPER_MODES
4842
bool "nRF70 operating modes"

drivers/wifi/nrf_wifi/src/qspi/inc/ficr_prog.h

Lines changed: 0 additions & 23 deletions
This file was deleted.

0 commit comments

Comments
 (0)