Skip to content

Commit b49df25

Browse files
committed
drivers: mspi: Add shim driver for sQSPI
Add a translation layer that allows using the sQSPI soft peripheral through the Zephyr MSPI API. Also modify the manifest to pull in related changes required in sdk-zephyr. Signed-off-by: Andrzej Głąbek <[email protected]>
1 parent 1b616da commit b49df25

File tree

6 files changed

+626
-1
lines changed

6 files changed

+626
-1
lines changed

drivers/mspi/CMakeLists.txt

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,27 @@
66

77
zephyr_library_amend()
88
zephyr_library_sources_ifdef(CONFIG_MSPI_NRFE mspi_nrfe.c)
9+
10+
if(CONFIG_MSPI_NRF_SQSPI)
11+
set(SP_DIR ${ZEPHYR_NRFXLIB_MODULE_DIR}/softperipheral)
12+
set(SQSPI_DIR ${SP_DIR}/sQSPI)
13+
14+
zephyr_library_compile_definitions(
15+
NRFX_QSPI2_ENABLED=1
16+
NRFX_QSPI2_MAX_NUM_DATA_LINES=4
17+
)
18+
zephyr_library_include_directories(
19+
${SP_DIR}/include
20+
${SQSPI_DIR}/include
21+
)
22+
zephyr_library_include_directories_ifdef(CONFIG_SOC_NRF54L15
23+
${SQSPI_DIR}/include/nrf54l15
24+
)
25+
zephyr_library_include_directories_ifdef(CONFIG_SOC_NRF54H20
26+
${SQSPI_DIR}/include/nrf54h20
27+
)
28+
zephyr_library_sources(
29+
${SQSPI_DIR}/src/nrfx_qspi2.c
30+
mspi_sqspi.c
31+
)
32+
endif()

drivers/mspi/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@
44
if MSPI
55

66
rsource "Kconfig.nrfe"
7+
rsource "Kconfig.sqspi"
78

89
endif # MSPI

drivers/mspi/Kconfig.sqspi

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# Copyright (c) 2025 Nordic Semiconductor ASA
2+
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
3+
4+
config MSPI_NRF_SQSPI
5+
bool "sQSPI driver"
6+
default y
7+
depends on DT_HAS_NORDIC_NRF_SQSPI_ENABLED
8+
select PINCTRL
9+
select GPIO if $(dt_compat_any_has_prop,$(DT_COMPAT_NORDIC_NRF_SQSPI),ce-gpios)

0 commit comments

Comments
 (0)