diff options
author | Chao Yu <yuchao0@huawei.com> | 2020-03-10 13:50:07 +0100 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2020-03-11 16:25:38 +0100 |
commit | 96f5b4fa567040360dc57fd39b8e1a85a3e0132a (patch) | |
tree | db70ec95a4a09cf0ef68ce1339fd97d6745883cb /fs/f2fs/f2fs.h | |
parent | f2fs: fix wrong check on F2FS_IOC_FSSETXATTR (diff) | |
download | linux-96f5b4fa567040360dc57fd39b8e1a85a3e0132a.tar.xz linux-96f5b4fa567040360dc57fd39b8e1a85a3e0132a.zip |
f2fs: fix to account compressed inode correctly
stat_inc_compr_inode() needs to check FI_COMPRESSED_FILE flag, so
in f2fs_disable_compressed_file(), we should call stat_dec_compr_inode()
before clearing FI_COMPRESSED_FILE flag.
Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/f2fs.h')
-rw-r--r-- | fs/f2fs/f2fs.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/f2fs/f2fs.h b/fs/f2fs/f2fs.h index 760a05f98ac7..23013d3b59ba 100644 --- a/fs/f2fs/f2fs.h +++ b/fs/f2fs/f2fs.h @@ -3824,8 +3824,8 @@ static inline u64 f2fs_disable_compressed_file(struct inode *inode) return fi->i_compr_blocks; fi->i_flags &= ~F2FS_COMPR_FL; - clear_inode_flag(inode, FI_COMPRESSED_FILE); stat_dec_compr_inode(inode); + clear_inode_flag(inode, FI_COMPRESSED_FILE); return 0; } |