diff options
author | Henrik Rydberg <rydberg@euromail.se> | 2010-07-16 02:10:10 -0400 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2010-07-16 02:52:03 -0400 |
commit | 40d007e7df1dab17bf1ecf91e718218354d963d7 (patch) | |
tree | d8c12e13e71f411b4f66aa44ec9b23935156e49d /drivers/input/evdev.c | |
parent | a8aef622929bbba4d89498fb41dd445c14fae1f7 (diff) |
Input: introduce MT event slots
With the rapidly increasing number of intelligent multi-contact and
multi-user devices, the need to send digested, filtered information
from a set of different sources within the same device is imminent.
This patch adds the concept of slots to the MT protocol. The slots
enumerate a set of identified sources, such that all MT events
can be passed independently and selectively per identified source.
The protocol works like this: Instead of sending a SYN_MT_REPORT
event immediately after the contact data, one sends an ABS_MT_SLOT
event immediately before the contact data. The input core will only
emit events for slots with modified MT events. It is assumed that
the same slot is used for the duration of an initiated contact.
Acked-by: Ping Cheng <pingc@wacom.com>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Rafi Rubin <rafi@seas.upenn.edu>
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input/evdev.c')
-rw-r--r-- | drivers/input/evdev.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c index cd323254ca6f..fc5afbd78625 100644 --- a/drivers/input/evdev.c +++ b/drivers/input/evdev.c | |||
@@ -686,6 +686,10 @@ static long evdev_do_ioctl(struct file *file, unsigned int cmd, | |||
686 | sizeof(struct input_absinfo)))) | 686 | sizeof(struct input_absinfo)))) |
687 | return -EFAULT; | 687 | return -EFAULT; |
688 | 688 | ||
689 | /* We can't change number of reserved MT slots */ | ||
690 | if (t == ABS_MT_SLOT) | ||
691 | return -EINVAL; | ||
692 | |||
689 | /* | 693 | /* |
690 | * Take event lock to ensure that we are not | 694 | * Take event lock to ensure that we are not |
691 | * changing device parameters in the middle | 695 | * changing device parameters in the middle |