f2fs: introduce cur_cp_version function to reduce code size

This patch introduces a new inline function, cur_cp_version, to reduce redundant
codes.

Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
This commit is contained in:
Jaegeuk Kim
2013-08-09 15:03:21 +09:00
parent e518ff81c3
commit d71b5564c0
5 changed files with 13 additions and 9 deletions

View File

@@ -488,7 +488,7 @@ int f2fs_setxattr(struct inode *inode, int name_index, const char *name,
}
/* store checkpoint version for conducting checkpoint during fsync */
fi->xattr_ver = le64_to_cpu(F2FS_CKPT(sbi)->checkpoint_ver);
fi->xattr_ver = cur_cp_version(F2FS_CKPT(sbi));
if (ipage)
update_inode(inode, ipage);