/[linux-patches]/genpatches-2.6/tags/3.0-8/2600_Input-ALPS-Move-protocol-information-to-Documentation.patch
Gentoo

Contents of /genpatches-2.6/tags/3.0-8/2600_Input-ALPS-Move-protocol-information-to-Documentation.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1988 - (show annotations) (download)
Tue Oct 4 07:39:33 2011 UTC (7 years, 2 months ago) by psomas
File size: 5315 byte(s)
3.0-8 release
1 From ffe7d2822d760868afc78e9c8239a77e913ed564 Mon Sep 17 00:00:00 2001
2 From: Seth Forshee <seth.forshee@canonical.com>
3 Date: Wed, 14 Sep 2011 11:40:37 -0500
4 Subject: [PATCH 1/8] Input: ALPS - Move protocol information to Documentation
5
6 In preparation for new protocol support, move the protocol
7 information currently documented in alps.c to
8 Documentation/input/alps.txt, where it can be expanded without
9 cluttering up the driver.
10 ---
11 Documentation/input/alps.txt | 75 ++++++++++++++++++++++++++++++++++++++++++
12 drivers/input/mouse/alps.c | 37 +--------------------
13 2 files changed, 76 insertions(+), 36 deletions(-)
14 create mode 100644 Documentation/input/alps.txt
15
16 diff --git a/Documentation/input/alps.txt b/Documentation/input/alps.txt
17 new file mode 100644
18 index 0000000..e88c921
19 --- /dev/null
20 +++ b/Documentation/input/alps.txt
21 @@ -0,0 +1,75 @@
22 +ALPS Touchpad Protocol
23 +----------------------
24 +
25 +Introduction
26 +------------
27 +
28 +Currently the ALPS touchpad driver supports two protocol versions in use by
29 +ALPS touchpads, the "old" and "new" protocol versions. Fundamentally these
30 +differ only in the format of their event packets (in reality many features may
31 +be found on new protocol devices that aren't found on the old protocol
32 +devices, but these are handled transparently as feature differences rather
33 +than protocol differences).
34 +
35 +Detection
36 +---------
37 +
38 +All ALPS touchpads should respond to the "E6 report" command sequence:
39 +E8-E6-E6-E6-E9. An ALPS touchpad should respond with either 00-00-0A or
40 +00-00-64.
41 +
42 +If the E6 report is successful, the touchpad model is identified using the "E7
43 +report" sequence: E8-E7-E7-E7-E9. The response is the model signature and is
44 +matched against known models in the alps_model_data_array.
45 +
46 +Packet Format
47 +-------------
48 +
49 +In the following tables, the following notation us used.
50 +
51 + CAPITALS = stick, miniscules = touchpad
52 +
53 +?'s can have different meanings on different models, such as wheel rotation,
54 +extra buttons, stick buttons on a dualpoint, etc.
55 +
56 +PS/2 packet format
57 +------------------
58 +
59 + byte 0: 0 0 YSGN XSGN 1 M R L
60 + byte 1: X7 X6 X5 X4 X3 X2 X1 X0
61 + byte 2: Y7 Y6 Y5 Y4 Y3 Y2 Y1 Y0
62 +
63 +Note that the device never signals overflow condition.
64 +
65 +ALPS Absolute Mode - Old Format
66 +-------------------------------
67 +
68 + byte 0: 1 0 0 0 1 x9 x8 x7
69 + byte 1: 0 x6 x5 x4 x3 x2 x1 x0
70 + byte 2: 0 ? ? l r ? fin ges
71 + byte 3: 0 ? ? ? ? y9 y8 y7
72 + byte 4: 0 y6 y5 y4 y3 y2 y1 y0
73 + byte 5: 0 z6 z5 z4 z3 z2 z1 z0
74 +
75 +ALPS Absolute Mode - New Format
76 +-------------------------------
77 +
78 + byte 0: 1 ? ? ? 1 ? ? ?
79 + byte 1: 0 x6 x5 x4 x3 x2 x1 x0
80 + byte 2: 0 x10 x9 x8 x7 ? fin ges
81 + byte 3: 0 y9 y8 y7 1 M R L
82 + byte 4: 0 y6 y5 y4 y3 y2 y1 y0
83 + byte 5: 0 z6 z5 z4 z3 z2 z1 z0
84 +
85 +Dualpoint device -- interleaved packet format
86 +---------------------------------------------
87 +
88 + byte 0: 1 1 0 0 1 1 1 1
89 + byte 1: 0 x6 x5 x4 x3 x2 x1 x0
90 + byte 2: 0 x10 x9 x8 x7 0 fin ges
91 + byte 3: 0 0 YSGN XSGN 1 1 1 1
92 + byte 4: X7 X6 X5 X4 X3 X2 X1 X0
93 + byte 5: Y7 Y6 Y5 Y4 Y3 Y2 Y1 Y0
94 + byte 6: 0 y9 y8 y7 1 m r l
95 + byte 7: 0 y6 y5 y4 y3 y2 y1 y0
96 + byte 8: 0 z6 z5 z4 z3 z2 z1 z0
97 diff --git a/drivers/input/mouse/alps.c b/drivers/input/mouse/alps.c
98 index 99d5876..ad15e7c 100644
99 --- a/drivers/input/mouse/alps.c
100 +++ b/drivers/input/mouse/alps.c
101 @@ -74,42 +74,7 @@ static const struct alps_model_info alps_model_data[] = {
102 * isn't valid per PS/2 spec.
103 */
104
105 -/*
106 - * PS/2 packet format
107 - *
108 - * byte 0: 0 0 YSGN XSGN 1 M R L
109 - * byte 1: X7 X6 X5 X4 X3 X2 X1 X0
110 - * byte 2: Y7 Y6 Y5 Y4 Y3 Y2 Y1 Y0
111 - *
112 - * Note that the device never signals overflow condition.
113 - *
114 - * ALPS absolute Mode - new format
115 - *
116 - * byte 0: 1 ? ? ? 1 ? ? ?
117 - * byte 1: 0 x6 x5 x4 x3 x2 x1 x0
118 - * byte 2: 0 x10 x9 x8 x7 ? fin ges
119 - * byte 3: 0 y9 y8 y7 1 M R L
120 - * byte 4: 0 y6 y5 y4 y3 y2 y1 y0
121 - * byte 5: 0 z6 z5 z4 z3 z2 z1 z0
122 - *
123 - * Dualpoint device -- interleaved packet format
124 - *
125 - * byte 0: 1 1 0 0 1 1 1 1
126 - * byte 1: 0 x6 x5 x4 x3 x2 x1 x0
127 - * byte 2: 0 x10 x9 x8 x7 0 fin ges
128 - * byte 3: 0 0 YSGN XSGN 1 1 1 1
129 - * byte 4: X7 X6 X5 X4 X3 X2 X1 X0
130 - * byte 5: Y7 Y6 Y5 Y4 Y3 Y2 Y1 Y0
131 - * byte 6: 0 y9 y8 y7 1 m r l
132 - * byte 7: 0 y6 y5 y4 y3 y2 y1 y0
133 - * byte 8: 0 z6 z5 z4 z3 z2 z1 z0
134 - *
135 - * CAPITALS = stick, miniscules = touchpad
136 - *
137 - * ?'s can have different meanings on different models,
138 - * such as wheel rotation, extra buttons, stick buttons
139 - * on a dualpoint, etc.
140 - */
141 +/* Packet formats are described in Documentation/input/alps.txt */
142
143 static bool alps_is_valid_first_byte(const struct alps_model_info *model,
144 unsigned char data)
145 --
146 1.7.4.1
147

  ViewVC Help
Powered by ViewVC 1.1.20