What for does UBI need headers in physical eraseblocks?
The headers are needed to keep track of erase counters and physical-to-logical eraseblock associations. There are two UBI headers stored in each PEB: • erase counter header (or EC header) which is mostly needed to store the erase counter of the PEB; • volume identifier header (or VID header) which stores volume ID and LEB number this PEB belongs to. Note, there are also some other data stored in EC and VID headers, see ubi-media.h for more details.