]> git.baikalelectronics.ru Git - kernel.git/commit
Input: add support for polling to input devices
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Wed, 19 Apr 2017 00:28:30 +0000 (17:28 -0700)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Tue, 20 Aug 2019 19:04:07 +0000 (12:04 -0700)
commit6e1867fc394beeea94879b74539737fa54347a80
tree0470cd10f6a489669c8a8ac5a99526ead4257e4f
parent80d27e382bf6eaa824c467bcc0ed0da651dbaceb
Input: add support for polling to input devices

Separating "normal" and "polled" input devices was a mistake, as often we
want to allow the very same device work on both interrupt-driven and
polled mode, depending on the board on which the device is used.

This introduces new APIs:

- input_setup_polling
- input_set_poll_interval
- input_set_min_poll_interval
- input_set_max_poll_interval

These new APIs allow switching an input device into polled mode with sysfs
attributes matching drivers using input_polled_dev APIs that will be
eventually removed.

Tested-by: Michal Vokáč <michal.vokac@ysoft.com>
Acked-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/Makefile
drivers/input/input-poller.c [new file with mode: 0644]
drivers/input/input-poller.h [new file with mode: 0644]
drivers/input/input.c
include/linux/input.h