zephyr/subsys/fs/zms
Riadh Ghaddab 2eba2e9c9c zms: add more robustiness in extreme cases
When power cuts during a GC operation, the sector is erased again in the
next reboot cycle and the cycle_cnt of the empty ATE is incremented.
If the same power cut happens 255 times in a row, the empty ATE cycle_cnt
will become equal to the close ATE which causes a memory corruption.
Fix this by checking the close ATE cycle_cnt before incrementing the
empty ATE cycle_cnt.

Fixes: #84874
Signed-off-by: Riadh Ghaddab <rghaddab@baylibre.com>
2025-04-16 20:36:49 +02:00
..
CMakeLists.txt fs: zms: multiple style fixes from previous PR review 2025-02-21 11:29:50 +00:00
Kconfig fs: zms: fix Copyright notice 2025-03-04 12:17:02 +00:00
zms_priv.h fs: zms: fix Copyright notice 2025-03-04 12:17:02 +00:00
zms.c zms: add more robustiness in extreme cases 2025-04-16 20:36:49 +02:00