devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/15] Introduce Allwinner H6/H616 NAND controller support
@ 2025-10-10  8:40 Richard Genoud
  2025-10-10  8:40 ` [PATCH 01/15] mtd: rawnand: sunxi: Remove superfluous register readings Richard Genoud
                   ` (14 more replies)
  0 siblings, 15 replies; 33+ messages in thread
From: Richard Genoud @ 2025-10-10  8:40 UTC (permalink / raw)
  To: Miquel Raynal, Richard Weinberger, Vignesh Raghavendra,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai,
	Jernej Skrabec, Samuel Holland
  Cc: Wentao Liang, Uwe Kleine-König, Maxime Ripard,
	Thomas Petazzoni, linux-mtd, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, Richard Genoud

Hi everyone,

This patch series introduce H6/H616 NAND controller support (but not yet
the DMA/MDMA part).

All the work was done on a H616 board with a Kioxia TC58NVG1S3HTA00 NAND
chip.
ECC is supported, as well as scrambling.

H6 SoC has not been tested, but it shares all registers with H616, plus
some registers dedicated to Embedded Crypto Engine that H616 lacks.

This IP has quite some register fields modified from the A10/A23, but in
the end, it works more or less the same.
Main differences with A10/A23 are:
- The need for 2 more clocks (for ECC and MBUS)
- The use of a new USER_DATA_LEN register
- More ECC strengths (44, 52, 68, 72, 76 and 80 bits / 1KB)
- MDMA based on chained buffers
- some registers layouts have changed (mainly due do the stronger ECC)

Patch 1 removes a superfluous call, and is independent from the others.

Patch 2 introduces allwinner,sun50i-h616-nand-controller compatible
in order to differentiate from the A10 and A23.

Patch 3 adds the NAND controller node to sun50i-h616.dtsi

Patches 4-14 are paving the way to the introduction of H616 NAND
controller support.
They are small, without functional change and easier to review than a
big patch.
They move a fixed value (register offset, field mask, SRAM size) into
the struct sunxi_nfc_caps when those values are different on H6/H616.

Patch 15 introduce the support for H6/H616 NAND controller.

Regards,
Richard

Richard Genoud (15):
  mtd: rawnand: sunxi: Remove superfluous register readings
  dt-bindings: mtd: sunxi: Add new compatible
  arm64: dts: allwinner: h616: add NAND controller
  mtd: nand: sunxi: move ecc strenghts in sunxi_nfc_caps
  mtd: nand: sunxi: introduce reg_ecc_err_cnt in sunxi_nfc_caps
  mtd: nand: sunxi: introduce reg_user_data in sunxi_nfc_caps
  mtd: nand: sunxi: rework pattern found registers
  mtd: nand: sunxi: add has_ecc_block_512 capability
  mtd: nand: sunxi: introduce ecc_mode_mask in sunxi_nfc_caps
  mtd: nand: sunxi: introduce random en/dir in sunxi_nfc_caps
  mtd: nand: sunxi: introduce reg_pat_id in sunxi_nfc_caps
  mtd: nand: sunxi: introduce reg_spare_area in sunxi_nfc_caps
  mtd: nand: sunxi: introduce ecc_err_mask in sunxi_nfc_caps
  mtd: nand: sunxi: introduce sram_size in sunxi_nfc_caps
  mtd: rawnand: sunxi: Add support for H616 nand controller

 .../mtd/allwinner,sun4i-a10-nand.yaml         |  56 ++-
 .../arm64/boot/dts/allwinner/sun50i-h616.dtsi |  50 +++
 drivers/mtd/nand/raw/sunxi_nand.c             | 342 +++++++++++++++---
 3 files changed, 390 insertions(+), 58 deletions(-)

-- 
2.47.3


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

end of thread, other threads:[~2025-10-13 12:01 UTC | newest]

Thread overview: 33+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-10  8:40 [PATCH 00/15] Introduce Allwinner H6/H616 NAND controller support Richard Genoud
2025-10-10  8:40 ` [PATCH 01/15] mtd: rawnand: sunxi: Remove superfluous register readings Richard Genoud
2025-10-11 10:15   ` Jernej Škrabec
2025-10-10  8:40 ` [PATCH 02/15] dt-bindings: mtd: sunxi: Add new compatible Richard Genoud
2025-10-10  8:45   ` Krzysztof Kozlowski
2025-10-10 10:16     ` Richard GENOUD
2025-10-10  8:49   ` Krzysztof Kozlowski
2025-10-10 10:18     ` Richard GENOUD
2025-10-11 10:27       ` Jernej Škrabec
2025-10-13 11:56         ` Richard GENOUD
2025-10-10  8:40 ` [PATCH 03/15] arm64: dts: allwinner: h616: add NAND controller Richard Genoud
2025-10-10  8:47   ` Krzysztof Kozlowski
2025-10-10 10:22     ` Richard GENOUD
2025-10-10 10:24       ` Krzysztof Kozlowski
2025-10-11 10:33   ` Jernej Škrabec
2025-10-13 11:59     ` Richard GENOUD
2025-10-10  8:40 ` [PATCH 04/15] mtd: nand: sunxi: move ecc strenghts in sunxi_nfc_caps Richard Genoud
2025-10-11 10:41   ` Jernej Škrabec
2025-10-13 12:00     ` Richard GENOUD
2025-10-10  8:40 ` [PATCH 05/15] mtd: nand: sunxi: introduce reg_ecc_err_cnt " Richard Genoud
2025-10-10  8:40 ` [PATCH 06/15] mtd: nand: sunxi: introduce reg_user_data " Richard Genoud
2025-10-10  8:40 ` [PATCH 07/15] mtd: nand: sunxi: rework pattern found registers Richard Genoud
2025-10-10  8:40 ` [PATCH 08/15] mtd: nand: sunxi: add has_ecc_block_512 capability Richard Genoud
2025-10-10  8:40 ` [PATCH 09/15] mtd: nand: sunxi: introduce ecc_mode_mask in sunxi_nfc_caps Richard Genoud
2025-10-10  8:40 ` [PATCH 10/15] mtd: nand: sunxi: introduce random en/dir " Richard Genoud
2025-10-10  8:40 ` [PATCH 11/15] mtd: nand: sunxi: introduce reg_pat_id " Richard Genoud
2025-10-10  8:40 ` [PATCH 12/15] mtd: nand: sunxi: introduce reg_spare_area " Richard Genoud
2025-10-10  8:40 ` [PATCH 13/15] mtd: nand: sunxi: introduce ecc_err_mask " Richard Genoud
2025-10-10  8:40 ` [PATCH 14/15] mtd: nand: sunxi: introduce sram_size " Richard Genoud
2025-10-10  8:40 ` [PATCH 15/15] mtd: rawnand: sunxi: Add support for H616 nand controller Richard Genoud
2025-10-11  1:00   ` kernel test robot
2025-10-11 10:48   ` Jernej Škrabec
2025-10-13 12:01     ` Richard GENOUD

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).