summaryrefslogtreecommitdiff
path: root/include/uapi
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2018-02-01 11:37:30 +0300
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2018-02-01 11:37:30 +0300
commitd67ad78e09cbb9935c74a40b85c5abe5b9cd48f8 (patch)
tree56e92b487de80090a998ff3c0469375982156802 /include/uapi
parent060403f34008af90e310d7e0e7531ebb3acf9557 (diff)
parentfafef982c7353e8982b951e40573e990ccf0ed00 (diff)
downloadlinux-d67ad78e09cbb9935c74a40b85c5abe5b9cd48f8.tar.xz
Merge branch 'next' into for-linus
Prepare input updates for 4.16 merge window.
Diffstat (limited to 'include/uapi')
-rw-r--r--include/uapi/linux/input.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/uapi/linux/input.h b/include/uapi/linux/input.h
index 8c5a0bf6ee35..7288a7c573cc 100644
--- a/include/uapi/linux/input.h
+++ b/include/uapi/linux/input.h
@@ -21,10 +21,21 @@
/*
* The event structure itself
+ * Note that __USE_TIME_BITS64 is defined by libc based on
+ * application's request to use 64 bit time_t.
*/
struct input_event {
+#if (__BITS_PER_LONG != 32 || !defined(__USE_TIME_BITS64)) && !defined(__KERNEL)
struct timeval time;
+#define input_event_sec time.tv_sec
+#define input_event_usec time.tv_usec
+#else
+ __kernel_ulong_t __sec;
+ __kernel_ulong_t __usec;
+#define input_event_sec __sec
+#define input_event_usec __usec
+#endif
__u16 type;
__u16 code;
__s32 value;