Take charge thresholds into account when calculating battery full state
UPower was calculating a wrong "charging" state if the state was reported as unknown by the kernel. The kernel side was fixed for ThinkPad laptops, and it now correctly reports that the battery is not charging.
However, that still leaves open the issue of a battery not charging because it was configured to not charge above a certain threshold. This should be considered as full.
i.e. anything above charge_start_threshold
should be considered full.
Version 0.99.11
When I set a charge limit of 90% on my Lenovo ThinkPad X1 Yoga gen 3, charging actually stops at 89%, not 90%.
Output of upower --dump
:
This was investigated downstream in https://bugs.kde.org/show_bug.cgi?id=435931 and determined to likely be an issue in upower.