Really fix IOPS logging
authorJens Axboe <axboe@kernel.dk>
Tue, 28 Feb 2012 07:20:26 +0000 (08:20 +0100)
committerJens Axboe <axboe@kernel.dk>
Tue, 28 Feb 2012 07:23:18 +0000 (08:23 +0100)
Commit 9602d8df had a bug where it mistakenly stored
the bytes last seen when doing an IOPS log entry, instead
of the blocks last seen.

Reported-by: Bill Hooper <whooper@micron.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
stat.c

diff --git a/stat.c b/stat.c
index a02c5829a494cf330a9394e731c0802b83b8b567..fa9af7c7c400ff8825cba27e1c0967efaa147e11 100644 (file)
--- a/stat.c
+++ b/stat.c
@@ -1343,7 +1343,7 @@ void add_iops_sample(struct thread_data *td, enum fio_ddir ddir,
                if (td->iops_log)
                        add_log_sample(td, td->iops_log, iops, ddir, 0);
 
-               td->stat_io_bytes[ddir] = td->this_io_bytes[ddir];
+               td->stat_io_blocks[ddir] = td->this_io_blocks[ddir];
        }
 
        fio_gettime(&td->iops_sample_time, NULL);