JFFS2 an nodes checking

Artem B. Bityuckiy abityuckiy at yandex.ru
Tue Sep 28 09:37:23 EDT 2004


David Woodhouse wrote:
> On Tue, 2004-09-28 at 17:17 +0400, Artem B. Bityuckiy wrote:
> 
>>Ok. But what if we check only last node (with the highest version) and 
>>if it is OK, don't check anything more? If it is bad, check previous, 
>>and so on. It seems for me, these checks are enough. We cover the 
>>situation with unexpected power losses.
> 
> 
> There's no reason to presume that the only node with broken CRC will be
> the _latest_ node, especially on NAND flash.
> 
If this isn't last node, the reason is media errors. And it isn't JFFS2 
deal to restore data. Moreover, this isn't guarantied in the current 
implementation - the previous node(s) may have been already Garbage 
Collected.

Another possibility is to teach the GC not to delete obsolete nodes for 
not yet checked inodes. And the fall-back procedure must be done if the 
bad node is read after the file was opened but its data wasn't checked 
(iput() and iget() again).

Comments?

-- 
Best Regards,
Artem B. Bityuckiy,
St.-Petersburg, Russia.




More information about the linux-mtd mailing list