projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Bool conversions
[fio.git]
/
backend.c
diff --git
a/backend.c
b/backend.c
index 36bde6a587535635ee9d1dcef6c0bc0c5160f772..76e456f1295da2d827269c27716ef63cbd33af43 100644
(file)
--- a/
backend.c
+++ b/
backend.c
@@
-53,7
+53,7
@@
static struct fio_sem *startup_sem;
static struct flist_head *cgroup_list;
static struct cgroup_mnt *cgroup_mnt;
static int exit_value;
static struct flist_head *cgroup_list;
static struct cgroup_mnt *cgroup_mnt;
static int exit_value;
-static volatile
int
fio_abort;
+static volatile
bool
fio_abort;
static unsigned int nr_process = 0;
static unsigned int nr_thread = 0;
static unsigned int nr_process = 0;
static unsigned int nr_thread = 0;
@@
-2213,18
+2213,22
@@
static void run_threads(struct sk_out *sk_out)
}
if (output_format & FIO_OUTPUT_NORMAL) {
}
if (output_format & FIO_OUTPUT_NORMAL) {
- log_info("Starting ");
+ struct buf_output out;
+
+ buf_output_init(&out);
+ __log_buf(&out, "Starting ");
if (nr_thread)
if (nr_thread)
-
log_info(
"%d thread%s", nr_thread,
+
__log_buf(&out,
"%d thread%s", nr_thread,
nr_thread > 1 ? "s" : "");
if (nr_process) {
if (nr_thread)
nr_thread > 1 ? "s" : "");
if (nr_process) {
if (nr_thread)
-
log_info(
" and ");
-
log_info(
"%d process%s", nr_process,
+
__log_buf(&out,
" and ");
+
__log_buf(&out,
"%d process%s", nr_process,
nr_process > 1 ? "es" : "");
}
nr_process > 1 ? "es" : "");
}
- log_info("\n");
- log_info_flush();
+ __log_buf(&out, "\n");
+ log_info_buf(out.buf, out.buflen);
+ buf_output_free(&out);
}
todo = thread_number;
}
todo = thread_number;
@@
-2367,7
+2371,7
@@
reap:
if (fio_sem_down_timeout(startup_sem, 10000)) {
log_err("fio: job startup hung? exiting.\n");
fio_terminate_threads(TERMINATE_ALL);
if (fio_sem_down_timeout(startup_sem, 10000)) {
log_err("fio: job startup hung? exiting.\n");
fio_terminate_threads(TERMINATE_ALL);
- fio_abort =
1
;
+ fio_abort =
true
;
nr_started--;
free(fd);
break;
nr_started--;
free(fd);
break;
@@
-2481,6
+2485,8
@@
int fio_backend(struct sk_out *sk_out)
}
startup_sem = fio_sem_init(FIO_SEM_LOCKED);
}
startup_sem = fio_sem_init(FIO_SEM_LOCKED);
+ if (!sk_out)
+ is_local_backend = true;
if (startup_sem == NULL)
return 1;
if (startup_sem == NULL)
return 1;