Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
if (eta_sec != INT_MAX && elapsed) {
perc = (double) elapsed / (double) (elapsed + eta_sec);
eta_to_str(eta_str, eta_sec);
if (eta_sec != INT_MAX && elapsed) {
perc = (double) elapsed / (double) (elapsed + eta_sec);
eta_to_str(eta_str, eta_sec);
}
printf("\r");
fflush(stdout);
}
printf("\r");
fflush(stdout);
}
void print_status_init(int thread_number)
}
void print_status_init(int thread_number)
int ret = switch_ioscheduler(td);
free(td->ioscheduler);
int ret = switch_ioscheduler(td);
free(td->ioscheduler);
sprintf(foo, "%s", tmp);
}
sprintf(foo, "%s", tmp);
}
- td->sysfs_root = strdup(foo);
+ if (td->ioscheduler)
+ td->sysfs_root = strdup(foo);
+
disk_util_add(dev, foo);
}
disk_util_add(dev, foo);
}
}
static inline void add_stat_sample(struct io_stat *is, unsigned long val)
}
static inline void add_stat_sample(struct io_stat *is, unsigned long val)