public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH v2 0/9] mtd: spi-nand: Continuous read support
@ 2024-08-26 10:14 Miquel Raynal
  2024-08-26 10:14 ` [PATCH v2 1/9] mtd: nand: Rename the NAND IO iteration helper Miquel Raynal
                   ` (8 more replies)
  0 siblings, 9 replies; 20+ messages in thread
From: Miquel Raynal @ 2024-08-26 10:14 UTC (permalink / raw)
  To: Richard Weinberger, Vignesh Raghavendra, Tudor Ambarus,
	Pratyush Yadav, Michael Walle, linux-mtd
  Cc: Julien Su, Alvin Zhou, Thomas Petazzoni, Miquel Raynal

Hello,

After the raw NAND series, here is an equivalent series bringing
continuous/sequential read support to spi-nand. The goal is to optimize
the reads when several consecutive pages are read. More explanations
about the "physics" in the patch 4 adding continuous read to the core.

The feature stops at the block boundary for two reasons:
* some vendors did not implement more
* NANDs are accessed through UBI these days, and there is absolutely no
guarantee (quite the opposite) two consecutive LEBs will end-up into two
consecutive PEBs.

The feature was tested using Macronix NANDs, and thus the vendor driver
is updated to expose this new feature.

Benchmarks are available in the last commit, but the overall the speed
gains are impressive: up to 45% when reading a block in 1-1-4 mode,
where a substantial time is lost waiting for the chip to be ready.

Modified userspace tools are also available for testing:
* https://lore.kernel.org/linux-mtd/20240826094629.19065-1-miquel.raynal@bootlin.com/T/#t
* https://github.com/miquelraynal/mtd-utils branch: cont-read

Cheers,
Miquèl

Changes in v2:
* A Reviewed-by from Pratyush.
* Dropped the static key optimization and turned the logic per-chip
  instead of global. 

Miquel Raynal (9):
  mtd: nand: Rename the NAND IO iteration helper
  mtd: nand: Introduce a block iterator
  mtd: spi-nand: Isolate the MTD read logic in a helper
  mtd: spi-nand: Add continuous read support
  mtd: spi-nand: Expose spinand_write_reg_op()
  mtd: spi-nand: macronix: Fix helper name
  mtd: spi-nand: macronix: Extract the bitflip retrieval logic
  mtd: spi-nand: macronix: Add a possible bitflip status flag
  mtd: spi-nand: macronix: Continuous read support

 drivers/mtd/nand/spi/core.c     | 216 ++++++++++++++++++++++++++++----
 drivers/mtd/nand/spi/macronix.c | 122 +++++++++++++-----
 include/linux/mtd/nand.h        |  90 +++++++++++--
 include/linux/mtd/spinand.h     |  17 +++
 4 files changed, 385 insertions(+), 60 deletions(-)

-- 
2.43.0


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2024-09-06 15:07 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-26 10:14 [PATCH v2 0/9] mtd: spi-nand: Continuous read support Miquel Raynal
2024-08-26 10:14 ` [PATCH v2 1/9] mtd: nand: Rename the NAND IO iteration helper Miquel Raynal
2024-09-06 15:03   ` Miquel Raynal
2024-08-26 10:14 ` [PATCH v2 2/9] mtd: nand: Introduce a block iterator Miquel Raynal
2024-09-06 15:03   ` Miquel Raynal
2024-08-26 10:14 ` [PATCH v2 3/9] mtd: spi-nand: Isolate the MTD read logic in a helper Miquel Raynal
2024-09-06 15:03   ` Miquel Raynal
2024-08-26 10:14 ` [PATCH v2 4/9] mtd: spi-nand: Add continuous read support Miquel Raynal
2024-09-04 14:23   ` Pratyush Yadav
2024-09-06 15:03   ` Miquel Raynal
2024-08-26 10:14 ` [PATCH v2 5/9] mtd: spi-nand: Expose spinand_write_reg_op() Miquel Raynal
2024-09-06 15:03   ` Miquel Raynal
2024-08-26 10:14 ` [PATCH v2 6/9] mtd: spi-nand: macronix: Fix helper name Miquel Raynal
2024-09-06 15:02   ` Miquel Raynal
2024-08-26 10:14 ` [PATCH v2 7/9] mtd: spi-nand: macronix: Extract the bitflip retrieval logic Miquel Raynal
2024-09-06 15:02   ` Miquel Raynal
2024-08-26 10:14 ` [PATCH v2 8/9] mtd: spi-nand: macronix: Add a possible bitflip status flag Miquel Raynal
2024-09-06 15:02   ` Miquel Raynal
2024-08-26 10:14 ` [PATCH v2 9/9] mtd: spi-nand: macronix: Continuous read support Miquel Raynal
2024-09-06 15:02   ` Miquel Raynal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox