[PATCH] Total io is the sum of READ and WRITE
[fio.git] / fio.c
diff --git a/fio.c b/fio.c
index 2aeb6f72a5b196e3052876b27c24fd266db90cfe..ace8c5ee09aae9e4353d9879273eaadbe1c2848d 100644 (file)
--- a/fio.c
+++ b/fio.c
@@ -382,7 +382,7 @@ static void do_io(struct thread_data *td)
 
        td_set_runstate(td, TD_RUNNING);
 
-       while (td->this_io_bytes[td->ddir] < td->io_size) {
+       while ((td->this_io_bytes[0] + td->this_io_bytes[1]) < td->io_size) {
                struct timespec *timeout;
                int min_evts = 0;
                struct io_u *io_u;