summaryrefslogtreecommitdiffstats
path: root/src/os_time.h
diff options
context:
space:
mode:
authorimarom <imarom@cisco.com>2016-04-10 12:52:59 +0300
committerimarom <imarom@cisco.com>2016-04-10 12:52:59 +0300
commit7a3be366c6473203bf9f6d75b945aba75ac3f53a (patch)
treee3809ff89be55a0ca7a9dcc4aca0c309388b7119 /src/os_time.h
parent9823cf0a2acfa3eed27613bf357d82c241889cba (diff)
some refinements and few refactors
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