]> git.baikalelectronics.ru Git - kernel.git/commit
Input: psmouse - fix Synaptics detection when protocol is disabled
authorDaniel Drake <dsd@laptop.org>
Thu, 7 Jan 2010 09:52:39 +0000 (01:52 -0800)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Thu, 7 Jan 2010 09:53:30 +0000 (01:53 -0800)
commitb508a01375526fcfe22c821d0fd53d42c0eecb6e
tree26bef82f6bafcbd824cac6cd5896241cb2527e66
parent53bd7766a172db41872aef8c055c041ef83a4046
Input: psmouse - fix Synaptics detection when protocol is disabled

For configurations where Synaptics hardware is present but the Synaptics
extensions support is not compiled in, the mouse is reprobed and a new
device is allocated on every suspend/resume.

During probe, psmouse_switch_protocol() calls psmouse_extensions() with
set_properties=1. This calls the dummy synaptics_init() which returns an
error code, instructing us not to use the synaptics extensions.

During resume, psmouse_reconnect() calls psmouse_extensions() with
set_properties=0, in which case call to synaptics_init() is bypassed and
PSMOUSE_SYNAPTICS is returned. Since the result is different from previous
attempt psmouse_reconnect() fails and full re-probe happens.

Fix this by tweaking the set_properties=0 codepath in psmouse_extensions()
to be more careful about offering PSMOUSE_SYNAPTICS extensions.

Signed-off-by: Daniel Drake <dsd@laptop.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
drivers/input/mouse/psmouse-base.c
drivers/input/mouse/synaptics.c
drivers/input/mouse/synaptics.h