-#endif
- fill_cpu_mask(td->cpumask, cpu);
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "fsync", &td->fsync_blocks)) {
- fgetpos(f, &off);
- td->end_fsync = 1;
- continue;
- }
- if (!check_int(p, "startdelay", &td->start_delay)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_str_time(p, "timeout", &ull)) {
- td->timeout = ull;
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "invalidate", &il)) {
- td->invalidate_cache = il;
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "iodepth", &td->iodepth)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "sync", &il)) {
- td->sync_io = il;
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "bwavgtime", &td->bw_avg_time)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "create_serialize", &il)) {
- td->create_serialize = il;
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "create_fsync", &il)) {
- td->create_fsync = il;
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "end_fsync", &il)) {
- td->end_fsync = il;
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "loops", &td->loops)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "numjobs", &td->numjobs)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "overwrite", &il)) {
- td->overwrite = il;
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "rwmixcycle", &td->rwmixcycle)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "rwmixread", &il)) {
- if (il > 100)
- il = 100;
- td->rwmixread = il;
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "rwmixwrite", &il)) {
- if (il > 100)
- il = 100;
- td->rwmixread = 100 - il;
- fgetpos(f, &off);
- continue;
- }
- if (!check_int(p, "nice", &td->nice)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_range_bytes(p, "bsrange", &ul1, &ul2)) {
- if (ul1 > ul2) {
- td->max_bs = ul1;
- td->min_bs = ul2;
- } else {
- td->max_bs = ul2;
- td->min_bs = ul1;
- }
- fgetpos(f, &off);
- continue;
- }
- if (!check_str_bytes(p, "bs", &ull)) {
- td->bs = ull;
- fgetpos(f, &off);
- continue;
- }
- if (!check_str_bytes(p, "size", &td->file_size)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_str_bytes(p, "offset", &td->file_offset)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_str_bytes(p, "zonesize", &td->zone_size)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_str_bytes(p, "zoneskip", &td->zone_skip)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_str_bytes(p, "lockmem", &mlock_size)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_strstore(p, "directory", tmpbuf)) {
- td->directory = strdup(tmpbuf);
- fgetpos(f, &off);
- continue;
- }
- if (!check_strstore(p, "name", tmpbuf)) {
- snprintf(td->name, sizeof(td->name)-1, "%s%d", tmpbuf, td->thread_number);
- fgetpos(f, &off);
- continue;
- }
- if (!check_str(p, "mem", str_mem_cb, td)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_str(p, "verify", str_verify_cb, td)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_str(p, "rw", str_rw_cb, td)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_str(p, "ioengine", str_ioengine_cb, td)) {
- fgetpos(f, &off);
- continue;
- }
- if (!check_strset(p, "create")) {
- td->create_file = 1;
- fgetpos(f, &off);
- continue;
- }
- if (!check_strset(p, "exitall")) {
- exitall_on_terminate = 1;
- fgetpos(f, &off);
- continue;
- }
- if (!check_strset(p, "stonewall")) {
- td->stonewall = 1;
- fgetpos(f, &off);
- continue;
- }
- if (!check_strset(p, "thread")) {
- td->use_thread = 1;
- fgetpos(f, &off);
- continue;
- }
- if (!check_strstore(p, "iolog", tmpbuf)) {
- if (td->write_iolog) {
- log_err("fio: read iolog overrides given write_iolog\n");
- free(td->iolog_file);
- td->write_iolog = 0;
- }
- td->iolog_file = strdup(tmpbuf);
- td->read_iolog = 1;
- fgetpos(f, &off);
- continue;
- }
- if (!check_strstore(p, "write_iolog", tmpbuf)) {
- if (!td->read_iolog) {
- td->iolog_file = strdup(tmpbuf);
- td->write_iolog = 1;
- } else
- log_err("fio: read iolog overrides given write_iolog\n");
- fgetpos(f, &off);
- continue;
- }
- if (!check_strstore(p, "exec_prerun", tmpbuf)) {
- td->exec_prerun = strdup(tmpbuf);
- fgetpos(f, &off);
- continue;
- }
- if (!check_strstore(p, "exec_postrun", tmpbuf)) {
- td->exec_postrun = strdup(tmpbuf);
- fgetpos(f, &off);
- continue;
- }
- if (!check_strstore(p, "ioscheduler", tmpbuf)) {
-#ifndef FIO_HAVE_IOSCHED_SWITCH
- log_err("io scheduler switching not available\n");
- ret = 1;
- break;
-#else
- td->ioscheduler = strdup(tmpbuf);
- fgetpos(f, &off);
- continue;
-#endif
- }