f2fs: don't worry about inode leak in evict_inode
Even if an inode failed to release its blocks, it should be kept in an orphan inode list, so it will be released later. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
Родитель
f51b4ce6c1
Коммит
29234b1d6d
|
@ -377,20 +377,8 @@ no_delete:
|
||||||
alloc_nid_failed(sbi, inode->i_ino);
|
alloc_nid_failed(sbi, inode->i_ino);
|
||||||
clear_inode_flag(fi, FI_FREE_NID);
|
clear_inode_flag(fi, FI_FREE_NID);
|
||||||
}
|
}
|
||||||
|
f2fs_bug_on(sbi, err &&
|
||||||
if (err && err != -ENOENT) {
|
!exist_written_data(sbi, inode->i_ino, ORPHAN_INO));
|
||||||
if (!exist_written_data(sbi, inode->i_ino, ORPHAN_INO)) {
|
|
||||||
/*
|
|
||||||
* get here because we failed to release resource
|
|
||||||
* of inode previously, reminder our user to run fsck
|
|
||||||
* for fixing.
|
|
||||||
*/
|
|
||||||
set_sbi_flag(sbi, SBI_NEED_FSCK);
|
|
||||||
f2fs_msg(sbi->sb, KERN_WARNING,
|
|
||||||
"inode (ino:%lu) resource leak, run fsck "
|
|
||||||
"to fix this issue!", inode->i_ino);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
out_clear:
|
out_clear:
|
||||||
fscrypt_put_encryption_info(inode, NULL);
|
fscrypt_put_encryption_info(inode, NULL);
|
||||||
clear_inode(inode);
|
clear_inode(inode);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче