Is there possible to integrate mtd ubi ubifs latest version in one git tree?

Jamie Lokier jamie at shareable.org
Tue Apr 15 11:21:04 EDT 2008


Artem Bityutskiy wrote:
> On Tue, 2008-04-15 at 12:41 +0100, Jamie Lokier wrote:
> > If erase counters are stored at the start of each block, for the block
> > itself, what happens in this sequence?
> > 
> >     1. Begin erase block.
> >     2. Erase succeeds.
> >     3. Power failure / system reset / watchdog / etc.
> >     4. ....?
> > 
> > Is the erase counter zeroed as a result of this?
> 
> It tries to minimize probability of situations like this by writing the
> EC right after the erasure. But this still can happen of course. In this
> case UBI uses the average erase-counter (calculated while scanning is
> done) and writes it to this eraseblock.

Oh, using the averase erase-counter is smart, I like that. :-)

Erase can be quite slow on some kinds of flash, and the race window is
the whole erase time.  And during some activities, many sequential
erases are done.

It would be good if the erase-counters (and indeed metadata needed for
fast mounting) were also records in the log/trees held in other
blocks, but I guess you'd need to closely couple with the filesystems
logging.  And that would be a layer violation, tricky and ugly in the
UBI API.

-- Jamie



More information about the linux-mtd mailing list