Remove version number from Windows MSI file
[fio.git] / eta.c
diff --git a/eta.c b/eta.c
index 81dbfa7ef2833438ab9344431e6024f31e33075b..ba6a3989366f37b025c42b5a4569e91ab707febe 100644 (file)
--- a/eta.c
+++ b/eta.c
@@ -161,12 +161,13 @@ static int thread_eta(struct thread_data *td)
                 * if given, otherwise assume it'll run at the specified rate.
                 */
                if (td->o.timeout) {
-                       t_eta = td->o.timeout + td->o.start_delay;
+                       t_eta = td->o.timeout + td->o.start_delay +
+                                       td->o.ramp_time;
 
                        if (in_ramp_time(td)) {
                                unsigned long ramp_left;
 
-                               ramp_left = mtime_since_now(&td->start);
+                               ramp_left = mtime_since_now(&td->epoch);
                                ramp_left = (ramp_left + 999) / 1000;
                                if (ramp_left <= t_eta)
                                        t_eta -= ramp_left;
@@ -328,7 +329,11 @@ void print_thread_status(void)
        }
 
        disp_time = mtime_since(&disp_prev_time, &now);
-       if (disp_time < 1000)
+
+       /*
+        * Allow a little slack, the target is to print it every 1000 msecs
+        */
+       if (disp_time < 900)
                return;
 
        calc_rate(disp_time, io_bytes, disp_io_bytes, rate);