summaryrefslogtreecommitdiff
path: root/fs/f2fs/xattr.h
diff options
context:
space:
mode:
authorChao Yu <yuchao0@huawei.com>2020-02-14 17:44:11 +0800
committerJaegeuk Kim <jaegeuk@kernel.org>2020-03-19 11:41:25 -0700
commitba3b583cff454f486683701f02a0b7a0dcbed04d (patch)
tree515e0c28843474310af515763395e7e06b8df344 /fs/f2fs/xattr.h
parenta2ced1ce1087a19361b7845c85a2d910fc591344 (diff)
f2fs: clean up parameter of macro XATTR_SIZE()
Just cleanup, no logic change. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/xattr.h')
-rw-r--r--fs/f2fs/xattr.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/f2fs/xattr.h b/fs/f2fs/xattr.h
index de0c600b9cab..574beea46494 100644
--- a/fs/f2fs/xattr.h
+++ b/fs/f2fs/xattr.h
@@ -73,7 +73,8 @@ struct f2fs_xattr_entry {
entry = XATTR_NEXT_ENTRY(entry))
#define VALID_XATTR_BLOCK_SIZE (PAGE_SIZE - sizeof(struct node_footer))
#define XATTR_PADDING_SIZE (sizeof(__u32))
-#define XATTR_SIZE(x,i) (((x) ? VALID_XATTR_BLOCK_SIZE : 0) + \
+#define XATTR_SIZE(i) ((F2FS_I(i)->i_xattr_nid ? \
+ VALID_XATTR_BLOCK_SIZE : 0) + \
(inline_xattr_size(i)))
#define MIN_OFFSET(i) XATTR_ALIGN(inline_xattr_size(i) + \
VALID_XATTR_BLOCK_SIZE)