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

Commit 7d464caf authored by Subbaraman Narayanamurthy's avatar Subbaraman Narayanamurthy Committed by Vamshi Krishna B V
Browse files

power_supply: add cycle_counts property



Currently, cycle_count and cycle_count_id are used to get the
cycle counter per SOC bucket. Add a string property cycle_counts
that can return all the cycle counters at once without the client
setting cycle_count_id.

CRs-Fixed: 2225336
Change-Id: If3014a4f865f94dc0895c1f5f7068ce936a0b62d
Signed-off-by: default avatarSubbaraman Narayanamurthy <subbaram@codeaurora.org>
Signed-off-by: default avatarVamshi Krishna B V <vbv@codeaurora.org>
parent 390aa5e7
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -337,6 +337,7 @@ static struct device_attribute power_supply_attrs[] = {
	POWER_SUPPLY_ATTR(manufacturer),
	POWER_SUPPLY_ATTR(serial_number),
	POWER_SUPPLY_ATTR(battery_type),
	POWER_SUPPLY_ATTR(cycle_counts),
};

static struct attribute *
+1 −0
Original line number Diff line number Diff line
@@ -288,6 +288,7 @@ enum power_supply_property {
	POWER_SUPPLY_PROP_MANUFACTURER,
	POWER_SUPPLY_PROP_SERIAL_NUMBER,
	POWER_SUPPLY_PROP_BATTERY_TYPE,
	POWER_SUPPLY_PROP_CYCLE_COUNTS,
};

enum power_supply_type {