X-Git-Url: https://git.kernel.dk/?p=fio.git;a=blobdiff_plain;f=fio.c;h=24af397a414d27669c6aa7874d3d5170737ea0c2;hp=f0a8ee2636d015116055d69148a0f524dfc50f40;hb=c81f9347e5849a6b97a02f215f1c474e27c79f1a;hpb=2e1df07d1ea30e0304cc65370f3ed161a6f22cd4 diff --git a/fio.c b/fio.c index f0a8ee26..24af397a 100644 --- a/fio.c +++ b/fio.c @@ -22,19 +22,8 @@ * */ #include -#include -#include -#include -#include -#include #include -#include #include -#include -#include -#include -#include -#include #include "fio.h" #include "hash.h" @@ -42,31 +31,13 @@ #include "verify.h" #include "trim.h" #include "diskutil.h" -#include "cgroup.h" #include "profile.h" #include "lib/rand.h" #include "memalign.h" #include "server.h" -unsigned long page_mask; -unsigned long page_size; - -int groupid = 0; -unsigned int thread_number = 0; -unsigned int nr_process = 0; -unsigned int nr_thread = 0; -int shm_id = 0; -int temp_stall_ts; -unsigned long done_secs = 0; - -/* - * Just expose an empty list, if the OS does not support disk util stats - */ -#ifndef FIO_HAVE_DISK_UTIL -FLIST_HEAD(disk_list); -#endif - -unsigned long arch_flags = 0; +uintptr_t page_mask; +uintptr_t page_size; static int endian_check(void) { @@ -108,6 +79,10 @@ int main(int argc, char *argv[], char *envp[]) return 1; } +#if !defined(CONFIG_GETTIMEOFDAY) && !defined(CONFIG_CLOCK_GETTIME) +#error "No available clock source!" +#endif + arch_init(envp); sinit(); @@ -133,6 +108,8 @@ int main(int argc, char *argv[], char *envp[]) if (parse_options(argc, argv)) return 1; + fio_time_init(); + if (nr_clients) return fio_handle_clients(); else