X-Git-Url: https://git.kernel.dk/?p=fio.git;a=blobdiff_plain;f=io_u.c;h=16c98b1f454869c43e4862b91c57b1278898de28;hp=7709df5fe55bf7fb6237d6b93476b2f09a2d3d3d;hb=a66da7a2354aac16757c75a824ad7cbba678535c;hpb=e2979754b554d6a48cffa98f41fb59bc045922ac diff --git a/io_u.c b/io_u.c index 7709df5f..16c98b1f 100644 --- a/io_u.c +++ b/io_u.c @@ -249,8 +249,12 @@ static int get_next_seq_block(struct thread_data *td, struct fio_file *f, assert(ddir_rw(ddir)); if (f->last_pos < f->real_file_size) { - unsigned long long pos = f->last_pos - f->file_offset; + unsigned long long pos; + if (f->last_pos == f->file_offset && td->o.ddir_seq_add < 0) + f->last_pos = f->real_file_size; + + pos = f->last_pos - f->file_offset; if (pos) pos += td->o.ddir_seq_add;