commit | 7e77dd026d85253936aef432ba8f3e89b96b805c | [log] [tgz] |
---|---|---|
author | Jens Axboe <jens.axboe@oracle.com> | Tue Feb 20 10:57:34 2007 +0100 |
committer | Jens Axboe <jens.axboe@oracle.com> | Tue Feb 20 10:57:34 2007 +0100 |
tree | 0b90d5b4ca2b1e01d64bbd9789d4f81733d292d7 | |
parent | 00de55ef85f01f3c56fac5397aca92eef0c73762 [diff] [blame] |
Improve submission latency calculation Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
diff --git a/io_u.c b/io_u.c index ab46cbe..6234c42 100644 --- a/io_u.c +++ b/io_u.c
@@ -555,3 +555,14 @@ return -1; } + +/* + * Call when io_u is really queued, to update the submission latency. + */ +void io_u_queued(struct thread_data *td, struct io_u *io_u) +{ + unsigned long slat_time; + + slat_time = mtime_since(&io_u->start_time, &io_u->issue_time); + add_slat_sample(td, io_u->ddir, slat_time); +}