diff options
author | Chao Yu <yuchao0@huawei.com> | 2017-07-18 19:19:05 +0300 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2017-08-01 02:48:29 +0300 |
commit | f247037120ecd3dcbbc196b51ded8b57edf4904f (patch) | |
tree | 9c255f95da7eadb42d67a0c0e7563e5d8916dbb0 /fs/f2fs/super.c | |
parent | e65ef20781cbfcbfe2d62ce37e028964bc34b313 (diff) | |
download | linux-f247037120ecd3dcbbc196b51ded8b57edf4904f.tar.xz |
f2fs: make max inline size changeable
This patch tries to make below macros calculating max inline size,
inline dentry field size considerring reserving size-changeable
space:
- MAX_INLINE_DATA
- NR_INLINE_DENTRY
- INLINE_DENTRY_BITMAP_SIZE
- INLINE_RESERVED_SIZE
Then, when inline_{data,dentry} options is enabled, it allows us to
reserve inline space with different size flexibly for adding newly
introduced inode attribute.
Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/super.c')
-rw-r--r-- | fs/f2fs/super.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index 32e4c025e97e..2d236384f938 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -446,6 +446,9 @@ static struct inode *f2fs_alloc_inode(struct super_block *sb) #endif /* Will be used by directory only */ fi->i_dir_level = F2FS_SB(sb)->dir_level; + + fi->i_inline_reserved = DEF_INLINE_RESERVED_SIZE; + return &fi->vfs_inode; } |