X-Git-Url: https://git.kernel.dk/?a=blobdiff_plain;f=io_u.c;h=e8894d5dca62ff07a9e39174191ae877490793b5;hb=b37d19b50ceab74c3947dd1685616e21b8638c95;hp=d815ad9a340a63aaee1c0de05c402adec129835e;hpb=d6b72507e72d3f2ed334fa5665880b0ab59dbfdd;p=fio.git diff --git a/io_u.c b/io_u.c index d815ad9a..e8894d5d 100644 --- a/io_u.c +++ b/io_u.c @@ -206,7 +206,6 @@ static int get_next_rand_offset(struct thread_data *td, struct fio_file *f, return get_off_from_method(td, f, ddir, b); if (!flist_empty(&td->next_rand_list)) { - struct rand_off *r; fetch: r = flist_first_entry(&td->next_rand_list, struct rand_off, list); flist_del(&r->list); @@ -581,8 +580,8 @@ static enum fio_ddir rate_ddir(struct thread_data *td, enum fio_ddir ddir) if (td_rw(td) && __should_check_rate(td, odir)) td->rate_pending_usleep[odir] -= usec; - if (ddir_trim(ddir)) - return ddir; + if (ddir == DDIR_TRIM) + return DDIR_TRIM; return ddir; }