]> git.baikalelectronics.ru Git - kernel.git/commit
power: supply: sc27xx: Save last battery capacity
authorYuanjiang Yu <yuanjiang.yu@unisoc.com>
Thu, 6 Dec 2018 03:20:39 +0000 (11:20 +0800)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Thu, 6 Dec 2018 21:24:39 +0000 (22:24 +0100)
commit8b7bcce60331b30d286f4fafe77afd44c2e3234c
tree421ae0e37b05a282fa6083d92bbc666b47d4f756
parentc20069ee51d5e588891cc94ab24846a2a020a455
power: supply: sc27xx: Save last battery capacity

Our charger manager can optimize the battery capacity periodically, so
we can save last battery capacity into registers. Then next system
power-on, we can read the last saved battery capacity as the initial
battery capacity, which can make the battery capacity more accurate.

Signed-off-by: Yuanjiang Yu <yuanjiang.yu@unisoc.com>
Signed-off-by: Baolin Wang <baolin.wang@linaro.org>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/sc27xx_fuel_gauge.c