Most recent kernel where this bug did *NOT* occur: none known Distribution: Gentoo Hardware Environment: ASUS laptop with Intel 82801 chipset Problem Description: When the system is suspended to disk, the battery state is not refreshed afterwards, i.e. if the battery is inserted while the computer is powered off, ACPI does not know it's there or how full it is. Steps to reproduce: - cat /proc/acpi/battery/*/state - Remove battery - echo -n disk > /sys/power/state - Insert battery - cat /proc/acpi/battery/*/state (battery is still reported as not present) This may be related to bug 4132
Please try 2.6.21 kernel and the last 'mm' kernel, attach acpidump and dmesg output. Please 'cat /proc/acpi/battery/*' few times and attach the results.
Created attachment 11282 [details] acpidump with 2.6.20, battery not present I cannot change kernels at the moment, but I will do some more testing tomorrow.
Please attach 2.6.20 dmesg output.
Created attachment 11288 [details] dmesg with 2.6.20, battery not present
Created attachment 11293 [details] dmesg with 2.6.21
Created attachment 11294 [details] acpidump with 2.6.21, battery not present
Created attachment 11295 [details] BAT0/* with 2.6.21, battery not present
Created attachment 11296 [details] acpidump with 2.6.21, after inserting battery in suspend
Created attachment 11297 [details] BAT0/* with 2.6.21, after inserting battery in suspend
Created attachment 11298 [details] acpidump with 2.6.21, battery present
Created attachment 11299 [details] BAT0/* with 2.6.21, battery present
Created attachment 11300 [details] acpidump with 2.6.21, after removing battery in suspend
Created attachment 11301 [details] BAT0/* with 2.6.21, after removing battery in suspend
Created attachment 11302 [details] dmesg with 2.6.21-rc7-mm2
Created attachment 11303 [details] acpidump with 2.6.21-rc7-mm2, after removing battery in suspend
Created attachment 11304 [details] BAT0/* with 2.6.21-rc7-mm2, after removing battery in suspend In this case, ACPI seems to actually notice the battery is missing, which did not happen in 2.6.20 or 2.6.21. When inserting the battery during suspend with 2.6.21-rc7-mm2, the behavior looks just like 2.6.21 to me. If you want me to attach the other acpidumps for the mm kernel as well, let me know.
Please perform the following testing: a) remove battery suspend insert battery resume cat /proc/acpi/battery/*/* and /proc/acpi/ac_adapter/*/* unplug/plug AC cable cat /proc/acpi/battery/*/* and /proc/acpi/ac_adapter/*/* send 'cat' output and dmesg b) remove battery suspend insert battery resume cat /proc/acpi/battery/*/* and /proc/acpi/ac_adapter/*/* wait for 5 minutes cat /proc/acpi/battery/*/* and /proc/acpi/ac_adapter/*/* send 'cat' output and dmesg Please test both kernels - 2.6.21 and 2.6.21-rc7-mm2.
Please test with 2.6.21, 2.6.22-rc*, or something later. If this issue still exists, please re-open this bug report.
Created attachment 11557 [details] first test from comment #17 (2.6.21)
Created attachment 11558 [details] second test from comment #17 (2.6.21)
Comment on attachment 11557 [details] first test from comment #17 (2.6.21) test passed
Comment on attachment 11558 [details] second test from comment #17 (2.6.21) test failed
Can you please try 2.6.22-rc3 with the patchset from http://www.sisk.pl/kernel/hibernation_and_suspend/2.6.22-rc3/patches/ applied?
Created attachment 11676 [details] output of patch -p1 For some strange reason some of the patches failagainst a vanilla 2.6.22-rc3. Should I apply them anyway?
Comment on attachment 11676 [details] output of patch -p1 Sorry, too dumb to patch. I'll be testing it now.
Created attachment 11678 [details] first test Again, the battery is only detected after toggling the AC adaptor
Created attachment 11679 [details] second test Battery is not detected at all. To me (dummy), everything looks the same as with 2.6.21.
Can you please try the 2.6.23-rc2 kernel?
Please reopen this bug if it's still present with kernel 2.6.23-rc6.