Skip to content

Commit

Permalink
Input: sparse-keymap - send sync event for KE_SW/KE_VSW
Browse files Browse the repository at this point in the history
Sync events are sent by sparse_keymap_report_entry for normal KEY_*
events, and are generated by several drivers after generating
SW_* events, so sparse_keymap_report_entry should do the same.

Without the sync, events are accumulated in the kernel.

Currently, no driver uses sparse-keymap for SW_* events, but
it is required for the intel-vbtn platform driver to generate
SW_TABLET_MODE events.

Signed-off-by: Stefan Brüns <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
  • Loading branch information
StefanBruens authored and dtor committed Nov 3, 2017
1 parent 53f0b7f commit 6f29c24
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/input/sparse-keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,7 @@ void sparse_keymap_report_entry(struct input_dev *dev, const struct key_entry *k

case KE_VSW:
input_report_switch(dev, ke->sw.code, value);
input_sync(dev);
break;
}
}
Expand Down

0 comments on commit 6f29c24

Please sign in to comment.