Skip to content

Commit

Permalink
init: don't adjust time units again for subjobs
Browse files Browse the repository at this point in the history
We adjust max_latency and latency_target values to be nsec internally.
Make sure we do this only once for the parent job and don't do it a
second time for a subjob.

Fixes: #1582
Signed-off-by: Vincent Fu <vincent.fu@samsung.com>
  • Loading branch information
vincentkfu committed Jun 20, 2023
1 parent 8ce9c40 commit 5087502
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions init.c
Original file line number Diff line number Diff line change
Expand Up @@ -951,13 +951,16 @@ static int fixup_options(struct thread_data *td)
if (o->disable_slat)
o->slat_percentiles = 0;

/*
* Fix these up to be nsec internally
*/
for_each_rw_ddir(ddir)
o->max_latency[ddir] *= 1000ULL;
/* Do this only for the parent job */
if (!td->subjob_number) {
/*
* Fix these up to be nsec internally
*/
for_each_rw_ddir(ddir)
o->max_latency[ddir] *= 1000ULL;

o->latency_target *= 1000ULL;
o->latency_target *= 1000ULL;
}

/*
* Dedupe working set verifications
Expand Down

0 comments on commit 5087502

Please sign in to comment.