MSFT Touchpad not working on Lenovo Legion-5 15ARH05

Bug #1887190 reported by Nicolas Rogues
406
This bug affects 73 people
Affects Status Importance Assigned to Milestone
Pop!_OS
Fix Released
Undecided
Unassigned
linux (Arch Linux)
Fix Committed
Undecided
Unassigned
linux (Fedora)
Confirmed
Undecided
Unassigned
linux (Ubuntu)
Fix Released
Undecided
Unassigned
linux (openSUSE)
New
Undecided
Unassigned
xserver-xorg-input-libinput (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Update (based on #296)
=============

The latest kernel tree (https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git) has the complete solution to fix this bug. So we can expect kernel v5.11 to fix this issue without any additional work.

Before the release of v5.11, you are suggested to use #189 to save your touchpad. Note that for distributions like Ubuntu and Fedora, the pinctrl-amd driver is built into the initramfs. So you have to rebuild the initramfs after replacing the old module with new one.
On Fedora, run `sudo dracut --force`; On ubuntu, run `sudo update-initramfs -u`.

The complete solution is three patches,
 - 47a0001436352c9853d72bf2071e85b316d688a2 ("pinctrl: amd: remove debounce filter setting in IRQ type setting")
 - 06abe8291bc31839950f7d0362d9979edc88a666 ("pinctrl: amd: fix incorrect way to disable debounce filter")
 - 8dcb7a15a585b6d0fee15751ce11d7a68cfedd56 ("gpiolib: acpi: Take into account debounce settings")

The first two patches has reached the stable tree. If the last one is also backported to LTS kernel, you won't need to install kernel 5.11. But I don't know when this will happen.

Original bug report
===================

Hello

The MSFT touchpad of this Lenovo Legion-5 15ARH05 laptop is not reacting at all (pointer and click never move when touchpad is touched). This has been reported by other users in various websites, with various linux systems including other Ubuntu systems, but I saw no launchpad bug so I post one. Example of websites covering the issue :
- https://askubuntu.com/questions/1253830/lenovo-legion-5-touchpad (exactly the same laptop)
- https://www.linux.org/threads/lenovo-legion-5-touchpad.29536/ (similar laptop)

xinput indentifies it as MSFT0001:00 04F3:3140

Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ MSFT0001:00 04F3:3140 Touchpad id=17 [slave pointer (2)]
⎜ ↳ MSFT0001:00 04F3:3140 Mouse id=16 [slave pointer (2)]
⎜ ↳ ITE Tech. Inc. ITE Device(8910) Consumer Control id=12 [slave pointer (2)]
⎜ ↳ Logitech USB Optical Mouse id=11 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
    ↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
    ↳ Ideapad extra buttons id=15 [slave keyboard (3)]
    ↳ Power Button id=6 [slave keyboard (3)]
    ↳ Integrated Camera: Integrated C id=10 [slave keyboard (3)]
    ↳ Video Bus id=7 [slave keyboard (3)]
    ↳ ITE Tech. Inc. ITE Device(8910) Consumer Control id=19 [slave keyboard (3)]
    ↳ Power Button id=9 [slave keyboard (3)]
    ↳ ITE Tech. Inc. ITE Device(8910) Wireless Radio Control id=13 [slave keyboard (3)]
    ↳ ITE Tech. Inc. ITE Device(8910) Keyboard id=14 [slave keyboard (3)]
    ↳ AT Translated Set 2 keyboard id=18 [slave keyboard (3)]
    ↳ Video Bus id=8 [slave keyboard (3)]

Thanks a lot for your time. It does not help, but I can confirm what was reported on askubuntu by another user : the touchpad does work on Windows.

ProblemType: Bug
DistroRelease: Ubuntu 20.04
Package: linux-image-5.4.0-40-generic 5.4.0-40.44
ProcVersionSignature: Ubuntu 5.4.0-40.44-generic 5.4.44
Uname: Linux 5.4.0-40-generic x86_64
NonfreeKernelModules: nvidia_modeset nvidia
ApportVersion: 2.20.11-0ubuntu27.3
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC0: nicolas 1567 F.... pulseaudio
 /dev/snd/controlC1: nicolas 1567 F.... pulseaudio
 /dev/snd/controlC2: nicolas 1567 F.... pulseaudio
CasperMD5CheckResult: skip
CurrentDesktop: ubuntu:GNOME
Date: Fri Jul 10 20:14:25 2020
InstallationDate: Installed on 2020-07-02 (8 days ago)
InstallationMedia: Ubuntu 20.04 LTS "Focal Fossa" - Release amd64 (20200423)
MachineType: LENOVO 82B5
ProcEnviron:
 TERM=xterm-256color
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=fr_FR.UTF-8
 SHELL=/bin/bash
ProcFB: 0 EFI VGA
ProcKernelCmdLine: BOOT_IMAGE=/vmlinuz-5.4.0-40-generic root=UUID=d8898017-2821-434e-ab52-fec76ac93106 ro quiet splash vt.handoff=7
RelatedPackageVersions:
 linux-restricted-modules-5.4.0-40-generic N/A
 linux-backports-modules-5.4.0-40-generic N/A
 linux-firmware 1.187.1
SourcePackage: linux
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 05/12/2020
dmi.bios.vendor: LENOVO
dmi.bios.version: EUCN19WW
dmi.board.asset.tag: NO Asset Tag
dmi.board.name: LNVNB161216
dmi.board.vendor: LENOVO
dmi.board.version: SDK0J40709 WIN
dmi.chassis.asset.tag: NO Asset Tag
dmi.chassis.type: 10
dmi.chassis.vendor: LENOVO
dmi.chassis.version: Lenovo Legion 5 15ARH05
dmi.modalias: dmi:bvnLENOVO:bvrEUCN19WW:bd05/12/2020:svnLENOVO:pn82B5:pvrLenovoLegion515ARH05:rvnLENOVO:rnLNVNB161216:rvrSDK0J40709WIN:cvnLENOVO:ct10:cvrLenovoLegion515ARH05:
dmi.product.family: Legion 5 15ARH05
dmi.product.name: 82B5
dmi.product.sku: LENOVO_MT_82B5_BU_idea_FM_Legion 5 15ARH05
dmi.product.version: Lenovo Legion 5 15ARH05
dmi.sys.vendor: LENOVO
---
ProblemType: Bug
ApportVersion: 2.20.11-0ubuntu27.3
Architecture: amd64
CasperMD5CheckResult: skip
CurrentDesktop: ubuntu:GNOME
DistroRelease: Ubuntu 20.04
InstallationDate: Installed on 2020-07-02 (12 days ago)
InstallationMedia: Ubuntu 20.04 LTS "Focal Fossa" - Release amd64 (20200423)
Package: linux (not installed)
ProcEnviron:
 TERM=xterm-256color
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=fr_FR.UTF-8
 SHELL=/bin/bash
Tags: focal
Uname: Linux 5.8.0-050800rc5-generic x86_64
UnreportableReason: The running kernel is not an Ubuntu kernel
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm cdrom dip lpadmin lxd plugdev sambashare sudo
_MarkForUpload: True

CVE References

Revision history for this message
Nicolas Rogues (nrogues) wrote :
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :
You-Sheng Yang (vicamo)
tags: added: hwe-touchpad
Revision history for this message
Nicolas Rogues (nrogues) wrote : ProcCpuinfoMinimal.txt

apport information

tags: added: apport-collected
description: updated
Revision history for this message
Nicolas Rogues (nrogues) wrote :

Hello

Kernel 5.8-rc5 from https://kernel.ubuntu.com/~kernel-ppa/mainline/v5.8-rc5/ does not resolve the problem.

I tried to use below command to reattach all apport files, but it only attached one file, let me know if you need more files (and provide the appropriate command line !)
apport-collect 1887190

Thanks
Nicolas

Revision history for this message
Helmut Stult (helmut-stult) wrote :

The link provides all the necessary information:

https://linux-hardware.org/?probe=59d2f291d6

Revision history for this message
Helmut Stult (helmut-stult) wrote :

Controlling the screen brightness with Fn + F5 / F6 also does not work

Revision history for this message
Stefano Galassi (iltoga) wrote :

my lenovo legion 5 15ARH05 has same issues:
touchpad shows up under input devices as 'MSFT0001:00 04F3:3140 Touchpad' but doesn't work on linux (on windows it does work perfectly)
screen brightness control doesn't work too

https://linux-hardware.org/?probe=a8dfb4b56d

Revision history for this message
You-Sheng Yang (vicamo) wrote :
Download full text (3.6 KiB)

@Helmut, from your Xorg.log and dmesg, MSFT0001 has beend detected and enabled in kernel, but somehow it failed to be enabled in xorg:

[ 74.771] (II) config/udev: Adding input device MSFT0001:00 04F3:3140 Mouse (/dev/input/event16)
[ 74.771] (**) MSFT0001:00 04F3:3140 Mouse: Applying InputClass "evdev pointer catchall"
[ 74.771] (**) MSFT0001:00 04F3:3140 Mouse: Applying InputClass "libinput pointer catchall"
[ 74.771] (II) Using input driver 'libinput' for 'MSFT0001:00 04F3:3140 Mouse'
[ 74.771] (**) MSFT0001:00 04F3:3140 Mouse: always reports core events
[ 74.771] (**) Option "Device" "/dev/input/event16"
[ 74.771] (**) Option "_source" "server/udev"
[ 74.772] (II) event16 - MSFT0001:00 04F3:3140 Mouse: is tagged by udev as: Mouse Pointingstick
[ 74.772] (II) event16 - MSFT0001:00 04F3:3140 Mouse: device is a pointer
[ 74.772] (II) event16 - MSFT0001:00 04F3:3140 Mouse: device removed
[ 74.836] (**) Option "config_info" "udev:/sys/devices/platform/AMDI0010:03/i2c-0/i2c-MSFT0001:00/0018:04F3:3140.0001/input/input18/event16"
[ 74.836] (II) XINPUT: Adding extended input device "MSFT0001:00 04F3:3140 Mouse" (type: MOUSE, id 16)
[ 74.836] (**) Option "AccelerationScheme" "none"
[ 74.836] (**) MSFT0001:00 04F3:3140 Mouse: (accel) selected scheme none/0
[ 74.836] (**) MSFT0001:00 04F3:3140 Mouse: (accel) acceleration factor: 2.000
[ 74.836] (**) MSFT0001:00 04F3:3140 Mouse: (accel) acceleration threshold: 4
[ 74.837] (II) event16 - MSFT0001:00 04F3:3140 Mouse: is tagged by udev as: Mouse Pointingstick
[ 74.837] (II) event16 - MSFT0001:00 04F3:3140 Mouse: device is a pointer
[ 74.838] (II) config/udev: Adding input device MSFT0001:00 04F3:3140 Mouse (/dev/input/mouse0)
[ 74.838] (II) No input driver specified, ignoring this device.
[ 74.838] (II) This device may have been added with another device file.
[ 74.839] (II) config/udev: Adding input device MSFT0001:00 04F3:3140 Touchpad (/dev/input/event17)
[ 74.839] (**) MSFT0001:00 04F3:3140 Touchpad: Applying InputClass "evdev touchpad catchall"
[ 74.839] (**) MSFT0001:00 04F3:3140 Touchpad: Applying InputClass "libinput touchpad catchall"
[ 74.839] (II) Using input driver 'libinput' for 'MSFT0001:00 04F3:3140 Touchpad'
[ 74.839] (**) MSFT0001:00 04F3:3140 Touchpad: always reports core events
[ 74.839] (**) Option "Device" "/dev/input/event17"
[ 74.839] (**) Option "_source" "server/udev"
[ 74.839] (II) event17 - MSFT0001:00 04F3:3140 Touchpad: is tagged by udev as: Touchpad
[ 74.840] (II) event17 - MSFT0001:00 04F3:3140 Touchpad: device is a touchpad
[ 74.840] (II) event17 - MSFT0001:00 04F3:3140 Touchpad: device removed
[ 74.916] (**) Option "config_info" "udev:/sys/devices/platform/AMDI0010:03/i2c-0/i2c-MSFT0001:00/0018:04F3:3140.0001/input/input19/event17"
[ 74.917] (II) XINPUT: Adding extended input device "MSFT0001:00 04F3:3140 Touchpad" (type: TOUCHPAD, id 17)
[ 74.917] (**) Option "AccelerationScheme" "none"
[ 74.917] (**) MSFT0001:00 04F3:3140 Touchpad: (accel) selected scheme none/0
[ 74.917] (**) MSFT0001:00 04F3:3140 Touchpad: (accel) acceleration factor: 2.000
[ 74.917] (**) MSF...

Read more...

Revision history for this message
You-Sheng Yang (vicamo) wrote :

Please file screen brightness control as another bug (and maybe comment the url for that new bug) and let's focus on touchpad here.

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :
Changed in linux (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Nicolas Rogues (nrogues) wrote :

Hello,

The kernel 5.4.0-42-generic from https://people.canonical.com/~khfeng/lp1887190/ does not work either.

Thanks

Nicolas

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Can you please attach dmesg? Thanks!

Revision history for this message
Nicolas Rogues (nrogues) wrote :

Here you go
Nicolas

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Please run `watch -n0 cat /proc/interrupts`, put finger on the touchpad and see "AMDI0010:03", "pinctrl_amd" or "MSFT0001:00" increase the interrupt count rapidly.

Revision history for this message
Nicolas Rogues (nrogues) wrote :

AMDI0010:03 and pinctrl_amd are present but the count does not move when I move finger or click on the touchpad.

Please note I tried to remove my USB Mouse which is responsible for the high counts on one of xhci_hcd. For this mouse it's moving rapidly.

Two screen captures enclosed.

Revision history for this message
Nicolas Rogues (nrogues) wrote :
Revision history for this message
Justin Arendt (arendtubuntuone) wrote :

This bug also affects my laptop touchpad
Lenvo Legion 5-ARH05 5.7.1 Kernel
https://linux-hardware.org/?probe=d449a0b248

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :
Revision history for this message
Stefano Galassi (iltoga) wrote :

I manually patched that file on 5.7.8-AMD kernel, but touchpad is still dead..

https://linux-hardware.org/?probe=50272ea6ea

thank you

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Please raise the issue to the following email address:
Jarkko Nikula <email address hidden> (maintainer:SYNOPSYS DESIGNWARE I2C DRIVER)
Andy Shevchenko <email address hidden> (reviewer:SYNOPSYS DESIGNWARE I2C DRIVER)
Mika Westerberg <email address hidden> (reviewer:SYNOPSYS DESIGNWARE I2C DRIVER)
Philipp Zabel <email address hidden> (maintainer:RESET CONTROLLER FRAMEWORK)
<email address hidden> (open list:SYNOPSYS DESIGNWARE I2C DRIVER)
<email address hidden> (open list)

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Possible dupe of lp: #1884981, with different error though.

Revision history for this message
Nicolas Rogues (nrogues) wrote :

done today

got an error from vger.kernel.org (policy analysis reported: your address is not liked source for email) but not from other recipients, so if any of the other affected users has an approved email address with this server, I will be glad to provide the initial email for forwarding

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in xserver-xorg-input-libinput (Ubuntu):
status: New → Confirmed
Revision history for this message
Didi Kohen (kohen-d) wrote :

I think I have the same issue on my Idea Pad 5, before I got i2c controller timed out errors, but after a firmware upgrade, I don't see any errors, I'll try to revert my firmware settings to see if I can restore the previous state (where after windows is started, touchpad workd on the next boot)
I'll try the kernels given here afterwards (since it did work before)

Revision history for this message
Didi Kohen (kohen-d) wrote :

OK, this is really strange, after tons of reboots to Ubuntu and Win 10, it started working again after I disabled the legacy boot option.
Still would like a solution to the timeouts other than rebooting twice, though.
I'm a developer, so if there are multiple code changes that need to be tested, I could make them and compile to check, but right now I don't know where to start. (I'm used to working on storage, not HID)

Revision history for this message
Nicolas Rogues (nrogues) wrote :

Hello Didi,

The issue we face could be different : on the Lenovo Legion-5 15ARH05 (which is the object of this bug report) there is no working trick to boot on Windows then Ubuntu : it just never worked under Linux on the two BIOS tested (factory I think EUCN16WW and June update EUCN19WW), in UEFI mode, no matters if Windows was used before reboot and grub to Ubuntu (I have a dual-boot setup).

As a remark, the touchpad does work in the UEFI BIOS, before any OS is loaded.

Revision history for this message
Ben T (derrotmax) wrote :

Touchpad MSFT0001:00 04F3:3140 is dead on 5.8 rc5 as well.

Revision history for this message
Helmut Stult (helmut-stult) wrote :

I have found the cause so far that the touchpad MSFT0001: 00 04F3: 3140 is recognized, but no suitable driver is found.

With the touchpad ELAN0001: 00 04F3: 3140 it seems to work with a few tricks.
ELAN is also available in the kernel config, but MSFT is not.

I just don't understand why there are two different names (ELAN and MFST) under the same hardware ID - what did Lenovo do?

Revision history for this message
Nicolas Rogues (nrogues) wrote :

It's a good question.

In my understanding, the Legion R7000 is the name for China of the Legion-5 15ARH05. In the Lenovo forum, the Lenovo employee has no access to the equipment and indicates it's a kernel issue, suggesting it used to work prior to 5.4 kernel. That looks strange.

https://forums.lenovo.com/topic/view/2713/5020793

Also in this thread a member of the Lenovo forum points out to a blog, unfortunately in Chinese, of a guy who may have found a workaround. I tried to google translate it but was not sure of the result to try anything :

https://www.cnblogs.com/mikeguan/p/13126497.html

Revision history for this message
Helmut Stult (helmut-stult) wrote :

I am a Manjaro developer and we have kernels 4.4 / 4.9 / 4.14 / 4.19 / 5.4 / 5.7 / 5.8
The touchpad doesn't work with one of the kernels.
Screen brightness only works with AMD- or nouveau-Driver, not with the proprietary driver, like 440.100
The brightness display works, but nothing changes.
.

Revision history for this message
Ben T (derrotmax) wrote :

Nicolas -- I've seen the R7000 Chinese post (https://www.cnblogs.com/mikeguan/p/13126497.html), and what it basically entails is blacklisting hid_multitouch (or disabling it in the kernel and recompiling), which according to other forums seems to have an effect on some touchpads, but has no effect on the MSFT0001:00 04F3:3140 touchpad we have. I attempted his suggestions anyways, and saw the same lack of results -- the touchpad remained dead.

Revision history for this message
Nicolas Rogues (nrogues) wrote :

Thanks Helmut and Ben. These are very precise information and better than any post elsewhere.
I got no reply from the email contacts provided by Kai-Heng yet...
Anyone with a Lenovo connection ?

Revision history for this message
Helmut Stult (helmut-stult) wrote :

Just repeat again - the fix works where an incorrect driver is detected.
However, no driver is found at all for the LEGION 5 and the touchpad is therefore not activated.

Revision history for this message
Helmut Stult (helmut-stult) wrote :

These are my latest LOG files

https://linux-hardware.org/?probe=27a5d47256

Revision history for this message
Helmut Stult (helmut-stult) wrote :

As long as no solution is found, here is another solution.

https://gitlab.manjaro.org/packages/community/lenopow

Since it is only a script, this should work in every distribution ;-)

Revision history for this message
Helmut Stult (helmut-stult) wrote :
Nicolas Rogues (nrogues)
Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Stefano Galassi (iltoga)
Changed in linux (Arch Linux):
status: New → Confirmed
Changed in linux (Fedora):
status: New → Confirmed
Revision history for this message
Stefano Galassi (iltoga) wrote :

is there anyone workin on this yet?

Revision history for this message
daleli (daleli) wrote :

is there anyone workin on this yet?

Revision history for this message
Stefano Galassi (iltoga) wrote :

it seems not yet... :(

no longer affects: linux
information type: Public → Public Security
information type: Public Security → Public
Eugene (zhekehz)
information type: Public → Public Security
information type: Public Security → Private Security
information type: Private Security → Public
juziy (jukz)
no longer affects: linux
tags: added: patch
Changed in linux (Arch Linux):
status: Confirmed → Fix Committed
Coiby Xu (coiby)
description: updated
Changed in linux (Ubuntu):
assignee: nobody → Phan Thanh Long (phanlong2811)
Coiby Xu (coiby)
description: updated
tags: added: verification-needed-xenial
tags: added: verification-needed-bionic
tags: added: verification-needed-groovy
tags: added: verification-failed-groovy
removed: verification-needed-groovy
tags: added: verification-needed-focal
Changed in linux (Ubuntu):
assignee: Phan Thanh Long (phanlong2811) → nobody
tags: added: verification-done-focal
removed: verification-needed-focal
337 comments hidden view all 417 comments
Revision history for this message
Marton Danko (golddragon007) wrote :

I've checked the 5.11.0-rc7 and the touchpad still doesn't work properly, on the left and right bottom side the same primary action is being taken instead of secondary on the right and primary on the left!

Revision history for this message
Coiby Xu (coiby) wrote : Re: [Bug 1887190] Re: MSFT Touchpad not working on Lenovo Legion-5 15ARH05
Download full text (8.0 KiB)

Hi resolve,

On Sun, Feb 14, 2021 at 04:09:09PM -0000, roselove wrote:
>Hi, I think I personally tried everything from bbs.archlinux.org,
>forum.manjaro.org, reddit, https://github.com/coiby/standalone_i2c_hid,
>bugzilla, bugs.launchpad.net, etc...
>
>I tried Coiby solution this very day (2021-02-14).
>
>Nothing ever worked since I updated to 9.7 kernel (coiby solution was
>nice before that ^^)
>
>Here is my lenovo model :
>https://psref.lenovo.com/Detail/Legion/Lenovo_Legion_5_15ARH05?M=82B50015FR
>
>Here is my touchpad model :
>```
>Input device ID: bus 0x18 vendor 0x6cb product 0x7f28 version 0x100
>Input device name: "MSFT0001:00 06CB:7F28 Touchpad"
>```
>
>evtest gives that btw :
>```
>Testing ... (interrupt to exit)
>expected 24 bytes, got -1
>
>evtest: error reading: No such device
>```
>

Did the above error happens when using https://github.com/coiby/standalone_i2c_hid?

Have you tried what's suggested in the bug description?

>Now I'm running on `Kernel: 5.10.15-1-MANJARO`, I never managed to make
>touchpad OR brightness work \o/, I guess I'll need to reinstall
>everything someday but if anyone have any clue I guess I'll take it :D
>

As for the brightness issue, https://github.com/Askannz/optimus-manager/
works for me.

>--
>You received this bug notification because you are subscribed to the bug
>report.
>https://bugs.launchpad.net/bugs/1887190
>
>Title:
> MSFT Touchpad not working on Lenovo Legion-5 15ARH05
>
>Status in Pop!_OS:
> New
>Status in linux package in Ubuntu:
> Confirmed
>Status in xserver-xorg-input-libinput package in Ubuntu:
> Confirmed
>Status in linux package in Arch Linux:
> Fix Committed
>Status in linux package in Fedora:
> Confirmed
>Status in linux package in openSUSE:
> New
>
>Bug description:
> Update (based on #296)
> =============
>
> The latest kernel tree
> (https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git)
> has the complete solution to fix this bug. So we can expect kernel
> v5.11 to fix this issue without any additional work.
>
> Before the release of v5.11, you are suggested to use #189 to save your touchpad. Note that for distributions like Ubuntu and Fedora, the pinctrl-amd driver is built into the initramfs. So you have to rebuild the initramfs after replacing the old module with new one.
> On Fedora, run `sudo dracut --force`; On ubuntu, run `sudo update-initramfs -u`.
>
> The complete solution is three patches,
>  - 47a0001436352c9853d72bf2071e85b316d688a2 ("pinctrl: amd: remove debounce filter setting in IRQ type setting")
>  - 06abe8291bc31839950f7d0362d9979edc88a666 ("pinctrl: amd: fix incorrect way to disable debounce filter")
>  - 8dcb7a15a585b6d0fee15751ce11d7a68cfedd56 ("gpiolib: acpi: Take into account debounce settings")
>
> The first two patches has reached the stable tree. If the last one is
> also backported to LTS kernel, you won't need to install kernel 5.11.
> But I don't know when this will happen.
>
> Original bug report
> ===================
>
> Hello
>
> The MSFT touchpad of this Lenovo Legion-5 15ARH05 laptop is not reacting at all (pointer and click never move when touchpad is touched). This has been reported by other users in va...

Read more...

Revision history for this message
Coiby Xu (coiby) wrote :
Download full text (7.3 KiB)

Hi Maton,

On Mon, Feb 15, 2021 at 08:46:57AM -0000, Maton Danko wrote:
>I've checked the 5.11.0-rc7 and the touchpad still doesn't work
>properly, on the left and right bottom side the same primary action is
>being taken instead of secondary on the right and primary on the left!
>

5.11.0-rc7 is expected to fix your touchpad. Could you paste the output of
"sudo cat /sys/kernel/debug/gpio|grep pin130 -A1" and also the output of
"sudo evest" when you lick the left bottom and right bottom button?

>--
>You received this bug notification because you are subscribed to the bug
>report.
>https://bugs.launchpad.net/bugs/1887190
>
>Title:
> MSFT Touchpad not working on Lenovo Legion-5 15ARH05
>
>Status in Pop!_OS:
> New
>Status in linux package in Ubuntu:
> Confirmed
>Status in xserver-xorg-input-libinput package in Ubuntu:
> Confirmed
>Status in linux package in Arch Linux:
> Fix Committed
>Status in linux package in Fedora:
> Confirmed
>Status in linux package in openSUSE:
> New
>
>Bug description:
> Update (based on #296)
> =============
>
> The latest kernel tree
> (https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git)
> has the complete solution to fix this bug. So we can expect kernel
> v5.11 to fix this issue without any additional work.
>
> Before the release of v5.11, you are suggested to use #189 to save your touchpad. Note that for distributions like Ubuntu and Fedora, the pinctrl-amd driver is built into the initramfs. So you have to rebuild the initramfs after replacing the old module with new one.
> On Fedora, run `sudo dracut --force`; On ubuntu, run `sudo update-initramfs -u`.
>
> The complete solution is three patches,
>  - 47a0001436352c9853d72bf2071e85b316d688a2 ("pinctrl: amd: remove debounce filter setting in IRQ type setting")
>  - 06abe8291bc31839950f7d0362d9979edc88a666 ("pinctrl: amd: fix incorrect way to disable debounce filter")
>  - 8dcb7a15a585b6d0fee15751ce11d7a68cfedd56 ("gpiolib: acpi: Take into account debounce settings")
>
> The first two patches has reached the stable tree. If the last one is
> also backported to LTS kernel, you won't need to install kernel 5.11.
> But I don't know when this will happen.
>
> Original bug report
> ===================
>
> Hello
>
> The MSFT touchpad of this Lenovo Legion-5 15ARH05 laptop is not reacting at all (pointer and click never move when touchpad is touched). This has been reported by other users in various websites, with various linux systems including other Ubuntu systems, but I saw no launchpad bug so I post one. Example of websites covering the issue :
> - https://askubuntu.com/questions/1253830/lenovo-legion-5-touchpad (exactly the same laptop)
> - https://www.linux.org/threads/lenovo-legion-5-touchpad.29536/ (similar laptop)
>
> xinput indentifies it as MSFT0001:00 04F3:3140
>
> Virtual core pointer id=2 [master pointer (3)]
> ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
> ⎜ ↳ MSFT0001:00 04F3:3140 Touchpad id=17 [slave pointer (2)]
> ⎜ ↳ MSFT0001:00 04F3:3140 Mouse id=16 [slave pointer (2)]
> ⎜ ↳ ITE Tech. Inc. ITE Device(8910) Consumer Con...

Read more...

Revision history for this message
Marton Danko (golddragon007) wrote :

Hi Coiby,

Here are they:
$ sudo cat /sys/kernel/debug/gpio|grep pin130 -A1
pin130 Level trigger| Active low| interrupt is enabled| interrupt is unmasked| disable wakeup in S0i3 state| disable wakeup in S3 state|
 disable wakeup in S4/S5 state| input is high| pull-up is disabled| Pull-down is disabled| output is disabled| debouncing filter disabled| 0x51b00

I did a left, right and middle click. Between them 2-3 sec delay.

Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (60.8 KiB)

This bug was fixed in the package linux - 5.4.0-66.74

---------------
linux (5.4.0-66.74) focal; urgency=medium

  * focal/linux: 5.4.0-66.74 -proposed tracker (LP: #1913152)

  * Add support for selective build of special drivers (LP: #1912789)
    - [Packaging] Add support for ODM drivers
    - [Packaging] Turn on ODM support for amd64

  * Packaging resync (LP: #1786013)
    - update dkms package versions
    - update dkms package versions

  * Introduce the new NVIDIA 460-server series and update the 460 series
    (LP: #1913200)
    - [Config] dkms-versions -- drop NVIDIA 435 455 and 440-server
    - [Config] dkms-versions -- add the 460-server nvidia driver

  * Enable mute and micmute LED on HP EliteBook 850 G7 (LP: #1910102)
    - ALSA: hda/realtek: Enable mute and micmute LED on HP EliteBook 850 G7

  * SYNA30B4:00 06CB:CE09 Mouse on HP EliteBook 850 G7 not working at all
    (LP: #1908992)
    - HID: multitouch: Enable multi-input for Synaptics pointstick/touchpad device

  * HD Audio Device PCI ID for the Intel Cometlake-R platform (LP: #1912427)
    - SAUCE: ALSA: hda: Add Cometlake-R PCI ID

  * switch to an autogenerated nvidia series based core via dkms-versions
    (LP: #1912803)
    - [Packaging] nvidia -- use dkms-versions to define versions built
    - [Packaging] update-version-dkms -- maintain flags fields
    - [Config] dkms-versions -- add transitional/skip information for nvidia
      packages

  * udpgro.sh in net from ubuntu_kernel_selftests seems not reflecting sub-test
    result (LP: #1908499)
    - selftests: fix the return value for UDP GRO test

  * qede: Kubernetes Internal DNS Failure due to QL41xxx NIC not supporting IPIP
    tx csum offload (LP: #1909062)
    - qede: fix offload for IPIP tunnel packets

  * Use DCPD to control HP DreamColor panel (LP: #1911001)
    - SAUCE: drm/dp: Another HP DreamColor panel brigntness fix

  * kvm: Windows 2k19 with Hyper-v role gets stuck on pending hypervisor
    requests on cascadelake based kvm hosts (LP: #1911848)
    - KVM: x86: Set KVM_REQ_EVENT if run is canceled with req_immediate_exit set

  * Ubuntu 20.10 four needed fixes to 'Add driver for Mellanox Connect-IB
    adapters' (LP: #1905574)
    - net/mlx5: Fix a race when moving command interface to polling mode

  * Fix right sounds and mute/micmute LEDs for HP ZBook Fury 15/17 G7 Mobile
    Workstation (LP: #1910561)
    - ALSA: hda/realtek: fix right sounds and mute/micmute LEDs for HP machines

  * Ubuntu 20.04 - multicast counter is not increased in ip -s (LP: #1901842)
    - net/mlx5e: Fix multicast counter not up-to-date in "ip -s"

  * eeh-basic.sh in powerpc from ubuntu_kernel_selftests timeout with 5.4 P8 /
    P9 (LP: #1882503)
    - selftests/powerpc/eeh: disable kselftest timeout setting for eeh-basic

  * DMI entry syntax fix for Pegatron / ByteSpeed C15B (LP: #1910639)
    - Input: i8042 - unbreak Pegatron C15B

  * CVE-2020-29372
    - mm: check that mm is still valid in madvise()

  * update ENA driver, incl. new ethtool stats (LP: #1910291)
    - net: ena: Change WARN_ON expression in ena_del_napi_in_range()
    - net: ena: ethtool: convert stat_offset to 64 bit resolution
    - net: ena: eth...

Changed in linux (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Marton Danko (golddragon007) wrote :

Hi Coiby,

Did you find anything about why it still doesn't work properly on my machine?

Revision history for this message
Piotr Tomaszewski (nfm886) wrote :

"This bug was fixed in the package linux - 5.4.0-66.74"

Wait, current kernel in Ubuntu 20.04.2 is 5.8 so can I expect to have it working on Ubuntu 20.04.2 without any hassle or I have to switch kernel?

Revision history for this message
Joe Zhou (joezhouchenye) wrote :

Works fine after installing hwe kernel using apt.(5.8.0.44 Ubuntu 20.04 Lenovo R7000P)

Revision history for this message
Coiby Xu (coiby) wrote :

Hi Marton,

On Tue, Feb 23, 2021 at 05:00:30PM -0000, Marton Danko wrote:
>Hi Coiby,
>
>Did you find anything about why it still doesn't work properly on my
>machine?
>

Your GPIO pin register value for the touchpad is 0x51b00 which means the
root cause has been fixed. I've less certain about the evest result but
I don't find something suspicious when comparing it with my laptop. Can
you create another user and check if the problem still occurs after
logging in?

Revision history for this message
Marton Danko (golddragon007) wrote :

I've done it and it's still registered primary action for that user too, it did not change anything.

Revision history for this message
Azizkhan (injkgz) wrote :

Tried - 5.4.0-66.74, 5.8.0.44 and 5.11 kernels, nothing worked for me, but i2c-hid and another one patches fixes problem. What can i do?

1 comments hidden view all 417 comments
Revision history for this message
Shatadru Banerjee (satadru-bag) wrote :

Can anyone please give a summary of the solution? What works what does not? I am using 5.11 on ubuntu 20.04. The touchpad works (not great though) but I cannot use nvidia gpu, hence stuck with the iGPU. The brightness control does not work perfectly. Is it possible to able to use touchpad and the nvidia GPU at the same time? Am I missing something here?
Thanks in advance.

Revision history for this message
Baq Domalaq (baq) wrote :

Hi Shatadru Banerjee (satadru-bag)

I think you should stick to patches and an official kernel of your distro for now.

I use Pop OS 20.10 with kernel 5.8.*. I used to apply the patch in comment #171 and rebuild the kernel to fix my touchpad.

Now two of the 3 new patches which Coiby Xu mentions in this bug description are landed to latest kernel updates of my distro. But without the third patch the touchpad doesn't work correctly. And the patch #171 doesn't work now like before. So I have to revert patches 47a0001436352c9853d72bf2071e85b316d688a2 and 06abe8291bc31839950f7d0362d9979edc88a666, and then apply the patch #171 to make touchpad work correctly.

I think my NVidia works ok.

I'm going to do that until the third patch arrives to my distro. Or a new version of distro will be released (and hopefully everything will work out of the box). Which is in June I think.

Revision history for this message
Coiby Xu (coiby) wrote :

On Wed, Feb 24, 2021 at 04:20:15PM -0000, Marton Danko wrote:
>I've done it and it's still registered primary action for that user too,
>it did not change anything.

I still think there's something wrong in the user space. I found a
similar bug report [1]. What's the output of "sudo libinput
debug-events" when you click the button at the right corner?

$ sudo libinput debug-events
-event7 DEVICE_ADDED MSFT0001:00 06CB:7F28 Mouse seat0 default group8 cap:p left scroll-nat scroll-button
-event8 DEVICE_ADDED MSFT0001:00 06CB:7F28 Touchpad seat0 default group8 cap:pg size 102x67mm tap(dl off) left scroll-nat scroll-2fg-edge click-buttonareas-clickfinger dwt-on

-event8 POINTER_BUTTON +5.491s BTN_RIGHT (273) pressed, seat count: 1
  event8 POINTER_BUTTON +5.612s BTN_RIGHT (273) released, seat count: 0
  event8 POINTER_BUTTON +7.796s BTN_LEFT (272) pressed, seat count: 1
  event8 POINTER_BUTTON +7.953s BTN_LEFT (272) released, seat count: 0

[1] https://bugzilla.redhat.com/show_bug.cgi?id=1564738

Revision history for this message
Shatadru Banerjee (satadru-bag) wrote :

Still confused. Anyway, I want to report that with kernel 5.11 I cannot connect to external display using HDMI. Does this problem appear because of using mainline kernel?

Revision history for this message
Marton Danko (golddragon007) wrote :

Hi Coiby,

Thanks, it seems that correctly telling which hardware button do I press.
Right:
-event18 POINTER_BUTTON +0.174s BTN_RIGHT (273) pressed, seat count: 1
 event18 POINTER_BUTTON +0.318s BTN_RIGHT (273) released, seat count: 0
Middle:
 event18 POINTER_BUTTON +3.086s BTN_MIDDLE (274) pressed, seat count: 1
 event18 POINTER_BUTTON +3.362s BTN_MIDDLE (274) released, seat count: 0
Left:
 event18 POINTER_BUTTON +5.132s BTN_LEFT (272) pressed, seat count: 1
 event18 POINTER_BUTTON +5.271s BTN_LEFT (272) released, seat count: 0

And in the mentioned bug report the following resolution works:
"Apparently it's a change they did in GNOME 3.28 and can be fixed by switching to Area mouse click emulation in GNOME Tweaks."

Thanks for your help, and now I need to go to the corner to cry again, why such a stupid default configuration is shipped with the system...

Revision history for this message
Mohamed Abba (kaderabba) wrote :

Hi Baq Domalaq (baq),
how do you revert the patches and apply #170?

Revision history for this message
Baq Domalaq (baq) wrote :

Hi Mohamed,
please DM me about that.

Revision history for this message
Coiby Xu (coiby) wrote :

On Fri, Feb 26, 2021 at 02:28:24PM -0000, Marton Danko wrote:
>Hi Coiby,
>
>Thanks, it seems that correctly telling which hardware button do I press.
>Right:
>-event18 POINTER_BUTTON +0.174s BTN_RIGHT (273) pressed, seat count: 1
> event18 POINTER_BUTTON +0.318s BTN_RIGHT (273) released, seat count: 0
>Middle:
> event18 POINTER_BUTTON +3.086s BTN_MIDDLE (274) pressed, seat count: 1
> event18 POINTER_BUTTON +3.362s BTN_MIDDLE (274) released, seat count: 0
>Left:
> event18 POINTER_BUTTON +5.132s BTN_LEFT (272) pressed, seat count: 1
> event18 POINTER_BUTTON +5.271s BTN_LEFT (272) released, seat count: 0
>
>And in the mentioned bug report the following resolution works:
>"Apparently it's a change they did in GNOME 3.28 and can be fixed by switching to Area mouse click emulation in GNOME Tweaks."
>

Good to know that:)

>Thanks for your help, and now I need to go to the corner to cry again,
>why such a stupid default configuration is shipped with the system...
>

You are welcome!

Revision history for this message
Piotr Tomaszewski (nfm886) wrote :

Tested Ubuntu 20.04.2/20.10 with all updates. Touchpad not working... How to make it works?

Revision history for this message
Helmut Stult (helmut-stult) wrote :

@Coiby Xu (coiby)

My touchpad MSFT0001:00 04F3:3140 works fine with Kernel 5.11, but stops working with the new 5.12-rc1
So far I haven't found the cause.

Revision history for this message
Helmut Stult (helmut-stult) wrote :
Revision history for this message
Helmut Stult (helmut-stult) wrote :

This is the working kernel 5.11

https://linux-hardware.org/?probe=fbcb409c56

Revision history for this message
Helmut Stult (helmut-stult) wrote :

Works again - have to set CONFIG_I2C_HID_ACPI=m in config

Revision history for this message
Helmut Stult (helmut-stult) wrote :
Revision history for this message
Piotr Henryk Dabrowski (phd) wrote :

Does this touchpad (and iGPU <-> nVidia switching) work fine in Ubuntu 20.10?

Revision history for this message
Coiby Xu (coiby) wrote :

On Tue, Mar 02, 2021 at 01:40:54AM -0000, Helmut Stult wrote:
>Works again - have to set CONFIG_I2C_HID_ACPI=m in config

Well done!

Revision history for this message
Shatadru Banerjee (satadru-bag) wrote :

I want to politely point out that this thread is not helping anymore; it has become mere chit-chat. Things were confusing to begin with and unfortunately it is becoming more confusing. What is the fix? Does is work with a particular kernel? The use of mainline kernel 5.11 should solve all the problems? Is this nvidia gpu issue related to the solution to the trackpad? Why can't the external monitor work, even with the AMD iGPU? Most importantly, what one should do to have a working touchpad, working nvida gpu and working external monitor? Please reply only if you know what are you going to write.

Revision history for this message
pravin poudel (poudprav) wrote :

Touchpad issue and brightness is different. Touchpad is working with kernel 5.11.
A solution for brightness issue is here: https://gitlab.freedesktop.org/drm/amd/-/issues/1438
but I don't think it is in the kernel yet.

Revision history for this message
Shatadru Banerjee (satadru-bag) wrote :

I did not mention brightness issue. With 5.11.3 the brightness does not work flawlessly however there are more serious problems. 1. External monitor not detected via HDMI, 2. still the wifi is not stable, 3. cannot switch to nvidia.

Revision history for this message
Baq Domalaq (baq) wrote :

Pop OS 20.10 has updated to kernel 5.11 and touchpad now works out of the box without patching.
This is a great day for my laptop!

Revision history for this message
Shatadru Banerjee (satadru-bag) wrote :

This thread has gone from stupid to completely pointless.

Revision history for this message
James Hennig (kissykitty) wrote :

Since this is the main thread on the Internet about this issue, I suppose it is appropriate to post here even though I am using Manjaro.

- This issue is non-present on a Thinkpad 3 14ADA05 with touchpad MSFT0001:00 06CB:CE2D on kernel 5.9.16-1 which uses i2c_hid. It is not elantech or designware (doesn't load the associated specific i2c drivers). Installing an entirely new keyboard panel with a new touchpad, essentially rebuilding the entire laptop does not address this issue. It is the same model touchpad for this specific laptop model even if you order a new one (unless I got bad luck of the draw).

- The issue becomes present on kernel 5.10.23-1 (and previous versions of 5.10) up to 5.12rc3. Have not tried compiling 5.12rc5, but no reason to believe it would work.

The touchpad will fail to be recognized and work on bootup between 1-30 reboots. I have tried many things such as different kernels and GRUB_CMDLINE_LINUX_DEFAULT options, yes even checking to set the kernel config option others are suggesting (Manjaro removed then reinstated the CONFIG_I2C_HID_ACPI=m option). I also tore apart kernels 5.9 and 5.10 to look at the pinctrl-amd.c driver and found that there was no difference between the two on these kernels, so it is something other than what https://launchpadlibrarian.net/500948605/0303-pinctrl-amd2.patch addresses since it works on the former kernel but not the latter. Also, the patch fails to apply on 5.12rc5.

I don't really know how to compare the entire torn-apart kernels 5.9 and 5.10 to try and find what change(s) could possibly cause this bug. Hopefully someone else knows how to?

Might be able to get somewhere if so...

Other mods might be replacing the touchpad with a model not designed for the laptop, but I don't know where to start with that either.

Revision history for this message
James Hennig (kissykitty) wrote :

I don't know what I was comparing before, but I was wrong. The pinctrl-amd.c drivers are different between the two kernels. Apologies. I wonder if just dropping in the 5.9 pinctrl-amd.c driver (+possibly other related needed ones?) into 5.10 (or later) would work?

Changed in pop-os:
status: New → Fix Released
Revision history for this message
Coiby Xu (coiby) wrote :

On Sat, Mar 06, 2021 at 03:24:35PM -0000, Shatadru Banerjee wrote:
>I want to politely point out that this thread is not helping anymore; it
>has become mere chit-chat. Things were confusing to begin with and
>unfortunately it is becoming more confusing. What is the fix? Does is
>work with a particular kernel? The use of mainline kernel 5.11 should
>solve all the problems? Is this nvidia gpu issue related to the solution
>to the trackpad? Why can't the external monitor work, even with the AMD
>iGPU? Most importantly, what one should do to have a working touchpad,
>working nvida gpu and working external monitor? Please reply only if you
>know what are you going to write.

On Sat, Mar 13, 2021 at 03:17:55AM -0000, Shatadru Banerjee wrote:
>I did not mention brightness issue. With 5.11.3 the brightness does not
>work flawlessly however there are more serious problems. 1. External
>monitor not detected via HDMI, 2. still the wifi is not stable, 3.
>cannot switch to nvidia.

On Thu, Apr 01, 2021 at 03:06:02AM -0000, Shatadru Banerjee wrote:
>This thread has gone from stupid to completely pointless.

Sorry to know this thread didn't help you. This thread only deals with
the touchpad issue and it's too long to follow. But I've summarized
what's needed in the beginning of the bug report. As far as I know, the
fix for the touchpad doesn't affect nvidia issue. In fact, I don't
experience any of the issues you mentioned including external monitor
not detected and brightness issue on Manjara with kernel=5.11.6-1
after installing optimus manager [1]. [1] is "a port to Archlinux of the
nvidia-prime solution created by Canonical for Ubuntu" so I assume the
issues of external monitor and brightness don't bother Ubuntu users
either.

[1] https://github.com/Askannz/optimus-manager/

Revision history for this message
Coiby Xu (coiby) wrote :

On Mon, Apr 05, 2021 at 03:22:24PM -0000, James Hennig wrote:
>Since this is the main thread on the Internet about this issue, I
>suppose it is appropriate to post here even though I am using Manjaro.
>
>- This issue is non-present on a Thinkpad 3 14ADA05 with touchpad
>MSFT0001:00 06CB:CE2D on kernel 5.9.16-1 which uses i2c_hid. It is not
>elantech or designware (doesn't load the associated specific i2c
>drivers). Installing an entirely new keyboard panel with a new touchpad,
>essentially rebuilding the entire laptop does not address this issue. It
>is the same model touchpad for this specific laptop model even if you
>order a new one (unless I got bad luck of the draw).

If kernel 5.9.16-1 with i2c_hid driver worked for you, I'd suggest you
stick with the i2c_hid that comes with kernel 5.9.16-1 and build a
stand-alone driver for newer kernel and replace newer i2c_hid driver.

>
>- The issue becomes present on kernel 5.10.23-1 (and previous versions
>of 5.10) up to 5.12rc3. Have not tried compiling 5.12rc5, but no reason
>to believe it would work.
>
>The touchpad will fail to be recognized and work on bootup between 1-30
>reboots. I have tried many things such as different kernels and
>GRUB_CMDLINE_LINUX_DEFAULT options, yes even checking to set the kernel
>config option others are suggesting (Manjaro removed then reinstated the
>CONFIG_I2C_HID_ACPI=m option). I also tore apart kernels 5.9 and 5.10 to
>look at the pinctrl-amd.c driver and found that there was no difference
>between the two on these kernels, so it is something other than what
>https://launchpadlibrarian.net/500948605/0303-pinctrl-amd2.patch
>addresses since it works on the former kernel but not the latter. Also,
>the patch fails to apply on 5.12rc5.
>
>I don't really know how to compare the entire torn-apart kernels 5.9 and
>5.10 to try and find what change(s) could possibly cause this bug.
>Hopefully someone else knows how to?
>
>Might be able to get somewhere if so...
>
>Other mods might be replacing the touchpad with a model not designed for
>the laptop, but I don't know where to start with that either.
>

Revision history for this message
James Hennig (kissykitty) wrote :

Hey there @Coiby Xu thank you,

I think I understand what you mean, basically use your Github for this, standalone_i2c_hid, but copy the i2c drivers from the cloned Manjaro kernel 5.9.16-1 ../src/linux-5.9/drivers/hid/i2c-hid/ directory into the ../i2c-hid_standalone/ directory in your project (replacing all 3 source files without the Makefile), then compile it and replace the according module in my running system.

Just as a reference, directly dropping in /lib/modules/5.9.16-1-MANJARO/kernel/drivers/hid/i2c-hid/i2c-hid.ko.xz into the respective 5.11.6-1-MANJARO ../i2c-hid/ directory, then running "mkinitcpio -P linux511" (to use the new module.. if this is how to do it?) does not work, in case anyone was wondering. Touchpad immediately froze on bootup.

******************************

I was able to compile the Manjaro 5.9.16-1 source files into a module (on 5.11.6-1 using linux511-headers) using your provided Makefile and followed the instructions to copy the compiled module into the 5.11.6-1-MANJARO ../i2c-hid/ directory. Also added the GRUB options and ran "sudo update-grub". It functioned, but did not fix the issue. Froze after 2 reboots.

I also tried compiling the Github project as it is, using the provided source files (on 5.11.6-1 using linux511-headers) and it spit out:
ERROR: modpost "irq_to_desc" (in ../i2c-hid-standalone/i2c-hid.ko) undefined !
../i2c-hid-standalone/Module.symvers Error 1

Also I wanted to point out in your README the instruction to append "i2c_hid.polling_mode=1" to GRUB_CMDLINE_LINUX. Shouldn't this be appended to GRUB_CMDLINE_LINUX_DEFAULT? I don't really know, I've just never seen the non-_DEFAULT line used before. In either case, produces same results.

Thanks for all your help, it was worth a shot. Maybe your code needs to be updated for recent kernels?

I am still trying to play with the idea of focusing on the pinctrl-amd.c driver, but really need some help with what to do with that driver. I am not sure the culprit is the i2c_hid driver, but rather this driver. Maybe I'm wrong, but it certainly is the next place to look...

Fun things to try!

Revision history for this message
James Hennig (kissykitty) wrote :

Well, I spent the past few hours pouring over the entirety of this thread and I didn't try the patches to pinctrl-amd.c provided by @Helmut Stult in post #317. These were downloaded and placed in the same source directory as the other patches for Manjaro kernel 5.11.13-1 and lines were added to the PKGBUILD file for the patches.

- 0303-pinctrl-amd2.patch fails to apply with error "Hunk #1 FAILED at 472". This is presumably because the code that the patch is trying to change is not present in 5.11.13-1, if I am right in my interpretation of it.
- 0303-revert-pinctrl_amd_remove_debounce_filter_setting_in_IRQ_type_setting.patch - Successfully validates, applies and I was able to compile and install 5.11.13-1 and the kernel functions on bootup.

However, this too did not resolve the issue. The touchpad failed on bootup in the expected 1-30 reboot range (Got to 9 reboots), just as if no patch were applied. I am out of ideas and need some help from an expert, @Coiby Xu. There is nothing else for me to try and I'm not a programmer so I don't know how to create a solution from scratch.

Thanks for any help moving forward.

Revision history for this message
James Hennig (kissykitty) wrote :

The solution has been found and should have been rather obvious in the first place... Just try a different distribution.

I decided to try out Linux Mint 20.1 and have been testing it for the past ~6 hours, completely stock (except for all updates installed), no kernel modifications or GRUB options and it works every time on bootup with the touchpad. I am rather surprised that such a relatively old kernel (5.4) works with this new-ish laptop. Perhaps this was why I was so falsely focused on having newer kernels available in a distribution in the first place.

I even tried 40 consecutive reboots whilst messing with the touchpad as the machine was booting and it still worked every time. Let it be known that the fix for the Lenovo IdeaPad 3 14ADA05 is to simply install Linux Mint. I have to imagine that other Ubuntu-based installs also work with this particular laptop, especially since it says "Fix Released" under Ubuntu and Ubuntu-related distributions.

As far as Manjaro goes, also let it be known that something was introduced after Kernel 5.9.16-1 which breaks the ability for the touchpad to reliably work with this laptop. My best educated guess is that something is loaded too early or too late during bootup which gets jumbled up at random. No idea what that could possibly be, but I hope that Manjaro devs might take note. I know that at least @Helmut Stult might still be looking in this thread.

I consider this fixed for my laptop :)

Displaying first 40 and last 40 comments. View all 417 comments or add a comment.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.