]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
Merge branch 'linux-next' of git://git.infradead.org/~dedekind/ubi-2.6
authorLinus Torvalds <torvalds@linux-foundation.org>
Sun, 30 Nov 2008 19:34:17 +0000 (11:34 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sun, 30 Nov 2008 19:34:17 +0000 (11:34 -0800)
* 'linux-next' of git://git.infradead.org/~dedekind/ubi-2.6:
  UBI: Don't exit from ubi_thread until kthread_should_stop() is true
  UBI: fix EBADMSG handling

drivers/mtd/ubi/eba.c
drivers/mtd/ubi/scan.c
drivers/mtd/ubi/wl.c

index e04bcf1dff87c1b2dfdd75ef2428a0bb76781ef7..d8966bae0e0b85ea2810dd094828ddedf1e7cf6a 100644 (file)
@@ -1022,7 +1022,7 @@ int ubi_eba_copy_leb(struct ubi_device *ubi, int from, int to,
        }
 
        /*
-        * OK, now the LEB is locked and we can safely start moving iy. Since
+        * OK, now the LEB is locked and we can safely start moving it. Since
         * this function utilizes thie @ubi->peb1_buf buffer which is shared
         * with some other functions, so lock the buffer by taking the
         * @ubi->buf_mutex.
index 4f2daa5bbecfbafe646da17a586cacd3328b5d07..41d47e1cf15c23f8c36423ae3caa4a0e2091e245 100644 (file)
@@ -320,7 +320,7 @@ static int compare_lebs(struct ubi_device *ubi, const struct ubi_scan_leb *seb,
        }
 
        err = ubi_io_read_data(ubi, buf, pnum, 0, len);
-       if (err && err != UBI_IO_BITFLIPS)
+       if (err && err != UBI_IO_BITFLIPS && err != -EBADMSG)
                goto out_free_buf;
 
        data_crc = be32_to_cpu(vid_hdr->data_crc);
index 05d70937b54322d8ecd878d05cc69e084ef4a5ed..dcb6dac1dc5446b4966d85ef8e6d8e1db5ed9dcb 100644 (file)
@@ -1396,7 +1396,8 @@ int ubi_thread(void *u)
                                ubi_msg("%s: %d consecutive failures",
                                        ubi->bgt_name, WL_MAX_FAILURES);
                                ubi_ro_mode(ubi);
-                               break;
+                               ubi->thread_enabled = 0;
+                               continue;
                        }
                } else
                        failures = 0;