Message ID | 20160923211105.20848-1-jaegeuk@kernel.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On 2016/9/24 5:11, Jaegeuk Kim wrote: > When getting EIO while handling orphan inodes, we can get some dirty node > pages. Then, f2fs_write_node_pages() called by iput(node_inode) will try > to flush node pages. But in this case, we should prevent to do that, since > we will try again from the start. We are protected since we set SBI_POR_DOING flag in sb, so we are safe now? Thanks, -- 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
On Sat, Sep 24, 2016 at 09:02:02AM +0800, Chao Yu wrote: > On 2016/9/24 5:11, Jaegeuk Kim wrote: > > When getting EIO while handling orphan inodes, we can get some dirty node > > pages. Then, f2fs_write_node_pages() called by iput(node_inode) will try > > to flush node pages. But in this case, we should prevent to do that, since > > we will try again from the start. > > We are protected since we set SBI_POR_DOING flag in sb, so we are safe now? Safe, but we get an infinite loop to flush node pages. > > Thanks, -- 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
On 2016/9/25 1:47, Jaegeuk Kim wrote: > On Sat, Sep 24, 2016 at 09:02:02AM +0800, Chao Yu wrote: >> On 2016/9/24 5:11, Jaegeuk Kim wrote: >>> When getting EIO while handling orphan inodes, we can get some dirty node >>> pages. Then, f2fs_write_node_pages() called by iput(node_inode) will try >>> to flush node pages. But in this case, we should prevent to do that, since >>> we will try again from the start. >> >> We are protected since we set SBI_POR_DOING flag in sb, so we are safe now? > > Safe, but we get an infinite loop to flush node pages. Got it. Thanks, > >> >> Thanks, > > . > -- 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 --git a/fs/f2fs/super.c b/fs/f2fs/super.c index e7bb153..fbded38 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -1892,6 +1892,7 @@ free_root_inode: dput(sb->s_root); sb->s_root = NULL; free_node_inode: + truncate_inode_pages_final(NODE_MAPPING(sbi)); mutex_lock(&sbi->umount_mutex); release_ino_entry(sbi, true); f2fs_leave_shrinker(sbi);
When getting EIO while handling orphan inodes, we can get some dirty node pages. Then, f2fs_write_node_pages() called by iput(node_inode) will try to flush node pages. But in this case, we should prevent to do that, since we will try again from the start. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> --- fs/f2fs/super.c | 1 + 1 file changed, 1 insertion(+)