aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/mouse/alps.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/input/mouse/alps.c')
-rw-r--r--drivers/input/mouse/alps.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/input/mouse/alps.c b/drivers/input/mouse/alps.c
index 450b68a619fd..4e71a66fc7fc 100644
--- a/drivers/input/mouse/alps.c
+++ b/drivers/input/mouse/alps.c
@@ -76,7 +76,7 @@ static const struct alps_model_info alps_model_data[] = {
76 * on a dualpoint, etc. 76 * on a dualpoint, etc.
77 */ 77 */
78 78
79static void alps_process_packet(struct psmouse *psmouse, struct pt_regs *regs) 79static void alps_process_packet(struct psmouse *psmouse)
80{ 80{
81 struct alps_data *priv = psmouse->private; 81 struct alps_data *priv = psmouse->private;
82 unsigned char *packet = psmouse->packet; 82 unsigned char *packet = psmouse->packet;
@@ -85,8 +85,6 @@ static void alps_process_packet(struct psmouse *psmouse, struct pt_regs *regs)
85 int x, y, z, ges, fin, left, right, middle; 85 int x, y, z, ges, fin, left, right, middle;
86 int back = 0, forward = 0; 86 int back = 0, forward = 0;
87 87
88 input_regs(dev, regs);
89
90 if ((packet[0] & 0xc8) == 0x08) { /* 3-byte PS/2 packet */ 88 if ((packet[0] & 0xc8) == 0x08) { /* 3-byte PS/2 packet */
91 input_report_key(dev2, BTN_LEFT, packet[0] & 1); 89 input_report_key(dev2, BTN_LEFT, packet[0] & 1);
92 input_report_key(dev2, BTN_RIGHT, packet[0] & 2); 90 input_report_key(dev2, BTN_RIGHT, packet[0] & 2);
@@ -181,13 +179,13 @@ static void alps_process_packet(struct psmouse *psmouse, struct pt_regs *regs)
181 input_sync(dev); 179 input_sync(dev);
182} 180}
183 181
184static psmouse_ret_t alps_process_byte(struct psmouse *psmouse, struct pt_regs *regs) 182static psmouse_ret_t alps_process_byte(struct psmouse *psmouse)
185{ 183{
186 struct alps_data *priv = psmouse->private; 184 struct alps_data *priv = psmouse->private;
187 185
188 if ((psmouse->packet[0] & 0xc8) == 0x08) { /* PS/2 packet */ 186 if ((psmouse->packet[0] & 0xc8) == 0x08) { /* PS/2 packet */
189 if (psmouse->pktcnt == 3) { 187 if (psmouse->pktcnt == 3) {
190 alps_process_packet(psmouse, regs); 188 alps_process_packet(psmouse);
191 return PSMOUSE_FULL_PACKET; 189 return PSMOUSE_FULL_PACKET;
192 } 190 }
193 return PSMOUSE_GOOD_DATA; 191 return PSMOUSE_GOOD_DATA;
@@ -202,7 +200,7 @@ static psmouse_ret_t alps_process_byte(struct psmouse *psmouse, struct pt_regs *
202 return PSMOUSE_BAD_DATA; 200 return PSMOUSE_BAD_DATA;
203 201
204 if (psmouse->pktcnt == 6) { 202 if (psmouse->pktcnt == 6) {
205 alps_process_packet(psmouse, regs); 203 alps_process_packet(psmouse);
206 return PSMOUSE_FULL_PACKET; 204 return PSMOUSE_FULL_PACKET;
207 } 205 }
208 206