diff options
author | Tudor Florea <tudor.florea@enea.com> | 2014-10-16 02:06:17 +0200 |
---|---|---|
committer | Tudor Florea <tudor.florea@enea.com> | 2014-10-16 02:06:17 +0200 |
commit | 54eecdabe0cdfdc47d77b3e182fda5899702ded7 (patch) | |
tree | 8e28d750773f0aa38f0d2de83109b190faf0b425 /recipes-kernel/linux/linux-cubox-i-3.0.35/0005-ENGR00271359-Add-Multi-touch-support.patch | |
download | meta-fsl-arm-extra-54eecdabe0cdfdc47d77b3e182fda5899702ded7.tar.gz |
initial commit for Enea Linux 4.0-140929daisy-140929
Migrated from the internal git server on the daisy-enea-point-release branch
Signed-off-by: Tudor Florea <tudor.florea@enea.com>
Diffstat (limited to 'recipes-kernel/linux/linux-cubox-i-3.0.35/0005-ENGR00271359-Add-Multi-touch-support.patch')
-rw-r--r-- | recipes-kernel/linux/linux-cubox-i-3.0.35/0005-ENGR00271359-Add-Multi-touch-support.patch | 98 |
1 files changed, 98 insertions, 0 deletions
diff --git a/recipes-kernel/linux/linux-cubox-i-3.0.35/0005-ENGR00271359-Add-Multi-touch-support.patch b/recipes-kernel/linux/linux-cubox-i-3.0.35/0005-ENGR00271359-Add-Multi-touch-support.patch new file mode 100644 index 0000000..cb20198 --- /dev/null +++ b/recipes-kernel/linux/linux-cubox-i-3.0.35/0005-ENGR00271359-Add-Multi-touch-support.patch | |||
@@ -0,0 +1,98 @@ | |||
1 | From 538f4bb2f7a51f267395550a5be9f0ab2e426712 Mon Sep 17 00:00:00 2001 | ||
2 | From: Erik Boto <erik.boto@pelagicore.com> | ||
3 | Date: Tue, 16 Jul 2013 12:06:05 -0500 | ||
4 | Subject: [PATCH] ENGR00271359 Add Multi-touch support | ||
5 | Organization: O.S. Systems Software LTDA. | ||
6 | |||
7 | The previous behavior of the driver did not work properly with Qt5 | ||
8 | QtQuick multi touch-point gestures, due to how touch-points are | ||
9 | reported when removing a touch-point. My interpretation of the | ||
10 | available documentation [1] was that the driver should report all | ||
11 | touch-points between SYN_REPORTs, but it is not explicitly stated so. | ||
12 | I've found another mail-thread [2] where the creator of the protocol | ||
13 | states: | ||
14 | |||
15 | "The protocol defines a generic way of sending a variable amount of | ||
16 | contacts. The contact count is obtained by counting the number of | ||
17 | non-empty finger packets between SYN_REPORT events."-Henrik Rydberg | ||
18 | |||
19 | I think this verifies my assumption that all touch-points should be | ||
20 | reported between SYN_REPORTs, otherwise it can not be used to obtain | ||
21 | the count. | ||
22 | |||
23 | [1] https://www.kernel.org/doc/Documentation/input/multi-touch-protocol.txt | ||
24 | [2] http://lists.x.org/archives/xorg-devel/2010-March/006466.html | ||
25 | |||
26 | Upstream-Status: Pending | ||
27 | |||
28 | Signed-off-by: Erik Boto <erik.boto@pelagicore.com> | ||
29 | Signed-off-by: Mahesh Mahadevan <Mahesh.Mahadevan@freescale.com> | ||
30 | (cherry picked from commit 7cba001c5a502680f6dbf902821726779a9c9287) | ||
31 | --- | ||
32 | drivers/input/touchscreen/egalax_ts.c | 36 +++++++++++++++++------------------ | ||
33 | 1 file changed, 18 insertions(+), 18 deletions(-) | ||
34 | |||
35 | diff --git a/drivers/input/touchscreen/egalax_ts.c b/drivers/input/touchscreen/egalax_ts.c | ||
36 | index 0b6cde7..271f820 100644 | ||
37 | --- a/drivers/input/touchscreen/egalax_ts.c | ||
38 | +++ b/drivers/input/touchscreen/egalax_ts.c | ||
39 | @@ -133,7 +133,6 @@ retry: | ||
40 | } | ||
41 | |||
42 | if (down) { | ||
43 | - /* should also report old pointers */ | ||
44 | events[id].valid = valid; | ||
45 | events[id].status = down; | ||
46 | events[id].x = x; | ||
47 | @@ -144,23 +143,6 @@ retry: | ||
48 | input_report_abs(input_dev, ABS_Y, y); | ||
49 | input_event(data->input_dev, EV_KEY, BTN_TOUCH, 1); | ||
50 | input_report_abs(input_dev, ABS_PRESSURE, 1); | ||
51 | -#else | ||
52 | - for (i = 0; i < MAX_SUPPORT_POINTS; i++) { | ||
53 | - if (!events[i].valid) | ||
54 | - continue; | ||
55 | - dev_dbg(&client->dev, "report id:%d valid:%d x:%d y:%d", | ||
56 | - i, valid, x, y); | ||
57 | - | ||
58 | - input_report_abs(input_dev, | ||
59 | - ABS_MT_TRACKING_ID, i); | ||
60 | - input_report_abs(input_dev, | ||
61 | - ABS_MT_TOUCH_MAJOR, 1); | ||
62 | - input_report_abs(input_dev, | ||
63 | - ABS_MT_POSITION_X, events[i].x); | ||
64 | - input_report_abs(input_dev, | ||
65 | - ABS_MT_POSITION_Y, events[i].y); | ||
66 | - input_mt_sync(input_dev); | ||
67 | - } | ||
68 | #endif | ||
69 | } else { | ||
70 | dev_dbg(&client->dev, "release id:%d\n", id); | ||
71 | @@ -176,6 +158,24 @@ retry: | ||
72 | #endif | ||
73 | } | ||
74 | |||
75 | +#ifndef CONFIG_TOUCHSCREEN_EGALAX_SINGLE_TOUCH | ||
76 | + /* report all pointers */ | ||
77 | + for (i = 0; i < MAX_SUPPORT_POINTS; i++) { | ||
78 | + if (!events[i].valid) | ||
79 | + continue; | ||
80 | + dev_dbg(&client->dev, "report id:%d valid:%d x:%d y:%d", | ||
81 | + i, valid, x, y); | ||
82 | + input_report_abs(input_dev, | ||
83 | + ABS_MT_TRACKING_ID, i); | ||
84 | + input_report_abs(input_dev, | ||
85 | + ABS_MT_TOUCH_MAJOR, 1); | ||
86 | + input_report_abs(input_dev, | ||
87 | + ABS_MT_POSITION_X, events[i].x); | ||
88 | + input_report_abs(input_dev, | ||
89 | + ABS_MT_POSITION_Y, events[i].y); | ||
90 | + input_mt_sync(input_dev); | ||
91 | + } | ||
92 | +#endif | ||
93 | input_sync(input_dev); | ||
94 | return IRQ_HANDLED; | ||
95 | } | ||
96 | -- | ||
97 | 1.8.4.rc3 | ||
98 | |||