power: supply: ug3105_battery: Add driver for uPI uG3105 battery monitor
authorHans de Goede <hdegoede@redhat.com>
Sun, 6 Feb 2022 18:35:43 +0000 (19:35 +0100)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Fri, 11 Feb 2022 18:08:35 +0000 (19:08 +0100)
commitf059b46e6fc3eb07e54e2a94912740da49f1d652
treeec3e56c466d945c486382e29a19a9ad8e0792d08
parent4e456230f1ba27deed5a2148bc58c85281d214b7
power: supply: ug3105_battery: Add driver for uPI uG3105 battery monitor

Add a new battery driver for the uPI uG3105 battery monitor.

Note the uG3105 is not a full-featured autonomous fuel-gauge. Instead it
is expected to be use in combination with some always on microcontroller
reading its coulomb-counter before it can wrap (must be read every 400
seconds!).

Since Linux does not monitor coulomb-counter changes while the device is
off or suspended, the coulomb counter is not used atm.

So far this driver is only used on x86/ACPI (non devicetree) devs
(also note there is no of_match table). Therefor there is no devicetree
bindings documentation for this driver's "upisemi,rsns-microohm" property
since this is not used in actual devicetree files and the dt bindings
maintainers have requested properties with no actual dt users to
_not_ be added to the dt bindings.

The property's name has been chosen so that it should not need to be
changed if/when devicetree enumeration support gets added later, as it
mirrors "maxim,rsns-microohm" from the "maxim,max17042" bindings.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/Kconfig
drivers/power/supply/Makefile
drivers/power/supply/ug3105_battery.c [new file with mode: 0644]