What if the UBI flasher can't skip all-FF pages?

J Barlow jbarlow at ivl.com
Mon Jan 10 17:47:05 EST 2011


Hi everyone,

I am developing an embedded system with a NAND flash.  We're intending to 
program all of the NAND flashes in a factory programmer.  I've read "how the UBI 
flash should work" and I suspect that the UBI flasher doesn't work that way.  
Specifically, I'm pretty sure it doesn't know how to skip pages containing only 
FFs.  Unfortunately, the flasher's software is proprietary, not to mention only 
available in Chinese.  It might well work as expected, but testing this would 
also be difficult and expensive since the flasher is in a factory in China. 

I believe that UBIFS is doing the right thing.  I blame the flasher, but I don't 
think I can do anything about it.

I'd prefer to use UBIFS as a writable root file system, if possible.  But maybe 
this won't work in my situation.

Is there any reasonable way to let UBIFS know all pages have been programmed 
initially?  For example, maybe I could deliberate replace all-FF pages with all-
00 pages in the flashed image.  Or will that just cause UBI/UBIFS to find 
corrupt empty space and fail?  Or perhaps someone could direct me how to make a 
patch that would help with UBIFS/UBI/ubinize with this specific situation.  It 
does seem like other people have run into problems with poorly written flashers 
problem, and in some cases like mine changing the flasher is not an option.

Also, if I use a read-only UBIFS in a dynamic UBI volume, will UBIFS ever 
attempt to double-program an all-FF page?  I would imagine if I used a read-only 
UBIFS in a static UBI volume I won't have trouble -- except that I also need to 
update the firmware.  Is it possible to ubiupdatevol a static UBI volume, or do 
I need something more aggressive to modify a static UBI volume?


Thanks.
J Barlow





More information about the linux-mtd mailing list