*
*/
#include <unistd.h>
-#include <fcntl.h>
-#include <string.h>
-#include <limits.h>
-#include <signal.h>
-#include <time.h>
#include <locale.h>
-#include <assert.h>
#include <time.h>
-#include <sys/stat.h>
-#include <sys/wait.h>
-#include <sys/ipc.h>
-#include <sys/shm.h>
-#include <sys/mman.h>
#include "fio.h"
-#include "hash.h"
#include "smalloc.h"
-#include "verify.h"
-#include "trim.h"
-#include "diskutil.h"
-#include "profile.h"
-#include "lib/rand.h"
-#include "memalign.h"
-#include "server.h"
-unsigned long page_mask;
-unsigned long page_size;
+uintptr_t page_mask = 0;
+uintptr_t page_size = 0;
static int endian_check(void)
{
else if (u.c[0] == 0x12)
le = 1;
-#if defined(FIO_LITTLE_ENDIAN)
+#if defined(CONFIG_LITTLE_ENDIAN)
if (be)
return 1;
-#elif defined(FIO_BIG_ENDIAN)
+#elif defined(CONFIG_BIG_ENDIAN)
if (le)
return 1;
#else
return 1;
}
+#if !defined(CONFIG_GETTIMEOFDAY) && !defined(CONFIG_CLOCK_GETTIME)
+#error "No available clock source!"
+#endif
+
arch_init(envp);
sinit();
if (parse_options(argc, argv))
return 1;
+ fio_time_init();
+
if (nr_clients)
return fio_handle_clients();
else