diff options
author | Chao Yu <yuchao0@huawei.com> | 2020-02-25 18:17:10 +0800 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2020-03-22 21:16:27 -0700 |
commit | a999150f4fe3abbb7efd05411fd5b460be699943 (patch) | |
tree | 08afcb75aaf48ab33888a594827aa68883789964 /fs/f2fs/f2fs.h | |
parent | dabfbbc8f914504670a7fbeaf933aa253cbb8acc (diff) | |
download | lwn-a999150f4fe3abbb7efd05411fd5b460be699943.tar.gz lwn-a999150f4fe3abbb7efd05411fd5b460be699943.zip |
f2fs: use kmem_cache pool during inline xattr lookups
It's been observed that kzalloc() on lookup_all_xattrs() are called millions
of times on Android, quickly becoming the top abuser of slub memory allocator.
Use a dedicated kmem cache pool for xattr lookups to mitigate this.
Signed-off-by: Park Ju Hyung <qkrwngud825@gmail.com>
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 | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/f2fs/f2fs.h b/fs/f2fs/f2fs.h index baaf7f0fd02a..3e727a6af08e 100644 --- a/fs/f2fs/f2fs.h +++ b/fs/f2fs/f2fs.h @@ -1487,6 +1487,9 @@ struct f2fs_sb_info { __u32 s_chksum_seed; struct workqueue_struct *post_read_wq; /* post read workqueue */ + + struct kmem_cache *inline_xattr_slab; /* inline xattr entry */ + unsigned int inline_xattr_slab_size; /* default inline xattr slab size */ }; struct f2fs_private_dio { |