diff options
author | Yangtao Li <frank.li@vivo.com> | 2022-12-21 02:39:04 +0800 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2023-01-11 11:15:19 -0800 |
commit | c40e15a9a59f79e79d9500f1fd019321ec35b959 (patch) | |
tree | 89dc3711f16003ff6e0724ed84cec867d0424d5d /fs/f2fs/node.c | |
parent | 1cd7565449de6e838ff5a3fa75fbd2ce58c6d955 (diff) | |
download | linux-c40e15a9a59f79e79d9500f1fd019321ec35b959.tar.gz linux-c40e15a9a59f79e79d9500f1fd019321ec35b959.tar.bz2 linux-c40e15a9a59f79e79d9500f1fd019321ec35b959.zip |
f2fs: merge f2fs_show_injection_info() into time_to_inject()
There is no need to additionally use f2fs_show_injection_info()
to output information. Concatenate time_to_inject() and
__time_to_inject() via a macro. In the new __time_to_inject()
function, pass in the caller function name and parent function.
In this way, we no longer need the f2fs_show_injection_info() function,
and let's remove it.
Suggested-by: Chao Yu <chao@kernel.org>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/node.c')
-rw-r--r-- | fs/f2fs/node.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/fs/f2fs/node.c b/fs/f2fs/node.c index 558b318f7316..fbd1d25fecc2 100644 --- a/fs/f2fs/node.c +++ b/fs/f2fs/node.c @@ -2541,10 +2541,8 @@ bool f2fs_alloc_nid(struct f2fs_sb_info *sbi, nid_t *nid) struct f2fs_nm_info *nm_i = NM_I(sbi); struct free_nid *i = NULL; retry: - if (time_to_inject(sbi, FAULT_ALLOC_NID)) { - f2fs_show_injection_info(sbi, FAULT_ALLOC_NID); + if (time_to_inject(sbi, FAULT_ALLOC_NID)) return false; - } spin_lock(&nm_i->nid_list_lock); |