#include "fio.h"
+static struct timeval genesis;
+
unsigned long utime_since(struct timeval *s, struct timeval *e)
{
double sec, usec;
/*
* busy looping version for the last few usec
*/
-static void __usec_sleep(unsigned int usec)
+void __usec_sleep(unsigned int usec)
{
struct timeval start;
td->rate_pending_usleep -= overtime;
}
}
+
+unsigned long mtime_since_genesis(void)
+{
+ return mtime_since_now(&genesis);
+}
+
+void time_init(void)
+{
+ gettimeofday(&genesis, NULL);
+}