X-Git-Url: https://git.kernel.dk/?p=fio.git;a=blobdiff_plain;f=init.c;h=f2ba1e208e8f1cc44d37490501abb932c6b6ed4b;hp=1eddc6f20721a77db3e3ac0656455637f548cf48;hb=32e31c8c5f7b1695a85a79da02ac854899abbb39;hpb=f1867a7f9e588acf67cf8fa96eab8a6e2fdedcf6 diff --git a/init.c b/init.c index 1eddc6f2..f2ba1e20 100644 --- a/init.c +++ b/init.c @@ -744,19 +744,12 @@ static int fixup_options(struct thread_data *td) /* * There's no need to check for in-flight overlapping IOs if the job * isn't changing data or the maximum iodepth is guaranteed to be 1 + * when we are not in offload mode */ if (o->serialize_overlap && !(td->flags & TD_F_READ_IOLOG) && - (!(td_write(td) || td_trim(td)) || o->iodepth == 1)) + (!(td_write(td) || td_trim(td)) || o->iodepth == 1) && + o->io_submit_mode != IO_MODE_OFFLOAD) o->serialize_overlap = 0; - /* - * Currently can't check for overlaps in offload mode - */ - if (o->serialize_overlap && o->io_submit_mode == IO_MODE_OFFLOAD) { - log_err("fio: checking for in-flight overlaps when the " - "io_submit_mode is offload is not supported\n"); - o->serialize_overlap = 0; - ret |= warnings_fatal; - } if (o->nr_files > td->files_index) o->nr_files = td->files_index; @@ -1224,7 +1217,7 @@ static void init_flags(struct thread_data *td) static int setup_random_seeds(struct thread_data *td) { - unsigned long seed; + uint64_t seed; unsigned int i; if (!td->o.rand_repeatable && !fio_option_is_set(&td->o, rand_seed)) { @@ -1445,7 +1438,7 @@ static int add_job(struct thread_data *td, const char *jobname, int job_add_num, int recursed, int client_type) { unsigned int i; - char fname[PATH_MAX]; + char fname[PATH_MAX + 1]; int numjobs, file_alloced; struct thread_options *o = &td->o; char logname[PATH_MAX + 32]; @@ -2047,7 +2040,8 @@ static int __parse_jobs_ini(struct thread_data *td, strncpy(full_fn, file, (ts - file) + 1); strncpy(full_fn + (ts - file) + 1, - filename, strlen(filename)); + filename, + len - (ts - file) - 1); full_fn[len - 1] = 0; filename = full_fn; } @@ -2914,6 +2908,7 @@ int parse_cmd_line(int argc, char *argv[], int client_type) log_err("%s: unrecognized option '%s'\n", argv[0], argv[optind - 1]); show_closest_option(argv[optind - 1]); + /* fall through */ default: do_exit++; exit_val = 1;