Bug 1255

Summary: PS/2 mouse problem with KVM switch
Product: Drivers Reporter: Jiri J. Moudry (moudryj)
Component: Input DevicesAssignee: Dmitry Torokhov (dmitry.torokhov)
Status: REJECTED DUPLICATE    
Severity: normal CC: nacc, vojtech
Priority: P2    
Hardware: i386   
OS: Linux   
Kernel Version: 2.6.0-test5 Subsystem:
Regression: --- Bisected commit-id:

Description Jiri J. Moudry 2003-09-21 15:39:37 UTC
Distribution: Gentoo 1.4
Hardware Environment: ICS-124 KVM switch, Labtec optical wheel mouse
Software Environment: Linux k6-2 2.6.0-test5 #7 Sat Sep 20 19:47:13 PDT 2003
i586 AMD-K6(tm) 3D processor AuthenticAMD GNU/Linux
Gnu C                  3.2.3
Gnu make               3.80
util-linux             2.11z
mount                  2.11z
e2fsprogs              1.33
reiserfsprogs          3.6.8
Linux C Library        2.3.2
Dynamic linker (ldd)   2.3.2
Procps                 3.1.9
Net-tools              1.60
Kbd                    1.06
Sh-utils               2.0.15
Modules Loaded         usbcore tulip ide_tape st

Problem Description: The mouse works OK until I use the KVM switch. After coming
back, the mouse jumps all over the place. Restarting X does not help, I must
reboot. Using a kernel parameter psmouse_noext works, but I lose the wheel.
Windows 2000 works fine on this hardware. With kernel 2.4.22-ac1, restarting X
(Ctl-Alt-Backspace) always helps, and switching to a character console and back
(Ctl-Alt-F1/Ctl-Alt-F7) usually helps. Still a big nuisance. 

Can't we match Windows? I'll be glad to run any tests you suggest.

Steps to reproduce: Boot the computer in kernel 2.6.0-test5/KDE 3.1. The mouse
including the wheel works. Use the KVM switch to move away from this computer
and back again. The mouse now behaves weirdly. Always.

Here is a mouse section of /etc/X11/XF86Config:

Section "InputDevice"
	Identifier  "Mouse0"
	Driver      "mouse"
	Option	    "Protocol" "IMPS/2"
# XFree86 4.x PS/2 mouse protocols:
# Auto PS/2 IMPS/2 ExplorerPS/2 NetMousePS/2 NetScrollPS/2
# MouseManPlusPS/2 ThinkingMousePS/2
	Option	    "Device" "/dev/psaux"
	Option      "ZAxisMapping" "4 5"
	Option      "Emulate3Buttons" "true"
	Option	    "Emulate3Timeout" "70"
EndSection
Comment 1 Andreas Brosche 2003-12-23 12:13:11 UTC
I am experiencing similar problems with a Logitech TrackMan Marble Wheel plugged
into the PS/2 port via a "Digitus Connect KVM Switch DC IC-614-1". With the
switch, I can use the trackball's full capabilities, including the wheel, under
Linux 2.4.18 and Windoze 98, but under Linux 2.6.0, the wheel does not work. 

When the trackball is plugged in directly into the PS/2 port, the wheel also
works under 2.6.0. The correct protocol (PS2++) is loaded then. Plugging the
trackball back into the switch and connecting the switch with my running box
does not resolve the issue, however; everything still works - except for the
wheel. Seems that the KVM does not forward PS2++. 

Booting with the KVM loads the Logitech protocol (without parameter) or the
Generic protocol (with psmouse_noext). I tried Petr Baudis' patch to enforce the
loading of the ImPS/2 protocol, but with this patch the cursor crawls over the
screen, clicks wildly, and no real clicks are registered.
Comment 2 Andreas Brosche 2003-12-23 12:20:58 UTC
Whoa. I forgot to mention that the bug is actually present in the 2.6.0 (stable)
kernel.
Comment 3 Vojtech Pavlik 2004-02-01 02:46:29 UTC
This FAQ entry should help you (2.6.2-rc3 and later):

Problem:
~~~~~~~~

When I switch my KVM, my PS/2 mouse goes all crazy.

Solution:
~~~~~~~~~

Use psmouse.proto=bare on the kernel command line, or proto=bare on the
psmouse module command line.
Comment 4 dan marinescu 2004-02-26 21:38:54 UTC
if "solution" makes you loose your wheel functionality, try to send
"psmouse.proto=imps" to the kernel cli // this works 4me
Comment 5 dan marinescu 2004-02-26 21:42:52 UTC
can reproduce it with (relatively recent) 2.6.3 (stable)
it would be nice if someone tells major distros (@ least fedore and suse) about
that...

regds,
daniel
Comment 6 Peter Williams 2004-03-12 17:12:00 UTC
Following the advice to set psmouse.proto=imps solved the problem that I was
experiencing whereby a back scroll on the mouse wheel was being interpreted as a
right button press.  Thanks.
Comment 7 Mauro M. 2004-03-20 04:53:53 UTC
See a follow-up on bug 2082 (Mouse control lost when switching with KVM)
Comment 8 OLFarCnArt 2005-07-10 13:01:55 UTC
Mandriva Club Forum Index
<http://forum.mandrivaclub.com/viewtopic.php?t=38059>
Mandriva 10.1 doesn't work with KVM switch

Maximillium
Joined: 16 Feb 2004
Posts: 4


PostPosted: 10 Jul 2005 08:54
Post subject: Mandriva 10.1 doesn't work with KVM switch

My systems, using Windows 3.11, Windows 98SE, and Linux worked fine
accessing the keyboard and trackball through my IOGear KVM switch until
I upgraded from Mandrake Linux 9.2 to Mandriva 10.1.

Mandriva 10.1 worked fine after the initial install, but since that
initial install the cursor flies wildly all over the screen, selecting
everything it passes over.

The cursor is totally uncontrollable until the KVM switch is replaced
by a direct connection -- cutting me out of the other computers.  10.1
is unusable for me if want to switch between computers.

This is an issue under discussion on some other forums and is a problem
in other distributions as well.  Everything that uses over a certain
version of the Linux kernel is hiccuping on the KVM switch.

Here are a couple of pages where my KVM issues were discussed by others
with the same problem:

<http://forum.mandrivaclub.com/viewtopic.php?t=34115&highlight=kvm>

and

<http://forum.mandrivaclub.com/viewtopic.php?t=34115&postdays=0&postorder=asc&highlight=kvm&start=15>

or <http://ClubForumPage2.notlong.com> if the long link broke up.

The reference to a Kernel problem is in a couple of posts by "Area66",
one of which is on each page (links above).


Question: Is this situation being addressed, and will there be some
kind of "fix" soon, so I can avoid going back to Mandrake 9.2?  I am a
noobie and am dead in the water with a cursor that has gone crazy --
can't see anything much less know how to fix it.

Will there be a "software update" bugfix that could be downloaded and
installed while using the mouse connected directly?

-----------------------------------------------------------------------
Comment 9 Nishanth Aravamudan 2005-10-30 16:33:47 UTC
Is this still a problem for anyone? The last comment was in July.

Thanks,
Nish
Comment 10 Dmitry Torokhov 2005-12-21 22:10:24 UTC

*** This bug has been marked as a duplicate of 2082 ***