summaryrefslogtreecommitdiffstats
path: root/include/linux/timekeeping32.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/timekeeping32.h')
-rw-r--r--include/linux/timekeeping32.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/include/linux/timekeeping32.h b/include/linux/timekeeping32.h
index 5abff52d07fd..8762c2f45f8b 100644
--- a/include/linux/timekeeping32.h
+++ b/include/linux/timekeeping32.h
@@ -11,9 +11,11 @@ unsigned long get_seconds(void);
static inline struct timespec current_kernel_time(void)
{
- struct timespec64 now = current_kernel_time64();
+ struct timespec64 ts64;
+
+ ktime_get_coarse_real_ts64(&ts64);
- return timespec64_to_timespec(now);
+ return timespec64_to_timespec(ts64);
}
/**
@@ -55,13 +57,17 @@ static inline void getrawmonotonic(struct timespec *ts)
{
struct timespec64 ts64;
- getrawmonotonic64(&ts64);
+ ktime_get_raw_ts64(&ts64);
*ts = timespec64_to_timespec(ts64);
}
static inline struct timespec get_monotonic_coarse(void)
{
- return timespec64_to_timespec(get_monotonic_coarse64());
+ struct timespec64 ts64;
+
+ ktime_get_coarse_ts64(&ts64);
+
+ return timespec64_to_timespec(ts64);
}
static inline void getboottime(struct timespec *ts)
OpenPOWER on IntegriCloud