Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 232578
b: refs/heads/master
c: c63fe0a
h: refs/heads/master
v: v3
  • Loading branch information
Alexandre Peixoto Ferreira authored and Dmitry Torokhov committed Jan 29, 2011
1 parent f67ae09 commit 512b300
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: baddf58963241307b29e027a9fb28dfe55939db8
refs/heads/master: c63fe0a41fd2374be0ebe93c053820a0eed9cefe
13 changes: 11 additions & 2 deletions trunk/drivers/input/mouse/synaptics.c
Original file line number Diff line number Diff line change
Expand Up @@ -755,12 +755,21 @@ static int synaptics_reconnect(struct psmouse *psmouse)
{
struct synaptics_data *priv = psmouse->private;
struct synaptics_data old_priv = *priv;
int retry = 0;
int error;

psmouse_reset(psmouse);
do {
psmouse_reset(psmouse);
error = synaptics_detect(psmouse, 0);
} while (error && ++retry < 3);

if (synaptics_detect(psmouse, 0))
if (error)
return -1;

if (retry > 1)
printk(KERN_DEBUG "Synaptics reconnected after %d tries\n",
retry);

if (synaptics_query_hardware(psmouse)) {
printk(KERN_ERR "Unable to query Synaptics hardware.\n");
return -1;
Expand Down

0 comments on commit 512b300

Please sign in to comment.