diff options
| author | Peter Zijlstra <peterz@infradead.org> | 2015-03-17 07:39:10 -0400 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2015-03-27 04:45:10 -0400 |
| commit | fe5fba05b46c791c95a9f34228ac495f81f72fc0 (patch) | |
| tree | 8f96b57c0aae9034491b5e2896340dfec7d03635 /include/linux/timekeeping.h | |
| parent | f09cb9a1808e35ad7502ea39b6bfb443c7fa0f19 (diff) | |
time: Add ktime_get_tai_ns()
Because it was the only clock for which we didn't have a _ns()
accessor yet.
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: John Stultz <john.stultz@linaro.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/linux/timekeeping.h')
| -rw-r--r-- | include/linux/timekeeping.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/timekeeping.h b/include/linux/timekeeping.h index f36b1edf3f73..5047b83483d6 100644 --- a/include/linux/timekeeping.h +++ b/include/linux/timekeeping.h | |||
| @@ -214,6 +214,11 @@ static inline u64 ktime_get_boot_ns(void) | |||
| 214 | return ktime_to_ns(ktime_get_boottime()); | 214 | return ktime_to_ns(ktime_get_boottime()); |
| 215 | } | 215 | } |
| 216 | 216 | ||
| 217 | static inline u64 ktime_get_tai_ns(void) | ||
| 218 | { | ||
| 219 | return ktime_to_ns(ktime_get_clocktai()); | ||
| 220 | } | ||
| 221 | |||
| 217 | static inline u64 ktime_get_raw_ns(void) | 222 | static inline u64 ktime_get_raw_ns(void) |
| 218 | { | 223 | { |
| 219 | return ktime_to_ns(ktime_get_raw()); | 224 | return ktime_to_ns(ktime_get_raw()); |
