Bug 1027059
Summary: | laptop hibernates after resuming from suspend | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Samuel Sieb <samuel-rhbugs> |
Component: | upower | Assignee: | systemd-maint |
Status: | CLOSED EOL | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | 19 | CC: | johannbg, lnykryn, msekleta, plautrba, rdieter, rhughes, systemd-maint, vpavlin, zbyszek |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2015-02-17 19:05:09 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Samuel Sieb
2013-11-06 03:08:56 UTC
I can now verify that it happens every time I both suspend while on battery and then resume while still on battery. If one of the suspend or resume is while plugged in, it doesn't happen. What appears to be happening is that upower is trying to get the battery state too soon after resuming and the sys tree for the battery isn't there yet. It doesn't recognize that, so as far as I can tell from the code it will be determining that the battery is empty. This then triggers something (probably gnome) to go to hibernate. The gnome control panel offers either hibernate or power off on low battery so I can't disable it! Actually, I found it in dconf, so for now I have it disabled, which is not ideal either. On the code side, this may be a little tricky to fix. The code that gets values from sysfs doesn't check for errors, it just returns 0. So there's no way to indicate that the file wasn't actually there to read from. Maybe at the top of the function check that the directory exists before trying to do anything else? I discovered the "upower -d" command. Here's the output right after resuming: Device: /org/freedesktop/UPower/devices/battery_BAT0 native-path: /sys/devices/LNXSYSTM:00/device:00/PNP0C0A:00/power_supply/BAT0 power supply: yes updated: Fri Nov 8 12:25:09 2013 (0 seconds ago) has history: yes has statistics: yes battery present: yes rechargeable: yes state: empty energy: 0 Wh energy-empty: 0 Wh energy-full: 0 Wh energy-full-design: 0 Wh energy-rate: 0 W percentage: 0% capacity: 100% History (rate): 1383942309 15.250 discharging 1383942309 0.000 unknown 1383942309 0.000 empty 1383942220 15.962 discharging 1383942198 17.302 discharging My analysis was correct, I'll file a bug upstream. see also bug #1025980 where I see odd bahaviors due to upower reporting: state: fully-charged percentage: 0% at least upower is being consistent here. (reporting both empty/0%) This message is a notice that Fedora 19 is now at end of life. Fedora has stopped maintaining and issuing updates for Fedora 19. It is Fedora's policy to close all bug reports from releases that are no longer maintained. Approximately 4 (four) weeks from now this bug will be closed as EOL if it remains open with a Fedora 'version' of '19'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 19 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed. |