Views:
832β
Votes: 4β
Tags:
18.04
thinkpad
trackpoint
Link:
π See Original Answer on Ask Ubuntu β§ π
URL:
https://askubuntu.com/q/1159960
Title:
Thinkpad trackpoint and trackpoint keys disabled after suspend
ID:
/2019/07/21/Thinkpad-trackpoint-and-trackpoint-keys-disabled-after-suspend
Created:
July 21, 2019
Edited: January 29, 2022
Upload:
September 15, 2024
Layout: post
TOC:
false
Navigation: false
Copy to clipboard: false
Having to unload and reload the psmouse
driver when resuming from suspend is a common problem. You can automate the process with a script though:
Create a new file in the /lib/systemd/system-sleep/
directory containing:
#!/bin/bash
case $1/$2 in
pre/*)
echo "Going to $2..."
# Place your pre suspend commands here, or `exit 0` if no pre suspend action required
modprobe -r psmouse
;;
post/*)
echo "Waking up from $2..."
# Place your post suspend (resume) commands here, or `exit 0` if no post suspend action required
sleep 2
modprobe psmouse
;;
esac
Make it executable:
sudo chmod a+x /lib/systemd/system-sleep/script-name
After the next reboot, the script will be active.
A script like this has worked for many people over the years. Of course your other option would be trying the previous kernel version and if it works sticking with it.
Notes when your script isnβt working:
-
Ensure the systemd suspend target is enabled.
- From the same accepted answer in the link, you may need to set
PATH
for external commands by inserting the following command into your script. Add any additional directories your commands may be in:PATH=/sbin:/usr/sbin:/bin:/usr/bin
- If it still isnβt working, post a new question. Then drop a comment below with a link to the new question and Iβll have a look.