mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
UBI: erase free PEB with bitflip in EC header
commit 193819cf2e
upstream.
Without this patch, these PEB are not scrubbed until we put data in them.
Bitflip can accumulate latter and we can loose the EC header (but VID header
should be intact and allow to recover data).
Signed-off-by: Matthieu Castet <matthieu.castet@parrot.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
[bwh: Backported to 3.2: adjust filename, context]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Cc: Qiang Huang <h.huangqiang@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
70e8fcb681
commit
b2d9953713
1 changed files with 1 additions and 1 deletions
|
@ -997,7 +997,7 @@ static int process_eb(struct ubi_device *ubi, struct ubi_scan_info *si,
|
|||
return err;
|
||||
goto adjust_mean_ec;
|
||||
case UBI_IO_FF:
|
||||
if (ec_err)
|
||||
if (ec_err || bitflips)
|
||||
err = add_to_list(si, pnum, ec, 1, &si->erase);
|
||||
else
|
||||
err = add_to_list(si, pnum, ec, 0, &si->free);
|
||||
|
|
Loading…
Reference in a new issue