[PATCH v3 0/2] PL353 SW ECC fixes

Andrea Scian via B4 Relay posted 2 patches 2 days, 11 hours ago
drivers/mtd/nand/raw/pl35x-nand-controller.c | 4 ++++
1 file changed, 4 insertions(+)
[PATCH v3 0/2] PL353 SW ECC fixes
Posted by Andrea Scian via B4 Relay 2 days, 11 hours ago
PL353 has some known errata with its ECC implementation and it may be
useful to switch to software ECC, to avoid issue with this.

On-die ECC is already supported (while I didn't test it) but when
enabling SW ECC we get operation-not-supported error during page write
(page read already work correctly)

IMHO it's enough to have 1-bit Hamming ECC correction, because this is
the only one supported on PL353, but this might be a wrong assumption.

This has been tested with nandflipbits and mtd_nandbiterrs

---
Changes in v3:
- remove wrong SW ECC algo selection
- add Fixes and CC to stable
- Link to v2: https://lore.kernel.org/r/20260126-pl353-soft-ecc-support-v2-0-fcd74b6e955f@dave.eu

Changes in v2:
- change dev_info() into dev_dbg() to reduce messages
- Link to v1: https://lore.kernel.org/r/20260121-pl353-soft-ecc-support-v1-0-00ad8e160d83@dave.eu

---
Andrea Scian (2):
      mtd: rawnand: pl353: Fix software ECC support
      mtd: rawnand: pl353: Add message about ECC mode

 drivers/mtd/nand/raw/pl35x-nand-controller.c | 4 ++++
 1 file changed, 4 insertions(+)
---
base-commit: 24d479d26b25bce5faea3ddd9fa8f3a6c3129ea7
change-id: 20260121-pl353-soft-ecc-support-794e1e75373a

Best regards,
-- 
Andrea Scian <andrea.scian@dave.eu>
Re: [PATCH v3 0/2] PL353 SW ECC fixes
Posted by Miquel Raynal 1 day, 11 hours ago
On Wed, 04 Feb 2026 18:41:43 +0100, Andrea Scian wrote:
> PL353 has some known errata with its ECC implementation and it may be
> useful to switch to software ECC, to avoid issue with this.
> 
> On-die ECC is already supported (while I didn't test it) but when
> enabling SW ECC we get operation-not-supported error during page write
> (page read already work correctly)
> 
> [...]

Applied to nand/next, thanks!

[1/2] mtd: rawnand: pl353: Fix software ECC support
      commit: 89b831ebdaca0df4ca3b226f7e7a1d1db1629060
[2/2] mtd: rawnand: pl353: Add message about ECC mode
      commit: 1e06dbfdfb851170b243d6498e442b449324c664

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