time: Consolidate the time accessor prototypes
Right now we have time related prototypes in 3 different header files. Move it to a single timekeeping header file and move the core internal stuff into a core private header. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: John Stultz <john.stultz@linaro.org>
This commit is contained in:

committed by
John Stultz

parent
7d489d15ce
commit
8b094cd03b
@@ -250,12 +250,6 @@ static inline __must_check bool ktime_to_timespec64_cond(const ktime_t kt,
|
||||
#define LOW_RES_NSEC TICK_NSEC
|
||||
#define KTIME_LOW_RES (ktime_t){ .tv64 = LOW_RES_NSEC }
|
||||
|
||||
/* Get the monotonic time in timespec format: */
|
||||
extern void ktime_get_ts(struct timespec *ts);
|
||||
|
||||
/* Get the real (wall-) time in timespec format: */
|
||||
#define ktime_get_real_ts(ts) getnstimeofday(ts)
|
||||
|
||||
static inline ktime_t ns_to_ktime(u64 ns)
|
||||
{
|
||||
static const ktime_t ktime_zero = { .tv64 = 0 };
|
||||
@@ -270,4 +264,6 @@ static inline ktime_t ms_to_ktime(u64 ms)
|
||||
return ktime_add_ms(ktime_zero, ms);
|
||||
}
|
||||
|
||||
# include <linux/timekeeping.h>
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user