helloSystem / ISO

helloSystem Live and installation ISO
https://github.com/helloSystem/
BSD 3-Clause "New" or "Revised" License
809 stars 58 forks source link

ELAN0501 Trackpad choppy after ACPI S3 sleep #100

Open probonopd opened 3 years ago

probonopd commented 3 years ago

ELAN0501 Trackpad choppy after ACPI S3 sleep

probonopd commented 3 years ago

After

sudo kldunload iichid 
sudo kldload iichid 
iichid0: HID descriptor is broken

the trackpad is entirely disfunctional.

How to restart its driver properly?

probonopd commented 3 years ago

https://github.com/wulf7/iichid is upstream?

users-TravelMate-B117-M% uname -v
FreeBSD 12.1-RELEASE r354233 GENERIC 

users-TravelMate-B117-M% sudo dmesg | grep iic
ig4iic_acpi0: <Designware I2C Controller> iomem 0x9131b000-0x9131bfff irq 32 on acpi0
iicbus0: <Philips I2C bus> on ig4iic_acpi0
acpi_iichid0: <HID over I2C (ACPI)> on acpi0
iichid0 at addr 0x15 on iicbus0
iichid0: <ELAN0501:01 04F3:3025 I2C HID device> on iicbus0
iichid0: Interrupt setup failed. Fallback to sampling
hidbus0: <HID bus> on iichid0
ig4iic_acpi0: <Designware I2C Controller> iomem 0x9131b000-0x9131bfff irq 32 on acpi0
iicbus0: <Philips I2C bus> on ig4iic_acpi0
acpi_iichid0: <HID over I2C (ACPI)> on acpi0
iichid0 at addr 0x15 on iicbus0
iichid0: <ELAN0501:01 04F3:3025 I2C HID device> on iicbus0
iichid0: Interrupt setup failed. Fallback to sampling
hidbus0: <HID bus> on iichid0
ig4iic_acpi0: <Designware I2C Controller> iomem 0x9131b000-0x9131bfff irq 32 on acpi0
iicbus0: <Philips I2C bus> on ig4iic_acpi0
acpi_iichid0: <HID over I2C (ACPI)> on acpi0
iichid0 at addr 0x15 on iicbus0
iichid0: <ELAN0501:01 04F3:3025 I2C HID device> on iicbus0
iichid0: Interrupt setup failed. Fallback to sampling
hidbus0: <HID bus> on iichid0
iichid0: detached
iicbus0: <unknown card> at addr 0x15
acpi_iichid0: detached
acpi_iichid0: <HID over I2C (ACPI)> on acpi0
iichid0: HID descriptor is broken
probonopd commented 3 years ago

Need to use 12.2 or 13-CURRENT as per upstream information.

probonopd commented 3 years ago

0.5.0 will be based on 12.2 thanks to @crees. Indeed it is not choppy there after ACPI S3 sleep.

probonopd commented 1 year ago

Seems like the issue has re-appeared in 13.1-RELEASE based helloSystem 0.8.0

iichid0: Interrupt setup failed. Fallback to sampling

Acer TravelMate B

But this time

sudo kldunload iichid 
sudo kldload iichid 

seems to work as a workaround.

dmesg then shows

hconf0: detached
hmt0: detached
hms0: detached
hidbus0: detached
iichid0: detached
iicbus0: <unknown card> at addr 0x15
iichid0: <ELAN0501:01 04F3:3025 I2C HID device> at addr 0x15 on iicbus0
iichid0: Interrupt setup failed. Fallback to sampling
hidbus0: <HID bus> on iichid0
hms0: <ELAN0501:01 04F3:3025 Mouse> on hidbus0
hms0: 33 buttons and [XYWH] coordinates ID=1
hmt0: <ELAN0501:01 04F3:3025 TouchPad> on hidbus0
hconf0: <ELAN0501:01 04F3:3025 Configuration> on hidbus0
hmt0: Multitouch touchpad with 0 external buttons, click-pad
hmt0: 5 contacts with [C] properties. Report range [0:0] - [3206:1782]

and it works.

Can we get this to work without the workaround?

crees commented 1 year ago

How about sticking

kldunload iichid && kldload iichid

In /etc/rc.resume? Off the top of my head the kldunload will fail if it's not loaded so will only load it if it was before.

probonopd commented 1 year ago

Thing with /etc/rc.resume is that it is one of those FreeBSD-provided files that I'd like to leave untouched. Unfortunately there doesn't appear to be a /etc/rc.resume.d/ directory, which would make adding this way easier.

crees commented 1 year ago

Having looked again, an rc.d script with only resume commands would do it, as that's what rc.resume does. I'll write one for you.