Signed-off-by: Jens Axboe <axboe@kernel.dk>
unsigned int *fio_debug_jobp = NULL;
static char cmd_optstr[256];
unsigned int *fio_debug_jobp = NULL;
static char cmd_optstr[256];
#define FIO_CLIENT_FLAG (1 << 16)
#define FIO_CLIENT_FLAG (1 << 16)
output_format |= FIO_OUTPUT_TERSE;
break;
case 'h':
output_format |= FIO_OUTPUT_TERSE;
break;
case 'h':
if (!cur_client) {
usage(argv[0]);
do_exit++;
}
break;
case 'c':
if (!cur_client) {
usage(argv[0]);
do_exit++;
}
break;
case 'c':
if (!cur_client) {
fio_show_option_help(optarg);
do_exit++;
}
break;
case 'i':
if (!cur_client) {
fio_show_option_help(optarg);
do_exit++;
}
break;
case 'i':
if (!cur_client) {
fio_show_ioengine_help(optarg);
do_exit++;
}
break;
case 's':
if (!cur_client) {
fio_show_ioengine_help(optarg);
do_exit++;
}
break;
case 's':
dump_cmdline = 1;
break;
case 'r':
read_only = 1;
break;
case 'v':
dump_cmdline = 1;
break;
case 'r':
read_only = 1;
break;
case 'v':
if (!cur_client) {
log_info("%s\n", fio_version_string);
do_exit++;
if (!cur_client) {
log_info("%s\n", fio_version_string);
do_exit++;
do_exit++;
break;
case 'P':
do_exit++;
break;
case 'P':
parse_only = 1;
break;
case 'x': {
parse_only = 1;
break;
case 'x': {
#ifdef CONFIG_ZLIB
case 'X':
exit_val = iolog_file_inflate(optarg);
#ifdef CONFIG_ZLIB
case 'X':
exit_val = iolog_file_inflate(optarg);
do_exit++;
break;
#endif
case 'p':
do_exit++;
break;
#endif
case 'p':
if (exec_profile)
free(exec_profile);
exec_profile = strdup(optarg);
if (exec_profile)
free(exec_profile);
exec_profile = strdup(optarg);
if (ret)
goto out_free;
td = NULL;
if (ret)
goto out_free;
td = NULL;
}
if (!td) {
int is_section = !strncmp(opt, "name", 4);
}
if (!td) {
int is_section = !strncmp(opt, "name", 4);
#ifndef CONFIG_NO_SHM
if (nr_clients) {
log_err("fio: can't be both client and server\n");
#ifndef CONFIG_NO_SHM
if (nr_clients) {
log_err("fio: can't be both client and server\n");
case 'I':
if ((ret = fio_idle_prof_parse_opt(optarg))) {
/* exit on error and calibration only */
case 'I':
if ((ret = fio_idle_prof_parse_opt(optarg))) {
/* exit on error and calibration only */
do_exit++;
if (ret == -1)
exit_val = 1;
}
break;
case 'C':
do_exit++;
if (ret == -1)
exit_val = 1;
}
break;
case 'C':
if (is_backend) {
log_err("fio: can't be both client and server\n");
do_exit++;
if (is_backend) {
log_err("fio: can't be both client and server\n");
do_exit++;
if (fio_client_add_ini_file(cur_client, optarg, true)) {
do_exit++;
exit_val = 1;
}
break;
case 'T':
if (fio_client_add_ini_file(cur_client, optarg, true)) {
do_exit++;
exit_val = 1;
}
break;
case 'T':
do_exit++;
exit_val = fio_monotonic_clocktest(1);
break;
case 'G':
do_exit++;
exit_val = fio_monotonic_clocktest(1);
break;
case 'G':
do_exit++;
exit_val = fio_crctest(optarg);
break;
do_exit++;
exit_val = fio_crctest(optarg);
break;