diff options
Diffstat (limited to 'drivers/input/mouse/psmouse-base.c')
-rw-r--r-- | drivers/input/mouse/psmouse-base.c | 34 |
1 files changed, 28 insertions, 6 deletions
diff --git a/drivers/input/mouse/psmouse-base.c b/drivers/input/mouse/psmouse-base.c index a0e4a033e2db..0fe5869d7d4c 100644 --- a/drivers/input/mouse/psmouse-base.c +++ b/drivers/input/mouse/psmouse-base.c | |||
@@ -93,12 +93,6 @@ static struct attribute_group psmouse_attribute_group = { | |||
93 | .attrs = psmouse_attributes, | 93 | .attrs = psmouse_attributes, |
94 | }; | 94 | }; |
95 | 95 | ||
96 | __obsolete_setup("psmouse_noext"); | ||
97 | __obsolete_setup("psmouse_resolution="); | ||
98 | __obsolete_setup("psmouse_smartscroll="); | ||
99 | __obsolete_setup("psmouse_resetafter="); | ||
100 | __obsolete_setup("psmouse_rate="); | ||
101 | |||
102 | /* | 96 | /* |
103 | * psmouse_mutex protects all operations changing state of mouse | 97 | * psmouse_mutex protects all operations changing state of mouse |
104 | * (connecting, disconnecting, changing rate or resolution via | 98 | * (connecting, disconnecting, changing rate or resolution via |
@@ -987,8 +981,36 @@ static void psmouse_resync(struct work_struct *work) | |||
987 | static void psmouse_cleanup(struct serio *serio) | 981 | static void psmouse_cleanup(struct serio *serio) |
988 | { | 982 | { |
989 | struct psmouse *psmouse = serio_get_drvdata(serio); | 983 | struct psmouse *psmouse = serio_get_drvdata(serio); |
984 | struct psmouse *parent = NULL; | ||
985 | |||
986 | mutex_lock(&psmouse_mutex); | ||
987 | |||
988 | if (serio->parent && serio->id.type == SERIO_PS_PSTHRU) { | ||
989 | parent = serio_get_drvdata(serio->parent); | ||
990 | psmouse_deactivate(parent); | ||
991 | } | ||
992 | |||
993 | psmouse_deactivate(psmouse); | ||
994 | |||
995 | if (psmouse->cleanup) | ||
996 | psmouse->cleanup(psmouse); | ||
990 | 997 | ||
991 | psmouse_reset(psmouse); | 998 | psmouse_reset(psmouse); |
999 | |||
1000 | /* | ||
1001 | * Some boxes, such as HP nx7400, get terribly confused if mouse | ||
1002 | * is not fully enabled before suspending/shutting down. | ||
1003 | */ | ||
1004 | ps2_command(&psmouse->ps2dev, NULL, PSMOUSE_CMD_ENABLE); | ||
1005 | |||
1006 | if (parent) { | ||
1007 | if (parent->pt_deactivate) | ||
1008 | parent->pt_deactivate(parent); | ||
1009 | |||
1010 | psmouse_activate(parent); | ||
1011 | } | ||
1012 | |||
1013 | mutex_unlock(&psmouse_mutex); | ||
992 | } | 1014 | } |
993 | 1015 | ||
994 | /* | 1016 | /* |