[<prev] [next>] [day] [month] [year] [list]
Message-ID: <5182D186.7060306@gmail.com>
Date: Thu, 02 May 2013 15:50:14 -0500
From: Chris Fries <ccfries@...il.com>
To: jason.hrycay@...orola.com, c.fries@...orola.com,
jaegeuk.kim@...sung.com, linux-f2fs-devel@...ts.sourceforge.net,
linux-kernel@...r.kernel.org
Subject: [PATCH 2/2] f2fs: Recover when journal contains deleted files
From: Chris Fries <C.Fries@...orola.com>
When recovering a journal file with fsync data for files that have
been deleted, don't bail out on recovery.
Signed-off-by: Chris Fries <C.Fries@...orola.com>
Reviewed-by: Russell Knize <rknize2@...orola.com>
Reviewed-by: Jason Hrycay <jason.hrycay@...orola.com>
---
fs/f2fs/recovery.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/fs/f2fs/recovery.c b/fs/f2fs/recovery.c
index f16d12d..c3a7ab0 100644
--- a/fs/f2fs/recovery.c
+++ b/fs/f2fs/recovery.c
@@ -53,7 +53,7 @@ static int recover_dentry(struct page *ipage, struct
inode *inode)
dir = f2fs_iget(inode->i_sb, le32_to_cpu(raw_inode->i_pino));
if (IS_ERR(dir)) {
- err = -EINVAL;
+ err = PTR_ERR(dir);
goto out;
}
@@ -157,7 +157,12 @@ static int find_fsync_dnodes(struct f2fs_sb_info
*sbi, struct list_head *head)
if (IS_INODE(page)) {
err = recover_inode(entry->inode, page);
if (err)
- goto unlock_out;
+ if (err == -ENOENT)
+ goto next;
+ else {
+ err = -EINVAL;
+ goto unlock_out;
+ }
}
next:
/* check next segment */
--
1.8.0
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists