You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
power_supply: Add a charge_type property, and use it for olpc driver
This adds a new sysfs file called 'charge_type' which displays the type of charging (unknown, n/a, trickle charge, or fast charging). This allows things like battery diagnostics to determine what the battery/EC is doing without resorting to changing the 'status' sysfs output. Signed-off-by: Andres Salomon <dilinger@collabora.co.uk> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Anton Vorontsov <cbouatmailru@gmail.com>
This commit is contained in:
committed by
Anton Vorontsov
parent
144bbeaedc
commit
ee8076ed3e
@@ -38,6 +38,13 @@ enum {
|
||||
POWER_SUPPLY_STATUS_FULL,
|
||||
};
|
||||
|
||||
enum {
|
||||
POWER_SUPPLY_CHARGE_TYPE_UNKNOWN = 0,
|
||||
POWER_SUPPLY_CHARGE_TYPE_NONE,
|
||||
POWER_SUPPLY_CHARGE_TYPE_TRICKLE,
|
||||
POWER_SUPPLY_CHARGE_TYPE_FAST,
|
||||
};
|
||||
|
||||
enum {
|
||||
POWER_SUPPLY_HEALTH_UNKNOWN = 0,
|
||||
POWER_SUPPLY_HEALTH_GOOD,
|
||||
@@ -70,6 +77,7 @@ enum {
|
||||
enum power_supply_property {
|
||||
/* Properties of type `int' */
|
||||
POWER_SUPPLY_PROP_STATUS = 0,
|
||||
POWER_SUPPLY_PROP_CHARGE_TYPE,
|
||||
POWER_SUPPLY_PROP_HEALTH,
|
||||
POWER_SUPPLY_PROP_PRESENT,
|
||||
POWER_SUPPLY_PROP_ONLINE,
|
||||
|
||||
Reference in New Issue
Block a user