static int pattern_cb(char *pattern, unsigned int max_size,
const char *input, unsigned int *pattern_bytes)
{
- long off;
+ long off = 0;
int i = 0, j = 0, len, k, base = 10;
uint32_t pattern_length;
char *loc1, *loc2;
*/
fill:
pattern_length = i;
+ if (!i && !off)
+ i = 1;
while (i > 1 && i * 2 <= max_size) {
memcpy(&pattern[i], &pattern[0], i);
i *= 2;
/*
* VERIFY_META could already be set
*/
- if (!ret && td->o.verify == VERIFY_NONE)
+ if (!ret && !fio_option_is_set(&td->o, verify))
td->o.verify = VERIFY_PATTERN;
return ret;
.oval = FIO_RAND_GEN_LFSR,
.help = "Variable length LFSR",
},
+ {
+ .ival = "tausworthe64",
+ .oval = FIO_RAND_GEN_TAUSWORTHE64,
+ .help = "64-bit Tausworthe variant",
+ },
},
.category = FIO_OPT_C_IO,
.group = FIO_OPT_G_RANDOM,
.oval = VERIFY_META,
.help = "Use io information",
},
+ { .ival = "pattern",
+ .oval = VERIFY_PATTERN_NO_HDR,
+ .help = "Verify strict pattern",
+ },
{
.ival = "null",
.oval = VERIFY_NULL,
},
{
.name = "allow_file_create",
+ .lname = "Allow file create",
.type = FIO_OPT_BOOL,
.off1 = td_var_offset(allow_create),
.help = "Permit fio to create files, if they don't exist",
.category = FIO_OPT_C_FILE,
.group = FIO_OPT_G_FILENAME,
},
+ {
+ .name = "allow_mounted_write",
+ .lname = "Allow mounted write",
+ .type = FIO_OPT_BOOL,
+ .off1 = td_var_offset(allow_mounted_write),
+ .help = "Allow writes to a mounted partition",
+ .def = "0",
+ .category = FIO_OPT_C_FILE,
+ .group = FIO_OPT_G_FILENAME,
+ },
{
.name = "pre_read",
.lname = "Pre-read files",