Bug 217152 - [Regression] acpi: laptop panics early on boot
Summary: [Regression] acpi: laptop panics early on boot
Status: RESOLVED PATCH_ALREADY_AVAILABLE
Alias: None
Product: ACPI
Classification: Unclassified
Component: Power-Battery (show other bugs)
Hardware: All Linux
: P1 high
Assignee: acpi_power-battery
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-03-06 21:33 UTC by Pierre Asselin
Modified: 2023-03-28 00:35 UTC (History)
0 users

See Also:
Kernel Version: 6.0
Subsystem:
Regression: Yes
Bisected commit-id:


Attachments

Description Pierre Asselin 2023-03-06 21:33:44 UTC
>Laptop panics when booting on AC power.
>
>The laptop is on Gentoo; upgrading from 5.15.88 to 6.1.12, the kernel
>panics before reaching early userspace.  I find no other report like
>this on the Gentoo, arch, mint, or Ubuntu forums, on kernel.org, or out
>of duckduckgo.  This is a regression (because, you know, the kernel used
>to boot) but so far it's only me, and only on my 16-year old laptop.
>Also, I have a workaround.
>
>Image of the panic screen at
>https://www.panix.com/~pa/linux-6.1.12-crash/boot-failure.jpg .
>
>Seeing acpi_ac_notify() near the top of the traceback, I tried booting on
>battery power.  Works fine.  The panic occurs only when booting on AC power,
>whether or not a battery is present.  Sometimes, rarely, it boots fine
>even on AC, but that is the exception not the rule.
>
>Based on comments in drivers/acpi/ac.c I tried a trivial patch,
>
>       --- drivers/acpi/ac.c.orig      2022-12-11 17:15:18.000000000 -0500
>       +++ drivers/acpi/ac.c   2023-02-19 17:38:06.958733031 -0500
>       @@ -47,7 +47,7 @@ static int acpi_ac_resume(struct device
>        #endif
>        static SIMPLE_DEV_PM_OPS(acpi_ac_pm, NULL, acpi_ac_resume);
>        
>       -static int ac_sleep_before_get_state_ms;
>       +static int ac_sleep_before_get_state_ms = 1000;
>        static int ac_only;
>        
>        static struct acpi_driver acpi_ac_driver = {
>
>and it works.  This is probably not the right fix but it will be my
>workaround for the time being.
>
>Problem is still present in 6.3-rc1 .  Bisecting, the first bad commit
>is d6fb6ee1820c .
>
>The starting config (from 5.15.88) is at 
>https://www.panix.com/~pa/linux-6.1.12-crash/config-base .
>The test is make olddefconfig, make bzImage, then kexec the bzImage with an
>initramfs to see if it reaches the rescueshell prompt.  Has to succeed
>three times to be declared good.
>
>In case I forgot something, here is my post on the Gentoo forums:
>https://forums.gentoo.org/viewtopic-t-1161834-highlight-.html
Comment 1 Pierre Asselin 2023-03-08 16:06:18 UTC
Corrections: 1) is a regression; 2) in kernel 6.0, not 5.19-rc4.
Comment 2 Pierre Asselin 2023-03-28 00:35:26 UTC
Patch queued for 6.3-rc5

https://patchwork.kernel.org/project/linux-acpi/patch/5687037.DvuYhMxLoT@kreacher/

Marking as Resolved (if I can...)

Note You need to log in before you can comment on or make changes to this bug.