diff options
Diffstat (limited to 'drivers/misc/ibmasm/ibmasm.h')
-rw-r--r-- | drivers/misc/ibmasm/ibmasm.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/misc/ibmasm/ibmasm.h b/drivers/misc/ibmasm/ibmasm.h index 5bd127727d8e..9fea49d2e15b 100644 --- a/drivers/misc/ibmasm/ibmasm.h +++ b/drivers/misc/ibmasm/ibmasm.h | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <linux/kref.h> | 34 | #include <linux/kref.h> |
35 | #include <linux/device.h> | 35 | #include <linux/device.h> |
36 | #include <linux/input.h> | 36 | #include <linux/input.h> |
37 | #include <linux/time64.h> | ||
37 | 38 | ||
38 | /* Driver identification */ | 39 | /* Driver identification */ |
39 | #define DRIVER_NAME "ibmasm" | 40 | #define DRIVER_NAME "ibmasm" |
@@ -53,9 +54,11 @@ extern int ibmasm_debug; | |||
53 | 54 | ||
54 | static inline char *get_timestamp(char *buf) | 55 | static inline char *get_timestamp(char *buf) |
55 | { | 56 | { |
56 | struct timeval now; | 57 | struct timespec64 now; |
57 | do_gettimeofday(&now); | 58 | |
58 | sprintf(buf, "%lu.%lu", now.tv_sec, now.tv_usec); | 59 | ktime_get_real_ts64(&now); |
60 | sprintf(buf, "%llu.%.08lu", (long long)now.tv_sec, | ||
61 | now.tv_nsec / NSEC_PER_USEC); | ||
59 | return buf; | 62 | return buf; |
60 | } | 63 | } |
61 | 64 | ||