UBI: bugfix - do not torture PEB needlessly
authorArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Fri, 18 Jul 2008 09:42:14 +0000 (12:42 +0300)
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Thu, 24 Jul 2008 10:34:46 +0000 (13:34 +0300)
This is probably a copy-paste bug - we torture the old PEB
in the atomic LEB change function, but we should not do this.

Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
drivers/mtd/ubi/eba.c

index 613cd1e..e142081 100644 (file)
@@ -906,7 +906,7 @@ retry:
        }
 
        if (vol->eba_tbl[lnum] >= 0) {
-               err = ubi_wl_put_peb(ubi, vol->eba_tbl[lnum], 1);
+               err = ubi_wl_put_peb(ubi, vol->eba_tbl[lnum], 0);
                if (err)
                        goto out_leb_unlock;
        }