Re: [PATCH v11 00/26] mtd: rawnand: sunxi: fix page transfers and controller error recovery

From: Miquel Raynal

Date: Fri Dec 04 2026 - 16:34:10 EST


On Fri, 20 Nov 2026 18:10:23 -0700, James Hilliard wrote:
> PIO reuses ECC slot zero for every step, but the protected OOB length
> belongs to the logical step. In DMA mode the controller can run out of
> user-data registers partway through a page. In both cases the driver
> can return or program OOB bytes for the wrong step.
>
> A10 and A23 reserve a fixed number of protected OOB bytes per step.
> H616 can vary that number. The first patch selects the two layouts
> through controller match data so ECC strength selection and protected
> byte placement use the same rules. The next two patches compute OOB
> offsets from chip geometry and share ECC read handling between PIO
> and DMA.
>
> [...]

Applied to nand/next, thanks!

[01/26] mtd: rawnand: sunxi: select the protected OOB layout from match data
commit: d0819f70890a49e5e5666c862e7b18d5caf08441
[02/26] mtd: rawnand: sunxi: compute protected OOB offsets from page geometry
commit: 56db1c432a39d431aab0e85b34756c2301ec3e46
[03/26] mtd: rawnand: sunxi: share ECC read handling between PIO and DMA
commit: b2b9e59c8e4a151b7ca8e86a2bf64d833b77df65
[04/26] mtd: rawnand: sunxi: use the logical step's OOB length in PIO
commit: 80c92c70612244f08fa7b3de8b7a6bf5d6a725d4
[05/26] mtd: rawnand: sunxi: reject ECC layouts that overwrite the bad-block marker
commit: c2eb0a72e70d9b2caf4be4deaac980bf10c12acd
[06/26] mtd: rawnand: sunxi: use page reads to reposition small-page NAND
commit: dbc26dd25909cd9c99485b1af772c6bc3d32bb72
[07/26] mtd: rawnand: sunxi: propagate page-setup and erased-check errors
commit: bc8a27ea33d2257888289bb542885769ee301a0a
[08/26] mtd: rawnand: sunxi: drain interrupts before reusing the completion
commit: 13077c9eed5123f28487efd9299d53861034d02b
[09/26] mtd: rawnand: sunxi: stop failed program operations and disable ECC
commit: fac7e7be54ba9b31be236d1e39898248e86c0481
[10/26] mtd: rawnand: sunxi: select the pattern ID for the current ECC step
commit: 4d9119a93c723e25fd723f88d5d0d1712df6017e
[11/26] mtd: rawnand: sunxi: preserve synthesized zero-pattern data and OOB
commit: 4ad7f043bbbe0a27897cb4ba282a66424158be8b
[12/26] mtd: rawnand: sunxi: handle ECC results in the batch reader
commit: 9969e59beea3ecea916846ea64a70fa24bac45f6
[13/26] mtd: rawnand: sunxi: propagate buffer and column transfer errors
commit: 2fa3b4a2950e7a5ab0e339de9ff08f3354c71629
[14/26] mtd: rawnand: sunxi: avoid a second program confirm for OOB writes
commit: cc0caeb9a537186e8ab85782acd819b4747c51fb
[15/26] mtd: rawnand: sunxi: bound DMA batches by the user-data register bank
commit: 3529ca2468a40892c4df857ab5ead6408c293b98
[16/26] mtd: rawnand: sunxi: limit DMA subpage ECC results to the requested range
commit: 7bdaaeefa34888cddcf5ac89b83fe6e882e34c84
[17/26] mtd: rawnand: sunxi: preserve bad-block markers on erased OOB reads
commit: 1e620f1b274fb0b011801380a1134a9cf79a6087
[18/26] mtd: rawnand: sunxi: send all address cycles in split operations
commit: 9b93f6e5f973a90cbcca38dc52d588b8c5c81ef4
[19/26] mtd: rawnand: sunxi: propagate chip clock setup errors
commit: 431b4d47817fd3020efcc3d86eb3bd8cd841e3b1
[20/26] mtd: rawnand: sunxi: limit buffer transfers to the command byte count
commit: 7561747ef3a5f7533c23bfd3ed50db14bac02595
[21/26] mtd: rawnand: sunxi: skip unavailable NAND child nodes
commit: 8a498c04e4d75c5150f285e3b510ee7c7aa82fda
[22/26] mtd: rawnand: sunxi: scan all chips before registering MTD devices
commit: 6eae51c4e867d907b4d27a1d7b4457df318c654e
[23/26] dt-bindings: mtd: sunxi: require the H616 AHB reset
commit: 42af2ba8a1acac901aa152226d3976c5daab25af
[24/26] mtd: rawnand: sunxi: reset the H616 data path after DMA aborts
commit: ed58cff6312729d3676791420e4f21d88c1b4e52
[25/26] mtd: rawnand: sunxi: reuse ECC status within each transfer
commit: 4eabdba1fbb5ba4c1c20365145ef052f28971c79
[26/26] mtd: rawnand: sunxi: reduce user-data length register accesses
commit: 05be7782c6fbf421898ce2a515a341d4597cdf55

Patche(s) should be available on mtd/linux.git and will be
part of the next PR (provided that no robot complains by then).

Kind regards,
Miquèl