aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/input/sparse-keymap.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/input/sparse-keymap.c b/drivers/input/sparse-keymap.c
index 337bf51bc984..74bca5d2f6dc 100644
--- a/drivers/input/sparse-keymap.c
+++ b/drivers/input/sparse-keymap.c
@@ -208,6 +208,11 @@ int sparse_keymap_setup(struct input_dev *dev,
208 } 208 }
209 } 209 }
210 210
211 if (test_bit(EV_KEY, dev->evbit)) {
212 __set_bit(EV_MSC, dev->evbit);
213 __set_bit(MSC_SCAN, dev->mscbit);
214 }
215
211 dev->keycode = map; 216 dev->keycode = map;
212 dev->keycodemax = map_size; 217 dev->keycodemax = map_size;
213 dev->getkeycode = sparse_keymap_getkeycode; 218 dev->getkeycode = sparse_keymap_getkeycode;
@@ -268,6 +273,7 @@ void sparse_keymap_report_entry(struct input_dev *dev, const struct key_entry *k
268{ 273{
269 switch (ke->type) { 274 switch (ke->type) {
270 case KE_KEY: 275 case KE_KEY:
276 input_event(dev, EV_MSC, MSC_SCAN, ke->code);
271 input_report_key(dev, ke->keycode, value); 277 input_report_key(dev, ke->keycode, value);
272 input_sync(dev); 278 input_sync(dev);
273 if (value && autorelease) { 279 if (value && autorelease) {