verify: always check completion list for low depth verifies
authorJens Axboe <axboe@fb.com>
Fri, 16 Jan 2015 17:25:05 +0000 (10:25 -0700)
committerJens Axboe <axboe@fb.com>
Fri, 16 Jan 2015 17:25:05 +0000 (10:25 -0700)
If we have done less IO than the depth, we need to check the
pending list.

Signed-off-by: Jens Axboe <axboe@fb.com>
verify.c

index 205f01a2fc304d8a1f401d2e2e9eee19a8c37294..260fa2ae2fad1f298b7ddad8cb421019708a09d1 100644 (file)
--- a/verify.c
+++ b/verify.c
@@ -1540,10 +1540,12 @@ int verify_state_should_stop(struct thread_data *td, struct io_u *io_u)
                return 0;
 
        /*
-        * If we're not into the window of issues - depth yet, continue
+        * If we're not into the window of issues - depth yet, continue. If
+        * issue is shorter than depth, do check.
         */
-       if (td->io_blocks[DDIR_READ] < s->depth ||
-           s->numberio - td->io_blocks[DDIR_READ] > s->depth)
+       if ((td->io_blocks[DDIR_READ] < s->depth ||
+           s->numberio - td->io_blocks[DDIR_READ] > s->depth) &&
+           s->numberio > s->depth)
                return 0;
 
        /*