aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Zijlstra2015-03-17 12:39:10 +0100
committerIngo Molnar2015-03-27 09:45:10 +0100
commitfe5fba05b46c791c95a9f34228ac495f81f72fc0 (patch)
tree8f96b57c0aae9034491b5e2896340dfec7d03635
parentf09cb9a1808e35ad7502ea39b6bfb443c7fa0f19 (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>
-rw-r--r--include/linux/timekeeping.h5
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)
return ktime_to_ns(ktime_get_boottime());
}
+static inline u64 ktime_get_tai_ns(void)
+{
+ return ktime_to_ns(ktime_get_clocktai());
+}
+
static inline u64 ktime_get_raw_ns(void)
{
return ktime_to_ns(ktime_get_raw());