summaryrefslogtreecommitdiffstats
path: root/src/os_time.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/os_time.h')
-rwxr-xr-xsrc/os_time.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/os_time.h b/src/os_time.h
index 0e732abf..42be576f 100755
--- a/src/os_time.h
+++ b/src/os_time.h
@@ -31,6 +31,11 @@ typedef double dsec_t; //time in sec double
uint32_t os_get_time_msec();
uint32_t os_get_time_freq();
+static inline double
+usec_to_sec(double usec) {
+ return (usec / (1000 * 1000));
+}
+
#ifdef LINUX