]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
spi: nxp_fspi: Support i.MX8DXL flexspi
authorYe Li <ye.li@nxp.com>
Wed, 24 Sep 2025 02:11:26 +0000 (10:11 +0800)
committerFabio Estevam <festevam@gmail.com>
Fri, 26 Sep 2025 12:52:23 +0000 (09:52 -0300)
According to i.MX8DXL A1 errata ERR050601, concurrent read accesses
from the A35 cores to the peripherals within the LSIO subsystem
(region 0_5DXX_XXXX) and address spaces in the regions
[0_0000_0000 – 0_1BFF_FFFF] and [4_0000_0000 – 4_3FFF_FFFF] can collide
and cause data corruption in the returned data, with no failure report.
Even a single A35 core accessing both these regions can trigger the issue
because an A35 core can have more than one parallel read operation in
progress.

The flexspi0 AHB memory is in LSIO region mentioned in above errata.
So we can't use AHB read, only can read data from FIFO.
Add the compatible string for 8DXL and use a flag for the IPS read.

Signed-off-by: Ye Li <ye.li@nxp.com>
drivers/spi/nxp_fspi.c

index 6e2aee4672b29aa254246fde16e52842eba571cf..3dfb54b19680e1f4fb0dab2f57700b9981a7b153 100644 (file)
@@ -346,6 +346,15 @@ static const struct nxp_fspi_devtype_data imx8qxp_data = {
        .little_endian = true,  /* little-endian    */
 };
 
+static const struct nxp_fspi_devtype_data imx8dxl_data = {
+       .rxfifo = SZ_512,       /* (64  * 64 bits)  */
+       .txfifo = SZ_1K,        /* (128 * 64 bits)  */
+       .ahb_buf_size = SZ_2K,  /* (256 * 64 bits)  */
+       .quirks = FSPI_QUIRK_USE_IP_ONLY,
+       .lut_num = 32,
+       .little_endian = true,  /* little-endian    */
+};
+
 struct nxp_fspi {
        struct udevice *dev;
        void __iomem *iobase;
@@ -1091,6 +1100,7 @@ static const struct udevice_id nxp_fspi_ids[] = {
        { .compatible = "nxp,imx8mm-fspi", .data = (ulong)&imx8mm_data, },
        { .compatible = "nxp,imx8mp-fspi", .data = (ulong)&imx8mm_data, },
        { .compatible = "nxp,imx8qxp-fspi", .data = (ulong)&imx8qxp_data, },
+       { .compatible = "nxp,imx8dxl-fspi", .data = (ulong)&imx8dxl_data, },
        { .compatible = "nxp,imxrt1170-fspi", .data = (ulong)&imxrt1170_data, },
        { }
 };