diff mbox

[2/2] f2fs: avoid wrong error during recovery

Message ID 1424900845-54141-2-git-send-email-jaegeuk@kernel.org (mailing list archive)
State New, archived
Headers show

Commit Message

Jaegeuk Kim Feb. 25, 2015, 9:47 p.m. UTC
From: Jaegeuk Kim <jaegeuk@motorola.com>

During the roll-forward recovery, -ENOENT for f2fs_iget can be skipped.
So, this error value should not be propagated.

Change-Id: I230ad2371e3fb4b9df42059c4a61f92c1f9838de
Signed-off-by: Jaegeuk Kim <jaegeuk@motorola.com>
---
 fs/f2fs/recovery.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

?? Feb. 26, 2015, 1:15 a.m. UTC | #1
> -----Original Message-----
> From: Jaegeuk Kim [mailto:jaegeuk@kernel.org]
> Sent: Thursday, February 26, 2015 5:47 AM
> To: linux-kernel@vger.kernel.org; linux-fsdevel@vger.kernel.org;
> linux-f2fs-devel@lists.sourceforge.net
> Cc: Jaegeuk Kim
> Subject: [f2fs-dev] [PATCH 2/2] f2fs: avoid wrong error during recovery
> 
> From: Jaegeuk Kim <jaegeuk@motorola.com>
> 
> During the roll-forward recovery, -ENOENT for f2fs_iget can be skipped.
> So, this error value should not be propagated.
> 
> Change-Id: I230ad2371e3fb4b9df42059c4a61f92c1f9838de
> Signed-off-by: Jaegeuk Kim <jaegeuk@motorola.com>

Reviewed-by: Chao Yu <chao2.yu@samsung.com>

--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/fs/f2fs/recovery.c b/fs/f2fs/recovery.c
index b2a92d4..6e40874 100644
--- a/fs/f2fs/recovery.c
+++ b/fs/f2fs/recovery.c
@@ -212,8 +212,10 @@  static int find_fsync_dnodes(struct f2fs_sb_info *sbi, struct list_head *head)
 			if (IS_ERR(entry->inode)) {
 				err = PTR_ERR(entry->inode);
 				kmem_cache_free(fsync_entry_slab, entry);
-				if (err == -ENOENT)
+				if (err == -ENOENT) {
+					err = 0;
 					goto next;
+				}
 				break;
 			}
 			list_add_tail(&entry->list, head);