修复ideapad14s 在ubuntu kernel(pve所用)上触摸板elants_i2c疯狂报错

https://askubuntu.com/questions/1248176/ideapad-5-15are05-elan-touchpad-not-working-on-20-04-nor-on-18-04

Just create a SystemD unit like the below:

stefano@stefano-IdeaPad-5-15ARE05:~$ cat /etc/systemd/system/touchpadfix.service

[Unit]
Description=Fix touchpad issue by binding correct driver

[Service]
ExecStart=/usr/local/bin/touchpadfix
Type=oneshot
RemainAfterExit=yes

[Install]
WantedBy=multi-user.target

and create /usr/local/bin/touchpadfix file as follows

stefano@stefano-IdeaPad-5-15ARE05:~$ cat /usr/local/bin/touchpadfix

#!/bin/bash
modprobe i2c_hid
echo "i2c-ELAN0001:00" > /sys/bus/i2c/drivers/elants_i2c/unbind
echo "i2c-ELAN0001:00" > /sys/bus/i2c/drivers/i2c_hid/bind

and then make it executable, enable and start the unit with the following commands:

chmod +x /usr/local/bin/touchpadfix
sudo systemctl daemon-reload
sudo systemctl enable --now touchpadfix.service

此处评论已关闭