[PATCH 0/2] Backport fixes for UBI
Dominique Martinet
dominique.martinet at atmark-techno.com
Wed Aug 19 17:57:27 PDT 2026
Richard Weinberger wrote on Wed, Aug 19, 2026 at 12:48:28PM +0200:
> While porting these back is not wrong, I have a hard time to see how the
> current stables rules apply here.
Thank you for looking into this!
I'm honestly fuzzy on stable backport "rules", but in practice I see all
sort of things get in (admitely sometimes new features/refactor just
because it makes an actual fix easier to backport, but also quite a few
leaks on failures like the second patch and other general improvements),
so after noticing someone else submitted 6.12 contiguous read
improvements recently[1] so I assumed such backports would be welcome...
But ultimately I think it's up to you, so happy to see the patches
dropped if you prefer.
[1] https://lore.kernel.org/r/20260811161342.533280-1-frieder@fris.de
> "mtd: ubi: skip programming unused bits in ubi headers" does not fix anything.
> It's a pure optimization for future flashes, UBI worked since ever without this
> change.
I might have misunderstood something about this patch, but while UBI
works fine I believe this would increase the longevity of more than just
"future flashes"
I've burned out 2 times 1MB (4 erase blocks) from the NAND I have on
hand (winbond W25N04LW) using either random data + erase (nandtest) or a
patched version writing zeroes + erase, and writing many zeroes failed
the erase blocks about 40-50% faster (85 thousands cycles vs 132
thousands until the first erase failure, 121/175 until erase stopped
working with many retries)
This obviously is a tiny sample size and not concrete proof, and this
patch won't have such a big impact because the area is small, but I
believe this patch will still improve the endurance a tiny bit for at
least our model, which was the motivation for me to pick this up.
Of course, there's also a chance that something breaks from it so I
can perfectly understand if you prefer not to backport it; you're in a
much better place than me to draw the line.
Thanks,
--
Dominique Martinet | Asmadeus
More information about the linux-mtd
mailing list