Fix thread hang when using async engines (libaio,etc.) when too low of a iops rate...
authorRyan Marchand <rmarchan@amazon.com>
Tue, 31 Jan 2012 13:05:32 +0000 (14:05 +0100)
committerJens Axboe <axboe@kernel.dk>
Tue, 31 Jan 2012 13:05:32 +0000 (14:05 +0100)
commit422f9e4b57549ce1e163b9c1de71932d9ea24de4
treed39111f740d64922803c9381af02084cb15984a7
parented33585509a97c4a65e46967cb49419b6a4f8870
Fix thread hang when using async engines (libaio,etc.) when too low of a iops rate is specified.

Rate limiting logic was using thread_data->cur_depth to decide the
min_evts number to ask for during its "flush" prior to sleeping.
td->cur_depth, however, does not properly track in-flight IOs submitted
to the async engines.  Added field to thread_data structure and use
that, instead, to track IOs currently in flight.

Signed-off-by: Ryan Marchand <rmarchan@amazon.com>
Signed-off-by: Steven Noonan <snoonan@amazon.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fio.h
io_u.c
ioengines.c