From: Jens Axboe Date: Wed, 14 May 2008 19:09:03 +0000 (+0200) Subject: Merge branch 'master' of ssh://git.kernel.dk/data/git/fio X-Git-Tag: fio-1.21-rc1~20 X-Git-Url: https://git.kernel.dk/?p=fio.git;a=commitdiff_plain;h=391ba6ac169ad7deaf3bb3840046581f45d755e1;hp=748b23a36509240af1debf5f7f3ca8ef153548ea Merge branch 'master' of ssh://git.kernel.dk/data/git/fio --- diff --git a/fio.h b/fio.h index 6f2c4c09..f201b33b 100644 --- a/fio.h +++ b/fio.h @@ -906,7 +906,7 @@ extern void io_u_queued(struct thread_data *, struct io_u *); extern void io_u_log_error(struct thread_data *, struct io_u *); extern void io_u_init_timeout(void); extern void io_u_set_timeout(struct thread_data *); -extern void io_u_mark_depth(struct thread_data *, struct io_u *); +extern void io_u_mark_depth(struct thread_data *, struct io_u *, unsigned int); /* * io engine entry points diff --git a/io_u.c b/io_u.c index 985c99b2..0ba48416 100644 --- a/io_u.c +++ b/io_u.c @@ -410,7 +410,8 @@ out: return 0; } -void io_u_mark_depth(struct thread_data *td, struct io_u *io_u) +void io_u_mark_depth(struct thread_data *td, struct io_u *io_u, + unsigned int nr) { int index = 0; @@ -439,8 +440,8 @@ void io_u_mark_depth(struct thread_data *td, struct io_u *io_u) break; } - td->ts.io_u_map[index]++; - td->ts.total_io_u[io_u->ddir]++; + td->ts.io_u_map[index] += nr; + td->ts.total_io_u[io_u->ddir] += nr; } static void io_u_mark_lat_usec(struct thread_data *td, unsigned long usec) diff --git a/ioengines.c b/ioengines.c index e44fce08..984c01ac 100644 --- a/ioengines.c +++ b/ioengines.c @@ -238,7 +238,7 @@ int td_io_queue(struct thread_data *td, struct io_u *io_u) unlock_file(td, io_u->file); if (ret != FIO_Q_BUSY) - io_u_mark_depth(td, io_u); + io_u_mark_depth(td, io_u, 1); if (ret == FIO_Q_QUEUED) { int r;