Touchpad not working properly after suspend-resume

From: <jbo_at_insane.engineer>
Date: Wed, 06 Apr 2022 20:01:41 UTC
Hello folks,

I'm experiencing issues with the touchpad after resuming from suspend.

System:
  - Lenovo ThinkPad X1 Carbon Gen9
  - FreeBSD 13.1-STABLE (March 27 2022)

After a regular boot, the touchpad is working as expected. If I then use zzz(8) to suspend the system and resume afterwards, the touchpad is behaving weirdly:
  - Regular cursor movements (one finger) are very, very laggy. It feels like the system is updating the cursor's position only once ever 800ms (or there about).
  - Anything multi-touch related such as two-finger scrolling is not working at all.

The keyboard and the trackpoint (joystick-thingy) continue to work as expected after resuming from suspend.

I'm using libinput as the input driver. Here's the relevant part of my Xorg config:

  Section "InputClass"
    Identifier "libinput touchpad catchall"
    Driver "libinput"
    MatchIsTouchpad "on"
    MatchDevicePath "/dev/input/event*"
    Option "AccelSpeed" "0.5"
    Option "ClickMethod" "clickfinger"
    Option "DisableWhileTyping" "on"
    Option "HorizontalScrolling" "on"
    Option "LeftHanded" "off"
    Option "NaturalScrolling" "on"
    Option "ScrollMethod" "twofinger"
    Option "Tapping" "on"
    Option "TappingDrag" "on"
    Option "TappingDragLock" "off"
  EndSection

Any idea how to track down the problem, what the problem could be or how to fix this?
I could not spot anything obviously in Xorg's log.


Best regards,
~ Joel