[PATCH] Newly erased page read workaround

Ricard Wanderlof ricard.wanderlof at axis.com
Fri Apr 1 10:58:47 EDT 2011


On Fri, 1 Apr 2011, Ivan Djelic wrote:

>> I'm curious, if the OOB area is so unreliable, how can we trust it to
>> store our ECC? We need a mini-ECC for the ECC then?
>
> The oob area is no different from the data area (same technology).
> Fortunately, Hamming and BCH codes (and usual ECC codes in general) actually
> have built-in robustness to corruption.

At least with Hamming, when the ECC has been calculated, if it differs 
from the ECC read from the oob, and the difference is just a single bit, 
it is assumed that the ECC stored in the oob was subjected to a bitflip, 
and the data is in fact ok. (A long time ago there was a bug in this in 
mtd, so that a (single) bit flip in the ECC bytes was flagged as an ECC 
failure).

I don't know how BCH (and other multiple-error-bit algorithms) deals with 
this though. Does it assume that there will be at most one bitflip within 
the ECC data (which is much smaller than the bytes covered by the ECC), or 
does it accept multiple bit errors also in the ECC data? One would assume 
that it would start to get difficult to distinguish multiple bit errors in 
the ECC data with valid ECC indicating bit errors in the data, but perhaps 
this isn't so thanks to the algorithm used?

/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