projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add new writetrim rw= mode for trims preceding writes
[fio.git]
/
options.c
diff --git
a/options.c
b/options.c
index 1857d4115f9a80234ec8aec2bb4a591405448a70..d7ce94bb75c7129cf5e4ff2bc663143ef537d63b 100644
(file)
--- a/
options.c
+++ b/
options.c
@@
-744,8
+744,13
@@
static int str_random_distribution_cb(void *data, const char *str)
return 1;
}
td->o.pareto_h.u.f = val;
return 1;
}
td->o.pareto_h.u.f = val;
- } else
- td->o.gauss_dev = val;
+ } else {
+ if (val <= 0.00 || val >= 100.0) {
+ log_err("fio: normal deviation out of range (0 < input < 100.0)\n");
+ return 1;
+ }
+ td->o.gauss_dev.u.f = val;
+ }
return 0;
}
return 0;
}
@@
-1411,6
+1416,10
@@
struct fio_option fio_options[FIO_MAX_OPTS] = {
.oval = TD_DDIR_RANDRW,
.help = "Random read and write mix"
},
.oval = TD_DDIR_RANDRW,
.help = "Random read and write mix"
},
+ { .ival = "writetrim",
+ .oval = TD_DDIR_WRITETRIM,
+ .help = "Write and trim mix, trims preceding writes"
+ },
},
},
{
},
},
{