diff options
author | Arve Hjønnevåg <arve@android.com> | 2008-10-17 15:20:55 -0700 |
---|---|---|
committer | Colin Cross <ccross@android.com> | 2014-03-19 13:02:05 -0700 |
commit | 6e71fda4b35e9b8b4f2f009b9d2b70214ea2db3a (patch) | |
tree | 968fa71f8339d1db2ed31b00ccc1d6a683188a1e /include/uapi | |
parent | 32a771aaf05c3599184ef5f9d2b545d79b5b3fc4 (diff) |
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.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/uapi/linux/input.h b/include/uapi/linux/input.h index 24593061fea..9a49af0b6d6 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 */ /* |