Ramp time ETA in thread_eta() was was assuming all rate directions were
being used and that bytes_total was in kilobytes.
Signed-off-by: Sitsofe Wheeler <sitsofe@yahoo.com>
- rate_bytes = ddir_rw_sum(td->o.rate);
+ rate_bytes = 0;
+ if (td_read(td))
+ rate_bytes = td->o.rate[DDIR_READ];
+ if (td_write(td))
+ rate_bytes += td->o.rate[DDIR_WRITE];
+ if (td_trim(td))
+ rate_bytes += td->o.rate[DDIR_TRIM];
+
- r_eta = (bytes_total / 1024) / rate_bytes;
+ r_eta = bytes_total / rate_bytes;
r_eta += (td->o.start_delay / 1000000ULL);
}
r_eta += (td->o.start_delay / 1000000ULL);
}