return strdup(p);
}
+static int str_rw_cb(void *data, const char *str)
+{
+ struct thread_data *td = data;
+ char *nr = get_opt_postfix(str);
+
+ td->o.ddir_nr = 0;
+ if (nr)
+ td->o.ddir_nr = atoi(nr);
+
+ printf("ddir_nr=%d\n", td->o.ddir_nr);
+
+ return 0;
+}
+
static int str_mem_cb(void *data, const char *mem)
{
struct thread_data *td = data;
.name = "rw",
.alias = "readwrite",
.type = FIO_OPT_STR,
+ .cb = str_rw_cb,
.off1 = td_var_offset(td_ddir),
.help = "IO direction",
.def = "read",