How to get a KVM operating in absolute mouse mode though legacy mouse support is needed.
by jschlinker from LinuxQuestions.org on (#6KJQE)
One of my customers has a Linux system with the following details:
Suse Linux 15
I plugged in a KVM-over-IP device from Raritan (DKX4-101) which introduces a USB-device with Keyboard + mouse in absolute mouse mode.
It's essential that the absolute mouse mode is used.
I can steer the system through the KVM, but the mouse is behaving as if it was in relative mouse mode.
I am 100% confident that the KVM is sending absolute mouse coordinates.
I found a [description][1] that there is a legacy mouse-driver in Linux (mousedev) which makes legacy application use a ps2-style interface via /dev/input/mice and which can also translate mice using absolute mouse coordinates to relative coordinates.
So I guess that the KVM's absolute mouse is not used directly by the application, but it's "piped/translated" through the legacy mousedev-interface which is ps2-based and doesn't support absolute mouse mode.
What I am now trying to achieve is that on this system I can use the local mouse with the mousedev and the KVM uses a "regular" driver which supports absolute mouse mode. I want to keep the mousedev approach as my customer tells me that I shouldn't change anything (if possible) on the system. If I change something it should just introduce something for the KVM and should not change ANYTHING e.g. regarding used drivers for existing devices.
So I guess my questions are:
1. Is this even possible?
2. Would a change in xorg.conf be able to achieve this?
Thanks in advance for your help.
I attach all the relevant config-files/logs that I could find below.
J.
Here are the udev mouse-rules:
Code:# serial ps/2 mouse
KERNELS=="input*", SUBSYSTEMS=="input", ATTRS(name)=="PS/2 Logitech Mouse", ATTRS(phys)=="isa0060/serio1/input0", SYMLINK+="input/pmouse0", MODE="0660", RUN="/usr/bin/killall -10 X"
# usb mouse
KERNELS=="mouse*", SUBSYSTEM=="input", ATTRS(name)=="USB*Mouse*", MODE="0660", SYMLINK="input/pmouse0", RUN="/usr/bin/killall -10 X"
And here the more generic evdev udev rules
Code:Section "InputClass"
Identifier "evdev pointer catchall"
MatchIsPointer "on"
MatchDevicePath "/dev/input/event*"
Driver "evdev"
EndSection
Section "InputClass"
Identifier "evdev tablet catchall"
MatchIsTablet "on"
MatchDevicePath "/dev/input/event*"
Driver "evdev"
EndSection
And here the more generic libinput udev rules
Code:Section "InputClass"
Identifier "libinput pointer catchall"
MatchIsPointer "on"
MatchDevicePath "/dev/input/event*"
Driver "libinput"
EndSection
Section "InputClass"
Identifier "libinput tablet catchall"
MatchIsTablet "on"
MatchDevicePath "/dev/input/event*"
Driver "libinput"
EndSectionIn the xorg.conf I found this
Code:...
Section "ServerLayout"
Identifier "NVidia"
Screen "Screen0"
InputDevice "Mouse0" "CorePointer"
InputDevice "Keyboard0" "CoreKeyboard"
EndSection
Section "ServerFlags"
Option "AutoAddDevices" "false"
Option "AutoEnableDevices" "true"
Option "AllowEmptyInput" "false"
EndSection
...
Section "InputDevice"
Identifier "Mouse0"
Driver "mouse"
Option "Protocol" "explorerps/2"
Option "Device" "/dev/input/mice"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "no"
EndSection
When I run xinput list the mouse from the KVM device does not show up
Code:Virtual core pointer
Virtual core XTEST pointer
Mouse0
Virtual core keygoard
Virtual core XTEST keyboard
Keyboard0
When I run lsusb I see the two local devices (keyboard+mouse) + the KVM:
Code:lsusb
...
BUS 001 Device 012: ID 03f0:034a HP, Inc Elite Keyboard
BUS 001 Device 010: ID 03f0:134a HP, Inc Optical Mouse
Bus 002 Device 014: ID 14dd:1010 Raritan Computer, Inc. KX4-101
...In the boot.msg I see how the device is registered
Code:input: Raritan KX4-101 as /devices/pci0000:00/0000:00:14,0/usb1/1-6/6:1.0/0003:1400:1010.0001/input/input1
hid-generic: 0003:1400:1010.0001: input.hidraw0: USB HID v1.01 Keyboard [Raritan KX4-101] on usb-0000:00:14.0-6/input0
input: Raritan KX4-101 as /devices/pci0000:00/0000:00:14,0/usb1/1-6/6:1.0/0003:1400:1010.0002/input/input2
hid-generic: 0003:1400:1010.0002: input.hidraw1: USB HID v1.01 Mouse [Raritan KX4-101] on usb-0000:00:14.0-6/input1In the xorg.log I found the following:
Code:(II) config/udev: Adding input device Raritan KX4-101 (/dev/input/mouse0)
(II) AutoAddDevices is off - not adding device.
(II) config/udev: Adding input device Raritan KX4-101 (/dev/input/event1)
(II) AutoAddDevices is off - not adding device.
...
(II) LoadModule: "mouse"
(II) Loading /usr/lib64/xorg/modules/input/mouse_drv.so
(II) Module mouse: vendor="X.Org Foundation"
compiled for 1.20.3, module version = 1.9.2
Module class: X.Org XInput Driver
ABI class: X.Org XInput driver, version 24.1
...
(II)Using input driver 'mouse' for 'Mouse1'
(**) Option "CorePointer"
(**) Mouse1: always reports core events
(**) Option "Protocol" "PS/2"
(**) Option "Device" "/dev/input/In the /dev/input I find a lot of events and at the end
Code:... input 13 ... mice
... input 13 ... mouse0
... input 13 ... mouse1
... input 13 ... mouse2
... input 13 ... mouse3
... input 13 ... mouse4
... root ... pmouse0 -> mouse3
[1]: https://askubuntu.com/questions/1043...dev-input-mice
Suse Linux 15
I plugged in a KVM-over-IP device from Raritan (DKX4-101) which introduces a USB-device with Keyboard + mouse in absolute mouse mode.
It's essential that the absolute mouse mode is used.
I can steer the system through the KVM, but the mouse is behaving as if it was in relative mouse mode.
I am 100% confident that the KVM is sending absolute mouse coordinates.
I found a [description][1] that there is a legacy mouse-driver in Linux (mousedev) which makes legacy application use a ps2-style interface via /dev/input/mice and which can also translate mice using absolute mouse coordinates to relative coordinates.
So I guess that the KVM's absolute mouse is not used directly by the application, but it's "piped/translated" through the legacy mousedev-interface which is ps2-based and doesn't support absolute mouse mode.
What I am now trying to achieve is that on this system I can use the local mouse with the mousedev and the KVM uses a "regular" driver which supports absolute mouse mode. I want to keep the mousedev approach as my customer tells me that I shouldn't change anything (if possible) on the system. If I change something it should just introduce something for the KVM and should not change ANYTHING e.g. regarding used drivers for existing devices.
So I guess my questions are:
1. Is this even possible?
2. Would a change in xorg.conf be able to achieve this?
Thanks in advance for your help.
I attach all the relevant config-files/logs that I could find below.
J.
Here are the udev mouse-rules:
Code:# serial ps/2 mouse
KERNELS=="input*", SUBSYSTEMS=="input", ATTRS(name)=="PS/2 Logitech Mouse", ATTRS(phys)=="isa0060/serio1/input0", SYMLINK+="input/pmouse0", MODE="0660", RUN="/usr/bin/killall -10 X"
# usb mouse
KERNELS=="mouse*", SUBSYSTEM=="input", ATTRS(name)=="USB*Mouse*", MODE="0660", SYMLINK="input/pmouse0", RUN="/usr/bin/killall -10 X"
And here the more generic evdev udev rules
Code:Section "InputClass"
Identifier "evdev pointer catchall"
MatchIsPointer "on"
MatchDevicePath "/dev/input/event*"
Driver "evdev"
EndSection
Section "InputClass"
Identifier "evdev tablet catchall"
MatchIsTablet "on"
MatchDevicePath "/dev/input/event*"
Driver "evdev"
EndSection
And here the more generic libinput udev rules
Code:Section "InputClass"
Identifier "libinput pointer catchall"
MatchIsPointer "on"
MatchDevicePath "/dev/input/event*"
Driver "libinput"
EndSection
Section "InputClass"
Identifier "libinput tablet catchall"
MatchIsTablet "on"
MatchDevicePath "/dev/input/event*"
Driver "libinput"
EndSectionIn the xorg.conf I found this
Code:...
Section "ServerLayout"
Identifier "NVidia"
Screen "Screen0"
InputDevice "Mouse0" "CorePointer"
InputDevice "Keyboard0" "CoreKeyboard"
EndSection
Section "ServerFlags"
Option "AutoAddDevices" "false"
Option "AutoEnableDevices" "true"
Option "AllowEmptyInput" "false"
EndSection
...
Section "InputDevice"
Identifier "Mouse0"
Driver "mouse"
Option "Protocol" "explorerps/2"
Option "Device" "/dev/input/mice"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "no"
EndSection
When I run xinput list the mouse from the KVM device does not show up
Code:Virtual core pointer
Virtual core XTEST pointer
Mouse0
Virtual core keygoard
Virtual core XTEST keyboard
Keyboard0
When I run lsusb I see the two local devices (keyboard+mouse) + the KVM:
Code:lsusb
...
BUS 001 Device 012: ID 03f0:034a HP, Inc Elite Keyboard
BUS 001 Device 010: ID 03f0:134a HP, Inc Optical Mouse
Bus 002 Device 014: ID 14dd:1010 Raritan Computer, Inc. KX4-101
...In the boot.msg I see how the device is registered
Code:input: Raritan KX4-101 as /devices/pci0000:00/0000:00:14,0/usb1/1-6/6:1.0/0003:1400:1010.0001/input/input1
hid-generic: 0003:1400:1010.0001: input.hidraw0: USB HID v1.01 Keyboard [Raritan KX4-101] on usb-0000:00:14.0-6/input0
input: Raritan KX4-101 as /devices/pci0000:00/0000:00:14,0/usb1/1-6/6:1.0/0003:1400:1010.0002/input/input2
hid-generic: 0003:1400:1010.0002: input.hidraw1: USB HID v1.01 Mouse [Raritan KX4-101] on usb-0000:00:14.0-6/input1In the xorg.log I found the following:
Code:(II) config/udev: Adding input device Raritan KX4-101 (/dev/input/mouse0)
(II) AutoAddDevices is off - not adding device.
(II) config/udev: Adding input device Raritan KX4-101 (/dev/input/event1)
(II) AutoAddDevices is off - not adding device.
...
(II) LoadModule: "mouse"
(II) Loading /usr/lib64/xorg/modules/input/mouse_drv.so
(II) Module mouse: vendor="X.Org Foundation"
compiled for 1.20.3, module version = 1.9.2
Module class: X.Org XInput Driver
ABI class: X.Org XInput driver, version 24.1
...
(II)Using input driver 'mouse' for 'Mouse1'
(**) Option "CorePointer"
(**) Mouse1: always reports core events
(**) Option "Protocol" "PS/2"
(**) Option "Device" "/dev/input/In the /dev/input I find a lot of events and at the end
Code:... input 13 ... mice
... input 13 ... mouse0
... input 13 ... mouse1
... input 13 ... mouse2
... input 13 ... mouse3
... input 13 ... mouse4
... root ... pmouse0 -> mouse3
[1]: https://askubuntu.com/questions/1043...dev-input-mice