Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 27 Apr 2020 17:45:59 +0200
From:      Michael Gmelin <freebsd@grem.de>
To:        Malcolm Matalka <mmatalka@gmail.com>
Cc:        Michael Gmelin <freebsd@grem.de>, Niclas Zeising <zeising+freebsd@daemonic.se>, "freebsd-current\@freebsd.org" <freebsd-current@freebsd.org>
Subject:   Re: Weird mouse behaviour
Message-ID:  <20200427174559.070c1b26@bsd64.grem.de>
In-Reply-To: <864kt5nf2j.fsf@gmail.com>
References:  <86imhlv518.fsf@gmail.com> <6dfad31c-68f2-c38f-28ac-0696e73b41a9@daemonic.se> <865zdljqg9.fsf@gmail.com> <e7319a5f-7470-76de-cf9e-dc92cbbeb4e7@daemonic.se> <86zhaxi4ea.fsf@gmail.com> <20200427153417.764b1bd4@bsd64.grem.de> <864kt5nf2j.fsf@gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help


On Mon, 27 Apr 2020 17:06:28 +0200
Malcolm Matalka <mmatalka@gmail.com> wrote:

> Michael Gmelin <freebsd@grem.de> writes:
> 
> >
> > Could you share your setup by running
> >
> >   pkg install ca_root_nss
> >   fetch \
> >   https://raw.githubusercontent.com/grembo/xorg-udev-setup-check/master/xorg-udev-setup-check.sh
> >   ./xorg-udev-setup-check.sh -desk
> >
> > and mailing the resulting file to the list (or just me directly)?  
> 
> I ran this and emailed results to Michael.  I fixed the issues it
> brought up and, tada, it's working.
> 
> One thing I'm not sure about is: how do I persist the changes?  I have
> done:
> 
> xinput --set-prop "SynPS/2 Synaptics TouchPad" "libinput Tapping
> Enabled" 1
> 
> xinput --set-prop "SynPS/2 Synaptics TouchPad" "libinput Accel Speed"
> 0.3
> 

There are two fundamental ways:

  1. Place a configuration file in /usr/local/etc/X11/xorg.conf.d
  2. Add the xinput commands to ~/.xinitrc

I usually go with option 2 these days whenever possible (unless it's
something that can only be done in Xorg's configuration files).

So a typical ~/.xinitrc would look like this:

    setxkbmap -model pc105 -layout de
    xmodmap $HOME/.Xmodmap
    xinput --set-prop "xyz" "0 0 0"
    xsetroot ...
   /path/to/my/windowmanager

You can find the one I used a few years ago here as an example:
https://blog.grem.de/pages/t470s.html#my-home-xinitrc

That way it's also part of my home directory and I can easily take
it to another machine. It also means I don't change Xorg's default
configs directly, which makes updating easier.

The best part is, that once I found the right tweak, I can simply copy
and paste the command that fixed the issue in there and call it a day.
And if anyone asks for help, I can consult my ~/.xinitrc and ask them
to execute the commands to test if it fixes their ache - which is easier
and often doesn't require to restart X.

> But these names don't seem to directly correspond to names in man 4
> libinput.  Why the difference?

That's kind of an upstream question, but you can see at least where
it's done it in the source of xf86-input-libinput[0]. Basically it's
done that way for pragmatic reasons (unifying xf86 input section config
vs xinput ABI would probably violate the Pareto principle).

It's a bit confusing, but as most things that you can configure and
their current configuration vales can be seen and tweaked by calling
xinput on the command line, I barely visit that man page. One more
reason why I tweak these things in ~/.xinitrc.

> 
> I also noticed in xorg logs:
> 
> [    34.491] (EE) event6  - SynPS/2 Synaptics TouchPad: kernel bug:
> Touch jump detected and discarded. See
> https://wayland.freedesktop.org/libinput/doc/1.15.5/touchpad-jumping-cursors.html
> for details [    34.491] (EE) event6  - SynPS/2 Synaptics TouchPad:
> WARNING: log rate limit exceeded (5 msgs per 7200000ms). Discarding

That's to be expected and can be ignored, unless you notice any
usability problems.

Cheers,
Michael

[0]
cd /usr/ports/x11-drivers/xf86-input-libinput
make patch
cd work/xf86-input-libinput*

see src/xf86libinput.c and include/libinput-properties.h

-- 
Michael Gmelin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20200427174559.070c1b26>