]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
spi: add driver for NXP XSPI controller
authorHaibo Chen <haibo.chen@nxp.com>
Tue, 16 Dec 2025 03:20:14 +0000 (11:20 +0800)
committerMark Brown <broonie@kernel.org>
Wed, 17 Dec 2025 12:04:47 +0000 (12:04 +0000)
commit29c8c00d9f9db5fb659b6f05f9e8964afc13f3e2
tree2b9911c513e630aae9cda818c3e410a249836536
parent64ba616741bcfc4c7ef1ed856179328300ca0422
spi: add driver for NXP XSPI controller

Add driver support for NXP XSPI controller.

XSPI is a flexible SPI host controller which supports up to
2 external devices (2 CS). It support Single/Dual/Quad/Octal
mode data transfer.

The difference between XSPI and Flexspi:
1.the register layout is total different.
2.XSPI support multiple independent execution environments
(EENVs) for HW virtualization with some limitations. Each EENV
has its own interrupt and its own set of programming registers
that exists in a specific offset range in the XSPI memory map.
The main environment (EENV0) address space contains all of the
registers for controlling EENV0 plus all of the general XSPI
control and programming registers. The register mnemonics for
the user environments (EENV1 to EENV4) have "_SUB_n" appended
to the mnemonic for the corresponding main-environment register.

Current driver based on EENV0, which means system already give
EENV0 right to linux.

This driver use SPI memory interface of the SPI framework to
issue flash memory operations. Tested this driver with UBIFS
and mtd_debug on NXP i.MX943 EVK board which has one spi nor
MT35XU512ABA flash. Now this driver has the following key
features:
- Support up to OCT DDR mode
- Support AHB read
- Support IP read and IP write
- Support two CS

Reviewed-by: Frank Li <Frank.Li@nxp.com>
Signed-off-by: Haibo Chen <haibo.chen@nxp.com>
Link: https://patch.msgid.link/20251216-xspi-v7-2-282525220979@nxp.com
Signed-off-by: Mark Brown <broonie@kernel.org>
MAINTAINERS
drivers/spi/Kconfig
drivers/spi/Makefile
drivers/spi/spi-nxp-xspi.c [new file with mode: 0644]