je->files_open = le32_to_cpu(je->files_open);
for (i = 0; i < DDIR_RWDIR_CNT; i++) {
- je->m_rate[i] = le32_to_cpu(je->m_rate[i]);
- je->t_rate[i] = le32_to_cpu(je->t_rate[i]);
+ je->m_rate[i] = le64_to_cpu(je->m_rate[i]);
+ je->t_rate[i] = le64_to_cpu(je->t_rate[i]);
je->m_iops[i] = le32_to_cpu(je->m_iops[i]);
je->t_iops[i] = le32_to_cpu(je->t_iops[i]);
- je->rate[i] = le32_to_cpu(je->rate[i]);
+ je->rate[i] = le64_to_cpu(je->rate[i]);
je->iops[i] = le32_to_cpu(je->iops[i]);
}
s = (struct io_sample *)((char *)__get_sample(samples, log_offset, i) +
i * sizeof(struct io_u_plat_entry));
- entry = s->plat_entry;
+ entry = s->data.plat_entry;
io_u_plat = entry->io_u_plat;
fprintf(f, "%lu, %u, %u, ", (unsigned long) s->time,
}
/* allocate buffer big enough for next sprintf() call */
- log_pathname = malloc( 10 +
- strlen((char * )pdu->name) +
+ log_pathname = malloc(10 + strlen((char *)pdu->name) +
strlen(client->hostname));
if (!log_pathname) {
log_err("fio: memory allocation of unique pathname failed");
fd = open((const char *) log_pathname,
O_WRONLY | O_CREAT | O_TRUNC, 0644);
if (fd < 0) {
- log_err("fio: open log %s: %s\n",
+ log_err("fio: open log %s: %s\n",
log_pathname, strerror(errno));
return 1;
}
FILE *f;
f = fopen((const char *) log_pathname, "w");
if (!f) {
- log_err("fio: fopen log %s : %s\n",
+ log_err("fio: fopen log %s : %s\n",
log_pathname, strerror(errno));
return 1;
}
s = (struct io_sample *)((void *)s + sizeof(struct io_u_plat_entry) * i);
s->time = le64_to_cpu(s->time);
- s->val = le64_to_cpu(s->val);
+ s->data.val = le64_to_cpu(s->data.val);
s->__ddir = le32_to_cpu(s->__ddir);
s->bs = le32_to_cpu(s->bs);
}
if (ret->log_type == IO_LOG_TYPE_HIST) {
- s->plat_entry = (struct io_u_plat_entry *)(((void *)s) + sizeof(*s));
- s->plat_entry->list.next = NULL;
- s->plat_entry->list.prev = NULL;
+ s->data.plat_entry = (struct io_u_plat_entry *)(((void *)s) + sizeof(*s));
+ s->data.plat_entry->list.next = NULL;
+ s->data.plat_entry->list.prev = NULL;
}
}