Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 81101090 authored by David Keitel's avatar David Keitel
Browse files

power: add qpnp fuel gauge driver



This adds the driver to support the
fuel gauge peripheral on PMI8994.

The initial driver is able to supply userspace
with the following properties via the power supply
framework.

  * POWER_SUPPLY_PROP_CAPACITY:
    - The state of charge of the battery in percent.
  * POWER_SUPPLY_PROP_CURRENT_NOW:
    - The battery current with 32 mA resolution.
  * POWER_SUPPLY_PROP_VOLTAGE_NOW:
    - The battery voltage with 32 mV resolution.

The fuel gauge driver wakes up the system if
either FULL (100%) or EMPTY (0%) state of charge (SOC)
has been reached to allow userspace to take appropriate
action.

In addition to this there are also non-wakeable interrupts
for each SOC change via the DELTA_SOC interrupt.

Each SOC change is conveyed to consumers via the power_supply
framework. If a given kernel driver needs to subscribe to
these events, one must expand the fg_supplicants string array.

Change-Id: I633cf48b4b3c0b1389327a8272b6df974fa03808
Signed-off-by: default avatarDavid Keitel <dkeitel@codeaurora.org>
parent f98fc1b2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment