aboutsummaryrefslogtreecommitdiff
path: root/include/uapi
diff options
context:
space:
mode:
authorArve Hjønnevåg <arve@android.com>2008-10-17 15:20:55 -0700
committerJohn Stultz <john.stultz@linaro.org>2015-11-19 12:35:51 -0800
commit1fd71481b0f41a47d28fe83b29cddbec60facab8 (patch)
tree7b36834ccd23edc2292204686391224bf2ae899f /include/uapi
parentac1abfc45ef211f2f242ad96830f640ee13b1fa5 (diff)
downloadv4.1-1fd71481b0f41a47d28fe83b29cddbec60facab8.tar.gz
Input: evdev - Add ioctl to block suspend while event queue is not empty.
Add an ioctl, EVIOCSSUSPENDBLOCK, to enable a wakelock that will block suspend while the event queue is not empty. This allows userspace code to process input events while the device appears to be asleep. The current code holds the wakelock for up 5 seconds for every input device and client. This can prevent suspend if sensor with a high data rate is active, even when that sensor is not capable of waking the device once it is suspended. Change-Id: I624d66ef30a0b3abb543685c343382b8419b42b9 Signed-off-by: Arve Hjønnevåg <arve@android.com>
Diffstat (limited to 'include/uapi')
-rw-r--r--include/uapi/linux/input.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/uapi/linux/input.h b/include/uapi/linux/input.h
index 5a52bf50ad2..166418c0e4d 100644
--- a/include/uapi/linux/input.h
+++ b/include/uapi/linux/input.h
@@ -156,6 +156,9 @@ struct input_keymap_entry {
/* HACK: disable conflicting EVIOCREVOKE until Android userspace stops using EVIOCSSUSPENDBLOCK */
/*#define EVIOCREVOKE _IOW('E', 0x91, int)*/ /* Revoke device access */
+#define EVIOCGSUSPENDBLOCK _IOR('E', 0x91, int) /* get suspend block enable */
+#define EVIOCSSUSPENDBLOCK _IOW('E', 0x91, int) /* set suspend block enable */
+
#define EVIOCSCLOCKID _IOW('E', 0xa0, int) /* Set clockid to be used for timestamps */
/*