diff options
| author | Chao Yu <yuchao0@huawei.com> | 2017-05-19 23:37:00 +0800 |
|---|---|---|
| committer | Moyster <oysterized@gmail.com> | 2017-07-21 12:37:26 +0200 |
| commit | de2b8fef72ca2f1048a298f8f6a8bb4e38008ca4 (patch) | |
| tree | 18947d64d96be1ea1aeeb73f2e4a665b6aad50b9 /fs/f2fs/super.c | |
| parent | 2e1f7424caf3fd8da6b0f9484867058a80463b52 (diff) | |
f2fs: split wio_mutex
Split wio_mutex to adjust different temperature bio cache.
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 | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index 13372b1ab..c9eb1590e 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -1574,7 +1574,7 @@ int sanity_check_ckpt(struct f2fs_sb_info *sbi) static void init_sb_info(struct f2fs_sb_info *sbi) { struct f2fs_super_block *raw_super = sbi->raw_super; - int i; + int i, j; sbi->log_sectors_per_block = le32_to_cpu(raw_super->log_sectors_per_block); @@ -1606,8 +1606,9 @@ static void init_sb_info(struct f2fs_sb_info *sbi) INIT_LIST_HEAD(&sbi->s_list); mutex_init(&sbi->umount_mutex); - mutex_init(&sbi->wio_mutex[NODE]); - mutex_init(&sbi->wio_mutex[DATA]); + for (i = 0; i < NR_PAGE_TYPE - 1; i++) + for (j = HOT; j < NR_TEMP_TYPE; j++) + mutex_init(&sbi->wio_mutex[i][j]); spin_lock_init(&sbi->cp_lock); } |
