summaryrefslogtreecommitdiff
path: root/libhw/host_sigrt.h
diff options
context:
space:
mode:
Diffstat (limited to 'libhw/host_sigrt.h')
-rw-r--r--libhw/host_sigrt.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/libhw/host_sigrt.h b/libhw/host_sigrt.h
index fa5675b..e8be26a 100644
--- a/libhw/host_sigrt.h
+++ b/libhw/host_sigrt.h
@@ -35,13 +35,13 @@ static inline host_ns_time_t ns_to_host_ns_time(uint64_t time_ns) {
}
static inline uint64_t ns_from_host_us_time(host_us_time_t host_time) {
- return (((uint64_t)ts.tv_sec) * NS_PER_S) +
- ((uint64_t)ts.tv_nsec * (NS_PER_S/US_PER_S));
+ return (((uint64_t)host_time.tv_sec) * NS_PER_S) +
+ ((uint64_t)host_time.tv_usec * (NS_PER_S/US_PER_S));
}
static inline uint64_t ns_from_host_ns_time(host_ns_time_t host_time) {
- return (((uint64_t)ts.tv_sec) * NS_PER_S) +
- ((uint64_t)ts.tv_nsec);
+ return (((uint64_t)host_time.tv_sec) * NS_PER_S) +
+ ((uint64_t)host_time.tv_nsec);
}
#endif /* _LIBHW_HOST_SIGRT_H_ */