14

When the laptop (Dell Vostro 15) wakes from suspend the mouse cursor can be moved with the touchpad at the login/lock screen, but once back in to the session does not move it. At this point plugging in an external USB mouse works fine. The touchpad works after a reboot, until suspending.

andrew.46
  • 38,003
  • 27
  • 156
  • 232

1 Answers1

16

Reloading the touchpad / mouse driver after resuming from suspend works in most cases.

Run sudo -H gedit /lib/systemd/system-sleep/touchpad

Copy and paste in these lines:

#!/bin/bash

if [[ $1 == post ]]; then
    modprobe -r psmouse
    modprobe psmouse
fi

Save the file and exit.

Now make it a program by setting the execution bit:

chmod a+x /lib/systemd/system-sleep/touchpad

You will need to reboot for changes to take effect.

  • This didn't help (I'd actually tried before manually rmmod and modprobing psmouse). But now, after another restart, it is working again. I believe some update was installed as well, so perhaps some transient kernel issue that was fixed? – Andrew Ray Oct 14 '18 at 07:11
  • I should have put into the answer a reboot may be necessary for changes to take effect but I didn't fully research that part of the answer. Let me know if it is still broken after next suspend. Thanks. – WinEunuuchs2Unix Oct 14 '18 at 15:48
  • 2
    This solution did not work for me. Ubuntu 18.04 with "SYNA8004:00 06CB:CD8B Touchpad", Lenovo X1 Carbon Gen 7. I get snappy touchpad behavior after resuming from hibernation. – SaTa Sep 27 '19 at 03:30
  • @SaTa You need to reboot for changes to take effect. Also hibernation often brings a host of new problems not found with suspend/resume. – WinEunuuchs2Unix Sep 27 '19 at 10:35
  • Thanks. The issue goes away if I do a reboot. Running modprobe -r psmouse and then modprobe psmouse from the terminal should resolve the problem, right? It doesn't though. If it was solving the issue, then I could have within the script you are recommending. – SaTa Sep 27 '19 at 15:51
  • instead of psmouse, I actually had to target i2c_i801 to get the two finger scrolling to work again. – Antony May 14 '20 at 15:23
  • On my lenovo x1 carbon, I had to replace pmouse with i2c_i801 to get the 2 finger scrolling working after suspend. – papar Sep 07 '20 at 15:43
  • This issue went away after an update. Not sure of its actual cause. – Andrew Ray Oct 14 '18 at 07:16
  • still there in ubuntu 20.04(focal) – mirec Jun 23 '20 at 20:30