diff options
author | Bjoern Brandenburg <bbb@mpi-sws.org> | 2012-08-14 14:31:06 -0400 |
---|---|---|
committer | Bjoern Brandenburg <bbb@mpi-sws.org> | 2012-08-14 14:46:16 -0400 |
commit | 2312a91bde3baeb226ce78c444b18eaa7f80cf34 (patch) | |
tree | 3632d1c940c99f2b1217b9efc654635b93756975 /include | |
parent | f215a05c0ea23c7779b1a3a4361b4d88ddc73dc1 (diff) |
Implement lt_sleep() syscall wrapper
Wrap nanosleep() to make sleeping for a given number of
nanoseconds easier, using the LITMUS^RT time type lt_t.
Diffstat (limited to 'include')
-rw-r--r-- | include/litmus.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/litmus.h b/include/litmus.h index e4b619e..677f9a9 100644 --- a/include/litmus.h +++ b/include/litmus.h | |||
@@ -129,6 +129,9 @@ static inline lt_t ms2lt(unsigned long milliseconds) | |||
129 | return __NS_PER_MS * milliseconds; | 129 | return __NS_PER_MS * milliseconds; |
130 | } | 130 | } |
131 | 131 | ||
132 | /* sleep for some number of nanoseconds */ | ||
133 | int lt_sleep(lt_t timeout); | ||
134 | |||
132 | /* CPU time consumed so far in seconds */ | 135 | /* CPU time consumed so far in seconds */ |
133 | double cputime(void); | 136 | double cputime(void); |
134 | 137 | ||