f2fs: fix to account inline xattr correctly during recovery
During recovery, we may missed to update inline xattr count correctly, fix it. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
parent
8492156153
commit
96dd025195
@ -2594,9 +2594,15 @@ int f2fs_recover_inline_xattr(struct inode *inode, struct page *page)
|
||||
|
||||
ri = F2FS_INODE(page);
|
||||
if (ri->i_inline & F2FS_INLINE_XATTR) {
|
||||
set_inode_flag(inode, FI_INLINE_XATTR);
|
||||
if (!f2fs_has_inline_xattr(inode)) {
|
||||
set_inode_flag(inode, FI_INLINE_XATTR);
|
||||
stat_inc_inline_xattr(inode);
|
||||
}
|
||||
} else {
|
||||
clear_inode_flag(inode, FI_INLINE_XATTR);
|
||||
if (f2fs_has_inline_xattr(inode)) {
|
||||
stat_dec_inline_xattr(inode);
|
||||
clear_inode_flag(inode, FI_INLINE_XATTR);
|
||||
}
|
||||
goto update_inode;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user