]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
f2fs: fix timeout precision of f2fs_io_schedule_timeout_killable()
authorChao Yu <chao@kernel.org>
Sun, 4 Jan 2026 02:07:26 +0000 (10:07 +0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Wed, 7 Jan 2026 03:17:07 +0000 (03:17 +0000)
commit6fa116053951d5785ef1a0b060858843e663a31a
tree57d968ccafd0e8b19800cce7a883748f28506e23
parentda90b6715567e900a3c5d112dfaf8f385b343edc
f2fs: fix timeout precision of f2fs_io_schedule_timeout_killable()

Sometimes, f2fs_io_schedule_timeout_killable(HZ) may delay for about 2
seconds, this is because __f2fs_schedule_timeout(DEFAULT_SCHEDULE_TIMEOUT)
may delay for about 2 * DEFAULT_SCHEDULE_TIMEOUT due to its precision, but
we only account the delay as DEFAULT_SCHEDULE_TIMEOUT as below, fix it.

f2fs_io_schedule_timeout_killable()
..
timeout -= DEFAULT_SCHEDULE_TIMEOUT;

Signed-off-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/f2fs.h