[MTD] mtdoops: Fix a bug where block may not be erased
Linux-MTD Mailing List
linux-mtd at lists.infradead.org
Sat Oct 18 07:59:02 EDT 2008
Gitweb: http://git.infradead.org/?p=mtd-2.6.git;a=commit;h=43b5693d404127697d62962def8c1bfe3a89811a
Commit: 43b5693d404127697d62962def8c1bfe3a89811a
Parent: f0482ee3669a78bdb1e15b9f9c58a9f1ffc5a997
Author: Richard Purdie <rpurdie at rpsys.net>
AuthorDate: Sat Jul 26 09:25:18 2008 +0100
Committer: David Woodhouse <David.Woodhouse at intel.com>
CommitDate: Sat Oct 18 11:51:48 2008 +0100
[MTD] mtdoops: Fix a bug where block may not be erased
This makes the driver erase a block when it doesn't find any
existing saved log messages which is safer than assuming the
flash was already erased.
Signed-off-by: Richard Purdie <rpurdie at rpsys.net>
Signed-off-by: David Woodhouse <David.Woodhouse at intel.com>
---
drivers/mtd/mtdoops.c | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/drivers/mtd/mtdoops.c b/drivers/mtd/mtdoops.c
index 6f6b2f3..aebb3b2 100644
--- a/drivers/mtd/mtdoops.c
+++ b/drivers/mtd/mtdoops.c
@@ -258,9 +258,7 @@ static void find_next_position(struct mtdoops_context *cxt)
if (maxcount == 0xffffffff) {
cxt->nextpage = 0;
cxt->nextcount = 1;
- cxt->ready = 1;
- printk(KERN_DEBUG "mtdoops: Ready %d, %d (first init)\n",
- cxt->nextpage, cxt->nextcount);
+ schedule_work(&cxt->work_erase);
return;
}
More information about the linux-mtd-cvs
mailing list