diff options
author | Angela Czubak <acz@semihalf.com> | 2022-07-20 21:15:28 +0300 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2022-07-20 21:35:13 +0300 |
commit | ebfa0043c96c7c7f645d0f96159bca988c873b6d (patch) | |
tree | 3324cb5f82a20050a790bdb42f78438a4e50093b /drivers/input/input-core-private.h | |
parent | 59b7a5af8e8c22b20fc68eca48d7cfdc92501c1e (diff) | |
download | linux-ebfa0043c96c7c7f645d0f96159bca988c873b6d.tar.xz |
Input: deactivate MT slots when inhibiting or suspending devices
When inhibiting or suspending a device we are sending release events for
all currently held keys and buttons, however we retain active MT slot
state, which causes issues with gesture recognition when we resume or
uninhibit.
Let's fix it by introducing, in addition to input_dev_release_keys(),
nput_mt_release_slots() that will deactivate all currently active slots.
Signed-off-by: Angela Czubak <acz@semihalf.com>
Link: https://lore.kernel.org/r/20220718151715.1052842-3-acz@semihalf.com
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/input-core-private.h')
-rw-r--r-- | drivers/input/input-core-private.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/input/input-core-private.h b/drivers/input/input-core-private.h new file mode 100644 index 000000000000..116834cf8868 --- /dev/null +++ b/drivers/input/input-core-private.h @@ -0,0 +1,16 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ +#ifndef _INPUT_CORE_PRIVATE_H +#define _INPUT_CORE_PRIVATE_H + +/* + * Functions and definitions that are private to input core, + * should not be used by input drivers or handlers. + */ + +struct input_dev; + +void input_mt_release_slots(struct input_dev *dev); +void input_handle_event(struct input_dev *dev, + unsigned int type, unsigned int code, int value); + +#endif /* _INPUT_CORE_PRIVATE_H */ |