kernel-6.15 randomly shutting down system on bogus power button events
I am seeing an issue where (in Fedora Rawhide) the following kernels:
kernel-6.15.0-0.rc0.20250327git1a9239bb4253.5.fc43.x86_64 kernel-6.15.0-0.rc0.20250401git08733088b566.8.fc43.x86_64
are randomly shutting the system down because bogus power button events are being received every 10 minutes to about 2 hours. My actual power button generates an event2, while the bogus events are arriving as event1.
Latest available 6.14 kernel:
kernel-6.14.0-0.rc7.20250321gitb3ee1e460951.60.fc43.x86_64
does not suffer from this issue.
Using 'sudo evtest --grab /dev/input/event1' I am able to prevent the system from shutting down and also record the bogus events.
The RedHat Bugzilla entry has more details and also links to a thread on the Fedora test mailing list:
https://bugzilla.redhat.com/show_bug.cgi?id=2357044
--
Ian Laurie
FAS: nixuser | IRC: nixuser
TZ: Australia/Sydney
Rafael J. Wysocki
maintainerQuoted 16 lines · Ian Laurie
I am seeing an issue where (in Fedora Rawhide) the following kernels:
kernel-6.15.0-0.rc0.20250327git1a9239bb4253.5.fc43.x86_64 kernel-6.15.0-0.rc0.20250401git08733088b566.8.fc43.x86_64
are randomly shutting the system down because bogus power button events are being received every 10 minutes to about 2 hours. My actual power button generates an event2, while the bogus events are arriving as event1.
Latest available 6.14 kernel:
kernel-6.14.0-0.rc7.20250321gitb3ee1e460951.60.fc43.x86_64
does not suffer from this issue.
Quoted 7 lines
Using 'sudo evtest --grab
/dev/input/event1' I am able to prevent the system from shutting down and also record the bogus events.The RedHat Bugzilla entry has more details and also links to a thread on the Fedora test mailing list:
I would try to revert the following commit and see if that helps:
commit a7e23ec17feecc7bac0d500cea900cace7b50129
Author: Mario Limonciello <[email protected]> Date: Mon Mar 3 15:27:09 2025 -0600
ACPI: button: Install notifier for system events as well
On some systems when the system is put to sleep pressing the ACPI power button will cause the EC SCI to try to wake the system by a Notify(DEV, 0x2) with an intention to wake the system up from suspend.
This behavior matches the ACPI specification in ACPI 6.4 section 4.8.3.1.1.2 which describes that the AML handler would generate a Notify() with a code of 0x2 to indicate it was responsible for waking the system.
This currently doesn't work because acpi_button_add() only configured ACPI_DEVICE_NOTIFY which means that device handler notifications 0x80 through 0xFF are handled.
To fix the wakeups on such systems, adjust the ACPI button handler to use ACPI_ALL_NOTIFY which will handle all events 0x00 through 0x7F.
+ Yijun (awareness)
Quoted 41 lines · Rafael J. Wysocki
Quoted 16 lines · Ian Laurie
I am seeing an issue where (in Fedora Rawhide) the following kernels:
kernel-6.15.0-0.rc0.20250327git1a9239bb4253.5.fc43.x86_64 kernel-6.15.0-0.rc0.20250401git08733088b566.8.fc43.x86_64
are randomly shutting the system down because bogus power button events are being received every 10 minutes to about 2 hours. My actual power button generates an event2, while the bogus events are arriving as event1.
Latest available 6.14 kernel:
kernel-6.14.0-0.rc7.20250321gitb3ee1e460951.60.fc43.x86_64
does not suffer from this issue.
Quoted 7 lines
Using 'sudo evtest --grab
/dev/input/event1' I am able to prevent the system from shutting down and also record the bogus events.The RedHat Bugzilla entry has more details and also links to a thread on the Fedora test mailing list:
I would try to revert the following commit and see if that helps:
commit
a7e23ec17feecc7bac0d500cea900cace7b50129Author: Mario Limonciello <[email protected]> Date: Mon Mar 3 15:27:09 2025 -0600ACPI: button: Install notifier for system events as well
On some systems when the system is put to sleep pressing the ACPI power button will cause the EC SCI to try to wake the system by a
Notify(DEV, 0x2)with an intention to wake the system up from suspend.This behavior matches the ACPI specification in ACPI 6.4 section 4.8.3.1.1.2 which describes that the AML handler would generate a
Notify()with a code of0x2to indicate it was responsible for waking the system.
Quoted 6 lines
This currently doesn't work because
acpi_button_add()only configuredACPI_DEVICE_NOTIFYwhich means that device handler notifications0x80through0xFFare handled.To fix the wakeups on such systems, adjust the ACPI button handler to use
ACPI_ALL_NOTIFYwhich will handle all events0x00through0x7F.
Yeah I think that's a very likely candidate from what you describe.
I'd like to understand how this is actually happening to decide what we should do about it. I'll subscribe to the bug report and we can go back and forth there.
1) Could you please add an acpidump into the bug report?
2) Can you please use acpica tracing to determine what is happening when this notify event comes in? The basic way to do it:
echo 0x00000004 | sudo tee /sys/module/acpi/parameters/trace_debug_layer echo 0x00000004 | sudo tee /sys/module/acpi/parameters/trace_debug_level echo enable | sudo tee /sys/module/acpi/parameters/trace_state
This should then save to the journal the associated event info.