Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 17 Apr 2017 12:59:55 +0200
From:      =?UTF-8?Q?Jan_Kokem=c3=bcller?= <jan.kokemueller@gmail.com>
To:        Vladimir Kondratyev <vladimir@kondratyev.su>, current@freebsd.org
Cc:        freebsd-mobile@freebsd.org
Subject:   Re: CFT: EVDEV support in psm(4) driver
Message-ID:  <5446ec03-c501-a369-01fc-e58a7d8712d9@gmail.com>
In-Reply-To: <5fa9225de944d6cdac0b7e5749b452a9@kondratyev.su>
References:  <5fa9225de944d6cdac0b7e5749b452a9@kondratyev.su>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi Vladimir,
this patch works great for me!
I'm testing this with a semi-mt Synaptics touchpad and a TrackPoint of a 
Lenovo T420. I'm running 12-CURRENT (amd64) and Xorg 1.19.3 from 
Matthew's CFT with the libudev-devd backend. The Evdev devices are 
picked up correctly by libudev-devd and xf86-input-libinput (even the 
TrackPoint). I haven't tested this with xf86-input-synaptics (which is 
in maintenance mode) or xf86-input-evdev. I am not
using xf86-input-mouse or xf86-input-keyboard.

What works (everything):
  - true smooth scrolling with Xinput2 (tested with GTK3 Firefox or 
gtk3-demo)
  - TrackPoint scrolling holding the middle button
  - both horizontal/vertical scrolling
  - two finger scrolling powered by libinput (this semi-mt touchpad 
doesn't really support more gestures than this)

The only thing that doesn't work out of the box is the mouse pointer on 
the VT console. It wouldn't be hard though to write a small tool that 
uses libinput to translate Evdev events into CONS_MOUSECTL ioctls needed 
for the VT pointer.

Some comments:
  - PS2_MOUSE_SYNAPTICS_PRODUCT should be 0x0007, not 0x0009 
(http://lxr.free-electrons.com/source/drivers/input/mouse/psmouse.h#L86)
  - The TrackPoint should be added with product id 0x000A as on Linux 
and with the INPUT_PROP_POINTING_STICK Evdev property set
  - I think it would be better if the same Evdev device names were 
exposed as on Linux (for example "SynPS/2 Synaptics TouchPad"). Many 
scripts using xinput to change device properties depend on the Linux 
device names.

I've added a patch and comments to https://reviews.freebsd.org/D10265 .

Even Linux 64-bit binaries work correctly with the created 
/dev/input/event* devices after applying those two patches here:
  - https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=218625
  - https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=218627

This will be very useful for Linux games using joysticks, game 
controllers etc.

Cheers,
Jan



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5446ec03-c501-a369-01fc-e58a7d8712d9>