[Openpxa-users] PXA310: double bit errors on NAND

Ricard Wanderlof ricard.wanderlof at axis.com
Sun Jan 16 16:53:28 EST 2011


On Sat, 15 Jan 2011, Bjørn Forsman wrote:

> I'd like to know how UBI images is supposed to be flashed.
> By searching the internet I've seen people saying that it is
> impossible to write UBI images with nandwrite and others say
> it *is* possible. By looking at
> http://www.linux-mtd.infradead.org/doc/ubi.html#L_flasher_algo
> it may appear that flashing UBI images requires an UBI aware flasher?
> But isn't the whole point of having ubinize so that you can take UBIFS
> images and wrap them into something that non UBIFS aware flashers can handle?

I think there are two separate issues here:

1. When reflashing a flash with a new image you'll want to preserve the 
UBI erase counters, hence a UBI-aware flasher (e.g. ubiformat) is 
required. You can use nandwrite, but then the erase counter information is 
lost.

2. When flashing a virgin flash there are no erase counters to be 
preserved, so nandwrite will suffice. However, there appears to be an old 
'bug' in nandwrite whereby all-ff pages in the source image are 
nevertheless written to the flash. All-ff pages are assumed erased by UBI, 
and so are never re-erased before subsequent usage. The problem is that 
some flash chips do not take lightly to being rewritten multiple times 
without an intermediate erase. So it's really an old bug in nandwrite, but 
it might not have manifested itself until heavy testing with UBI had been 
performed. There's more information on this in the FAQ I believe.

/Ricard
-- 
Ricard Wolf Wanderlöf                           ricardw(at)axis.com
Axis Communications AB, Lund, Sweden            www.axis.com
Phone +46 46 272 2016                           Fax +46 46 13 61 30



More information about the linux-mtd mailing list