projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add support for O_ATOMIC
[fio.git]
/
parse.c
diff --git
a/parse.c
b/parse.c
index e8b628cee7be114d2579aa5a1d2fe75515653127..5e3573ea646fcb52ca1b08d043712d2c89efb0c6 100644
(file)
--- a/
parse.c
+++ b/
parse.c
@@
-285,7
+285,7
@@
int check_str_bytes(const char *p, long long *val, void *data)
return str_to_decimal(p, val, 1, data);
}
return str_to_decimal(p, val, 1, data);
}
-
static
int check_str_time(const char *p, long long *val)
+int check_str_time(const char *p, long long *val)
{
return str_to_decimal(p, val, 0, NULL);
}
{
return str_to_decimal(p, val, 0, NULL);
}
@@
-380,7
+380,7
@@
static int str_match_len(const struct value_pair *vp, const char *str)
static int __handle_option(struct fio_option *o, const char *ptr, void *data,
int first, int more, int curr)
{
static int __handle_option(struct fio_option *o, const char *ptr, void *data,
int first, int more, int curr)
{
- int il, *ilp;
+ int il
=0
, *ilp;
fio_fp64_t *flp;
long long ull, *ullp;
long ul1, ul2;
fio_fp64_t *flp;
long long ull, *ullp;
long ul1, ul2;
@@
-451,6
+451,8
@@
static int __handle_option(struct fio_option *o, const char *ptr, void *data,
else
ret = check_str_bytes(tmp, &ull, data);
else
ret = check_str_bytes(tmp, &ull, data);
+ dprint(FD_PARSE, " ret=%d, out=%llu\n", ret, ull);
+
if (ret)
break;
if (ret)
break;
@@
-576,6
+578,8
@@
static int __handle_option(struct fio_option *o, const char *ptr, void *data,
flp = td_var(data, o->off1);
flp[curr].u.f = uf;
flp = td_var(data, o->off1);
flp[curr].u.f = uf;
+ dprint(FD_PARSE, " out=%f\n", uf);
+
/*
** Calculate precision for output by counting
** number of digits after period. Find first
/*
** Calculate precision for output by counting
** number of digits after period. Find first
@@
-745,6
+749,8
@@
static int __handle_option(struct fio_option *o, const char *ptr, void *data,
else
il = 1;
else
il = 1;
+ dprint(FD_PARSE, " ret=%d, out=%d\n", ret, il);
+
if (ret)
break;
if (ret)
break;
@@
-782,6
+788,7
@@
static int __handle_option(struct fio_option *o, const char *ptr, void *data,
}
case FIO_OPT_DEPRECATED:
log_info("Option %s is deprecated\n", o->name);
}
case FIO_OPT_DEPRECATED:
log_info("Option %s is deprecated\n", o->name);
+ ret = 1;
break;
default:
log_err("Bad option type %u\n", o->type);
break;
default:
log_err("Bad option type %u\n", o->type);
@@
-1080,6
+1087,8
@@
int show_cmd_help(struct fio_option *options, const char *name)
continue;
if (!exec_profile && o->prof_name)
continue;
continue;
if (!exec_profile && o->prof_name)
continue;
+ if (exec_profile && !(o->prof_name && !strcmp(exec_profile, o->prof_name)))
+ continue;
if (name) {
if (!strcmp(name, o->name) ||
if (name) {
if (!strcmp(name, o->name) ||