[Pkg-utopia-maintainers] Bug#870442: upower lazy about critical-action

Brian Ristuccia brian at ristuccia.com
Wed Aug 2 00:48:22 UTC 2017


Package: upower
Version: 0.99.4-4+b1
Severity: critical
Justification: causes serious data loss

    * When the charge level is below PercentageAction or TimeAction as
applicable, upower fails to be sufficiently aggressive about hibernating the
system.
    * When hibernation fails, the system can shut down abruptly, 
resulting in
loss of all unsaved data.
    * On some systems, running down the battery completely erases firmware
confirguration information, rendering the system unbootable.

A few examples of cases where it fails:

    * On my Acer UX32VD, upower will hybrid suspend the system on low 
battery.
When the battery reaches a critical level during suspend, the system 
wakes up
and then runs until the battery is completely dead. This can happen even 
with
the lid closed while the system is in a bag or briefcase, which can cause
elevated temperatures. The BIOS configuration including UEFI boot options is
lost.
    * Plugging in a charger briefly and then unplugging it may forestall
suspending, then the system will then run until the battery is 
completely dead.
    * Waking a hybrid suspended system without first connecting a 
charger can
cause it to run until the battery is completely dead. This problem is easily
triggered if the user is actively typing at the time of suspend.
    * If a system is woken from hibernation with a critically low battery,
upower does not try to re-hibernate it.
    * There is no facility to block resume on a critically low battery 
early in
the boot process, thus a resume image can be "wasted" by consuming it 
with no
hope of continued execution.

Here's the behavior I expect:

    * upower should aggressively try the critical action if the battery has
reached the critical action level and no charger is connected
    * upower should run the critical action if a charger is disconnected for
more than a few seconds while the battery is still below the critical action
level
    * If the system wakes up from hybrid suspend (or fails to hybrid 
suspend)
with a critical battery and no charger connected, it should be immediately
hibernated
    * If the system wakes up from hibernation with a critical battery and no
charger connected, it should be immediately re-hibernated
    * Early in the initramfs, upower should check the battery status and 
block
bootup if the battery is critical and no charger is connected




-- System Information:
Debian Release: 9.1
   APT prefers stable
   APT policy: (500, 'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 4.11.0-0.bpo.1-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages upower depends on:
ii  dbus               1.10.18-1
ii  libc6              2.24-11+deb9u1
ii  libglib2.0-0       2.50.3-2
ii  libgudev-1.0-0     230-3
ii  libimobiledevice6  1.2.0+dfsg-3.1
ii  libplist3          1.12+git+1+e37ca00-0.3
ii  libupower-glib3    0.99.4-4+b1
ii  libusb-1.0-0       2:1.0.21-1
ii  udev               232-25+deb9u1

Versions of packages upower recommends:
ii  policykit-1  0.105-18

upower suggests no packages.

-- Configuration Files:
/etc/UPower/UPower.conf changed [not included]

-- no debconf information



More information about the Pkg-utopia-maintainers mailing list