if (!error[i]) {
log_err("Unknown error %s, please use number value \n",
fname);
+ free(error);
return 1;
}
i++;
return 0;
}
-static int str_perc_rand_cb(void *data, unsigned long long *val)
-{
- struct thread_data *td = data;
-
- td->o.perc_rand = *val;
- return 0;
-}
-
-static int str_perc_seq_cb(void *data, unsigned long long *val)
-{
- struct thread_data *td = data;
-
- td->o.perc_rand = 100 - *val;
- return 0;
-}
-
-
static int str_exitall_cb(void)
{
exitall_on_terminate = 1;
.category = FIO_OPT_C_IO,
.group = FIO_OPT_G_INVALID,
},
+ {
+ .name = "bs_is_seq_rand",
+ .lname = "Block size division is seq/random (not read/write)",
+ .type = FIO_OPT_BOOL,
+ .off1 = td_var_offset(bs_is_seq_rand),
+ .help = "Consider any blocksize setting to be sequential,ramdom",
+ .def = "0",
+ .parent = "blocksize",
+ .category = FIO_OPT_C_IO,
+ .group = FIO_OPT_G_INVALID,
+ },
{
.name = "randrepeat",
.lname = "Random repeatable",
.name = "percentage_random",
.lname = "Percentage Random",
.type = FIO_OPT_INT,
- .cb = str_perc_rand_cb,
+ .off1 = td_var_offset(perc_rand[DDIR_READ]),
+ .off2 = td_var_offset(perc_rand[DDIR_WRITE]),
+ .off3 = td_var_offset(perc_rand[DDIR_TRIM]),
.maxval = 100,
.help = "Percentage of seq/random mix that should be random",
- .def = "100",
+ .def = "100,100,100",
.interval = 5,
.inverse = "percentage_sequential",
.category = FIO_OPT_C_IO,
{
.name = "percentage_sequential",
.lname = "Percentage Sequential",
- .type = FIO_OPT_INT,
- .cb = str_perc_seq_cb,
- .maxval = 100,
- .help = "Percentage of seq/random mix that should be sequential",
- .def = "0",
- .interval = 5,
- .inverse = "percentage_random",
+ .type = FIO_OPT_DEPRECATED,
.category = FIO_OPT_C_IO,
.group = FIO_OPT_G_RANDOM,
},