Bug 334587

Summary: synaptics driver failing to find device after several suspend/resume cycles
Product: [openSUSE] openSUSE 10.3 Reporter: Ruediger Oertel <ro>
Component: X.OrgAssignee: Matthias Hopf <mhopf>
Status: RESOLVED FIXED QA Contact: E-mail List <xorg-maintainer-bugs>
Severity: Normal    
Priority: P5 - None CC: fazerxlo, martin.wilck, rs.opensuse, sndirsch
Version: Final   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Ruediger Oertel 2007-10-17 14:55:25 UTC
the device check in the driver has
-    const int max_skip = 10;

with this, the driver may not find the device, since every reload
(and possible also every resume) might increase the device number:
from dmesg:
--------------
input: appletouch as /class/input/input42
--------------

quick hack can be to increase max_skip to 50, but a real fix
should walk over the existing device nodes and not just walk
over /dev/input/event$NUM from 1...20 ...
Comment 1 Stefan Dirsch 2007-10-17 15:05:24 UTC
Matthias, can you look at this? Same applies to wacom driver I guess.
Comment 2 Stefan Dirsch 2007-10-18 18:14:37 UTC
*** Bug 331240 has been marked as a duplicate of this bug. ***
Comment 3 Stefan Dirsch 2007-10-23 14:04:04 UTC
*** Bug 336000 has been marked as a duplicate of this bug. ***
Comment 4 Martin Wilck 2007-10-26 00:24:31 UTC
On my Fujitsu Siemens Amilo Pro V3205, the synaptics device disappears after every Suspend-to-RAM/resume cycle.

It can be seen that the corresponding input device is missing from /proc/input/devices after the resume:

--- id.normal   2007-10-26 01:25:47.000000000 +0200
+++ id.after    2007-10-26 01:33:03.000000000 +0200
@@ -18,16 +18,6 @@
 B: EV=40001
 B: SND=6

-I: Bus=0011 Vendor=0002 Product=0007 Version=25b1
-N: Name="SynPS/2 Synaptics TouchPad"
-P: Phys=isa0060/serio1/input0
-S: Sysfs=/class/input/input2
-U: Uniq=
-H: Handlers=mouse0 event2
-B: EV=b
-B: KEY=6420 0 70000 0 0 0 0 0 0 0 0
-B: ABS=11000003
-
 I: Bus=0019 Vendor=0000 Product=0002 Version=0000
 N: Name="Power Button (FF)"
 P: Phys=LNXPWRBN/button/input0

Similar problems have been reported repeatedly:
   http://bugzilla.kernel.org/show_bug.cgi?id=7977
   https://bugs.launchpad.net/ubuntu/+source/linux-source-2.6.20/+bug/59867

The kernel.org bugzilla relates the problem to the following patch:

http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=5d57a6a55ec0bdcb952dbcd3f8ffcde8a3ee9413

This patch was lately reverted:
http://www.mail-archive.com/linux-acpi@vger.kernel.org/msg09329.html

There is no final clue if the patch helps, currently.

cat /proc/acpi/embedded_controller/EC0/info
gpe:                    0x17
ports:                  0x66, 0x62
use global lock:        no
Comment 5 Stefan Dirsch 2007-11-27 22:02:27 UTC
Thanks. The patch seems to have been applied to 2.6.24_rc2_git6 we currently use for STABLE/Factory. Let's assume it's fixed for openSUSE 11.0 and kernel-of-the-day. Please reopen if the problem still occurs with 
kernel >= 2.6.24_rc2_git6.
Comment 6 Martin Wilck 2007-11-28 12:10:07 UTC
I have tried the patch mentioned in the meantime (by just applying it to the 10.3 kernel sources), and it did NOT fix the problem. I'll check the 2.6.24 kernel nonetheless.