Add FIO_PREFERRED_CLOCK_SOURCE to allow selection of clock source on a per-platform...
[fio.git] / os / os.h
diff --git a/os/os.h b/os/os.h
index e1c285ce5a5152e6e7cb76af71687efd473dc845..c10cb127a2126ab084162c4945eaba7ee7d52c41 100644 (file)
--- a/os/os.h
+++ b/os/os.h
@@ -2,10 +2,24 @@
 #define FIO_OS_H
 
 #include <sys/types.h>
+#include <sys/socket.h>
 #include <pthread.h>
 #include <unistd.h>
 #include <stdlib.h>
 
+enum {
+       os_linux = 1,
+       os_aix,
+       os_freebsd,
+       os_hpux,
+       os_mac,
+       os_netbsd,
+       os_solaris,
+       os_windows,
+
+       os_nr,
+};
+
 #if defined(__linux__)
 #include "os-linux.h"
 #elif defined(__FreeBSD__)
@@ -111,6 +125,14 @@ typedef unsigned long os_cpu_mask_t;
 #define FIO_PREFERRED_ENGINE   "sync"
 #endif
 
+#ifndef FIO_OS_PATH_SEPARATOR
+#define FIO_OS_PATH_SEPARATOR  "/"
+#endif
+
+#ifndef FIO_PREFERRED_CLOCK_SOURCE
+#define FIO_PREFERRED_CLOCK_SOURCE     CS_CGETTIME
+#endif
+
 #ifndef FIO_MAX_JOBS
 #define FIO_MAX_JOBS           2048
 #endif