mbox series

[0/4] Simplify event handling logic in input core

Message ID 20240701060553.869989-1-dmitry.torokhov@gmail.com (mailing list archive)
Headers show
Series Simplify event handling logic in input core | expand

Message

Dmitry Torokhov July 1, 2024, 6:05 a.m. UTC
This series tries to untangle somewhat convoluted logic in the input
event processing in the input core by realizing that input handler can
be either a filter, or a handler that handles a single event at a time,
or a handler that can handle a sequence of events, but should not mix
the 3 behaviors in one handler. This allows us to reduce both filter
functionality and single-event handling functionality to batch handling
and have the main event handling path to only deal with
input_handle->events() batch method.

Dmitry Torokhov (4):
  Input: make sure input handlers define only one processing method
  Input: make events() method return number of events processed
  Input: simplify event handling logic
  Input: preallocate memory to hold event values

 drivers/input/evdev.c |   6 +-
 drivers/input/input.c | 210 +++++++++++++++++++++++++++---------------
 include/linux/input.h |   7 +-
 3 files changed, 146 insertions(+), 77 deletions(-)