Re: break out separate wsmouse devices for ps2 types

2018-12-21 Thread William Graeber
For historical reference, Ulf has pointed out that I misunderstood what
was going on here, and this diff is incorrect.

There is a much more elegant way of handling this with xorg.conf that he
pointed out using separate InputClasses with MatchIsTouchPad and
MatchIsPointer options.

Thanks Ulf, and thanks jcs@ for getting me started.



break out separate wsmouse devices for ps2 types

2018-12-17 Thread William Graeber
I was having an issue where I was unable to separately define
sensitivity and acceleration on my X1.  When the touchpad is usable, the
trackpoint is borderline unusable (the opposite is also true).  xinput
was showing:

$ xinput list
⎡ Virtual core pointer  id=2[master pointer  (3)]
⎜   ↳ Virtual core XTEST pointerid=4[slave  pointer  (2)]
⎜   ↳ /dev/wsmouse0 id=7[slave  pointer  (2)]
⎜   ↳ /dev/wsmouse  id=8[slave  pointer  (2)]
⎣ Virtual core keyboard id=3[master keyboard (2)]
↳ Virtual core XTEST keyboard   id=5[slave  keyboard (3)]
↳ /dev/wskbd

Even though wsmouse0 and wsmouse1 were both present in the dmesg
(https://pastebin.com/raw/qZ9vK196).  This diff breaks out both wsmouse0
and wsmouse1 devices, so that you can set sensitivity/acceleration
separately on both.

This is my first diff, so I suppose if it receives positive feedback I
can go upstream.

Full credit goes to jcs@


Index: wscons.c
===
RCS file: /cvs/xenocara/xserver/config/wscons.c,v
retrieving revision 1.22
diff -u -p -u -p -r1.22 wscons.c
--- wscons.c30 Jul 2018 16:00:39 -  1.22
+++ wscons.c18 Dec 2018 02:17:57 -
@@ -240,6 +240,7 @@ wscons_add_pointers(void)
   case WSMOUSE_TYPE_ELANTECH:
   case WSMOUSE_TYPE_SYNAP_SBTN:
   case WSMOUSE_TYPE_TOUCHPAD:
+  case WSMOUSE_TYPE_PS2:
 wscons_add_pointer(devnam, "ws",
ATTR_TOUCHPAD);
 break;