io_u: fix exit failure case when using rates and timeout
authorsribs <sriharsha.bs@outlook.com>
Fri, 24 Jul 2020 10:06:58 +0000 (15:36 +0530)
committersribs <sriharsha.bs@outlook.com>
Fri, 24 Jul 2020 16:49:55 +0000 (22:19 +0530)
commitdf06a03616661423baa39b68a8679c7f7baa99ed
treea78e6f629006475b0bbda2996922e514b48902fd
parent5090d1d0f2a109c276384c93308566b7a3bfa5ad
io_u: fix exit failure case when using rates and timeout

Previously when using a rate smaller than the minimum block size,
fio could end up failing to exit at a designated timeout and
while doing this, do check if usec takes in negative values which could
potentially not exit fio indefinitely.

Fixes: https://github.com/axboe/fio/issues/1039

Signed-off-by: Sriharsha B S <sribs@microsoft.com>
io_u.c