Skip to content

mtd: spi-nor: add support to SPI 1-2-2 and SPI 1-4-4 protocols

Cyrille Pitchen linux-mtd lkml 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3mtd: spi-nor: add support of SPI protocols like SPI 1-2-2 and SPI 1-4-4drivers/mtd/devices/m25p80.c drivers/mtd/spi-nor/aspeed-smc.c drivers/mtd/spi-nor/atmel-quadspi.c +8 more+515 -1400 replies
2/3mtd: spi-nor: remove unused set_quad_mode() functiondrivers/mtd/spi-nor/spi-nor.c+0 -240 replies
3/3mtd: m25p80: add support of SPI 1-2-2 and 1-4-4 protocolsdrivers/mtd/devices/m25p80.c+92 -300 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/3] mtd: spi-nor: add support to SPI 1-2-2 and SPI 1-4-4 protocols

Hi all,

this series of patches updates the spi-nor framework to add support to more SPI protocols. Also the 3rd argument of spi_nor_scan() is changed so we can now make the difference between read and write operations. Indeed some SPI controllers may support Quad SPI protocols only for read operations but not for write operations.

The new argument is designed so SPI controller drivers can precisely describe their hardware capabilies to the spi-nor framework. In turn, this framework selects the right SPI protocols, op code, number of dummy cycles and so on for (Fast) Read and Page Program commands by computing the best match between the SPI memory and controller hardware capabilities.

Please note that a spi_nor_basic_flash_parameter structure is also introduced by this series. It's used to describe the hardware capabilities and requirements of SPI memories. The structure fields are based on what can be read from the SFDP Basic Flash Parameter table of the JESD216B specification. Indeed this series of patch is also a base for a further series which will add support to the SFDP tables in the spi-nor framework.

This series is based on the next branch of the spi-nor tree.

Best regards,

Cyrille

Cyrille Pitchen (3):
mtd: spi-nor: add support of SPI protocols like SPI 1-2-2 and SPI

    1-4-4

mtd: spi-nor: remove unused set_quad_mode() function
mtd: m25p80: add support of SPI 1-2-2 and 1-4-4 protocols

 drivers/mtd/devices/m25p80.c          | 133 +++++++++++----
 drivers/mtd/spi-nor/aspeed-smc.c      |  22 +--
 drivers/mtd/spi-nor/atmel-quadspi.c   |  82 ++++++----
 drivers/mtd/spi-nor/cadence-quadspi.c |  18 ++-
 drivers/mtd/spi-nor/fsl-quadspi.c     |   8 +-
 drivers/mtd/spi-nor/hisi-sfc.c        |  31 +++-
 drivers/mtd/spi-nor/intel-spi.c       |   6 +-
 drivers/mtd/spi-nor/mtk-quadspi.c     |  16 +-
 drivers/mtd/spi-nor/nxp-spifi.c       |  21 +--
 drivers/mtd/spi-nor/spi-nor.c         | 295 +++++++++++++++++++++++++---------
 include/linux/mtd/spi-nor.h           | 163 +++++++++++++++++--
 11 files changed, 604 insertions(+), 191 deletions(-)
Signature · 1 line
2.7.4