1
0
Fork 0
alistair23-linux/drivers/power
Tony Lindgren 07ce121158 power: supply: cpcap-battery: Check voltage before orderly_poweroff
[ Upstream commit 639c1524da ]

We can get the low voltage interrupt trigger sometimes way too early,
maybe because of CPU load spikes. This causes orderly_poweroff() be
called too easily.

Let's check the voltage before orderly_poweroff in case it was not
yet a permanent condition. We will be getting more interrupts anyways
if the condition persists.

Let's also show the measured voltages for low battery and battery
empty warnings since we have them.

Cc: Merlijn Wajer <merlijn@wizzup.org>
Cc: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-12-31 16:44:12 +01:00
..
avs power: avs: smartreflex: no need to check return value of debugfs_create functions 2019-06-18 10:54:32 +02:00
reset power: reset: reboot-mode: Fix author email format 2019-09-02 21:05:59 +02:00
supply power: supply: cpcap-battery: Check voltage before orderly_poweroff 2019-12-31 16:44:12 +01:00
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00