Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 436966

Summary: sys-kernel/vanilla-sources-3.4.9 - battery drains after Gentoo poweroff with acpi=on
Product: Gentoo Linux Reporter: larophel <larophel>
Component: [OLD] Core systemAssignee: Gentoo Kernel Bug Wranglers and Kernel Maintainers <kernel>
Status: RESOLVED WONTFIX    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: emerge --info
Kernel Config Vanilla Sources 3.4.9
Output of dmesg

Description larophel 2012-10-02 14:36:46 UTC
Created attachment 325532 [details]
emerge --info

I got a new laptop a while ago, and have been having the issue that the battery drains while the laptop is off.
By "off", I mean a full shutdown (e.g. shutdown -h now).
Over an eight hour off-period, the battery discharges around 15-20%.

This seems to be a Gentoo / ACPI-specific issue, because it does not happen if I shutdown the laptop from Windows or from an Ubuntu 12.04.1 Live-CD.
It also does not happen if I boot Gentoo with the "acpi=off" kernel parameter, and then perform a shutdown.
I have tried various things to solve this, but have been unsuccessful:

1. Replace the battery.
2. Upgrade from kernel 3.2.12 gentoo sources to 3.4.9 vanilla sources.
3. Disable all power / wakeup related features in the laptop's BIOS.
4. Disable wake-on-lan using the command "ethtool -s eth0 wol d".
5. Disable all wake-up actions in /proc/acpi/wakeup.
6. Disable bluetooth using "echo 1 > /sys/devices/LNXSYSTM:00/device:00/TOS6208:00/rfkill/rfkill1/state".
7. Disable the wlan adapter using the FN+F8 hotkey. 
8. Disable the lan-adapter completely in the kernel. 

Here's my kernel .config: http://pastebin.com/NRzK85bp
Here's my dmesg output: http://pastebin.com/BW4fE4tG
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2012-10-02 14:45:43 UTC
(In reply to comment #0)

> Here's my kernel .config: http://pastebin.com/NRzK85bp
> Here's my dmesg output: http://pastebin.com/BW4fE4tG

Please attach those files to this bug report.
Comment 2 larophel 2012-10-02 15:04:46 UTC
Created attachment 325536 [details]
Kernel Config Vanilla Sources 3.4.9
Comment 3 larophel 2012-10-02 15:05:14 UTC
Created attachment 325538 [details]
Output of dmesg
Comment 4 larophel 2012-10-02 15:07:27 UTC
(In reply to comment #1)

> Please attach those files to this bug report.

Done. 
Please note that this problem also happened with Gentoo sources 3.2.12.
Comment 5 Mike Pagano gentoo-dev 2012-10-11 23:55:22 UTC
laptop manufacturer and model?
Comment 6 larophel 2012-10-12 00:00:33 UTC
Toshiba Qosmio F755-3D350.
Comment 7 larophel 2012-11-16 14:15:37 UTC
I finally found the cause of the issue: the command "hwclock --systohc --local" causes the battery to drain when the laptop is off.
This command is executed by the /etc/init.d/hwclock script.
If I set clock_hctosys="NO" in /etc/conf.d/hwclock, that command does not get executed anymore, and the battery does not drain.
Comment 8 Tom Wijsman (TomWij) (RETIRED) gentoo-dev 2012-11-17 01:06:44 UTC
Sounds like broken hardware, glad you've got it fixed.

If you believe this could be fixed in the kernel (I doubt it, as you're using hwclock), then feel free to report this upstream and leave a link to the upstream bug here as a reference. Otherwise this bug will suffice as a reference point for future people experiencing the bug.

Since I don't think this is a kernel bug, it might not be worth fixing and there's a sufficient workaround; I'm closing this as WONTFIX for now.