Table of contents not updating
An UBI volume is a set of consecutive logical eraseblocks (LEBs).Each logical eraseblock may be mapped to any physical eraseblock (PEB).
This means that PEBs always have the EC header, except for the short period of time after the erasure and before the EC header is written.
Should an unclean reboot happen during this short period of time, the EC header is lost or becomes corrupted.
In this case UBI writes new EC header with an average erase counter just after the MTD device scanning is done.
Static volumes are read-only and their contents are protected by checksums, while dynamic volumes are read-write and the upper layers (e.g., a file-system) are responsible for ensuring data integrity.
UBI is aware of bad eraseblocks (e.g., NAND flash may have them) and frees the upper layers from any bad block handling.