platform/x86: peaq-wmi: switch to using polled mode of input devices
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Tue, 1 Oct 2019 18:58:22 +0000 (11:58 -0700)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Tue, 15 Oct 2019 07:55:09 +0000 (10:55 +0300)
commit60d15095336cfb56dce5c7767ed3b8c6c1cf79a3
tree2ebfbc537b36c1df401225181734c4a06f7886b1
parent83dbbe5ae47f163df05f13cbb619841ab2cca05e
platform/x86: peaq-wmi: switch to using polled mode of input devices

We have added polled mode to the normal input devices with the intent of
retiring input_polled_dev. This converts peaq-wmi driver to use the
polling mode of standard input devices and removes dependency on
INPUT_POLLDEV.

Because the new polling coded does not allow peeking inside the poller
structure to get the poll interval, we change the "debounce" process to
operate on the time basis, instead of counting events.

We also fix error handling during initialization, as previously we leaked
input device structure when we failed to register it.

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Tested-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
drivers/platform/x86/Kconfig
drivers/platform/x86/peaq-wmi.c