backend: fix runtime when used with thinktime
authorAnkit Kumar <ankit.kumar@samsung.com>
Fri, 17 Feb 2023 07:03:22 +0000 (12:33 +0530)
committerJens Axboe <axboe@kernel.dk>
Sat, 18 Feb 2023 02:52:50 +0000 (19:52 -0700)
commitf9fc7a27cae5ea2dbb310c05f7b693c68ba15537
tree0f3b2273e3e25ee2f1837c6bfaa2d1d56b0db4ee
parentdf292e805f9762e4ef3479e1254b3c7328e19988
backend: fix runtime when used with thinktime

Runtime for fio jobs when used in conjuction with thinktime,
thinktime_iotime and thinktime_spin were sometimes more than
what is specified. Add a fix so that fio doesn't spin or sleep
for any duration beyond runtime.

For the first cycle fio starts by doing I/O for
thinktime + thinktime_iotime, which should just be for
thinktime_iotime. Add a fix for that.

Signed-off-by: Ankit Kumar <ankit.kumar@samsung.com>
Link: https://lore.kernel.org/r/20230217070322.14163-2-ankit.kumar@samsung.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
backend.c