mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 04:34:03 +02:00
power: supply: Add PbAc, NiZn, RAM, and ZnAr support
Add four new members to the POWER_SUPPLY_TECHNOLOGY enum and sysfs interface to represent the Smart Battery Data Specification v1.1 (Section 5.1.30 DeviceChemistry) battery types: - Lead Acid (PbAc) - Nickel Zinc (NiZn) - Rechargeable Alkaline-Manganese (RAM) - Zinc Air (ZnAr) Update documentation to express these types. Update ABI testing for these types. Link: https://sbs-forum.org/specs/sbdat110.pdf Signed-off-by: Boris Shtrasman <borissh1983@gmail.com> Link: https://patch.msgid.link/20260624135718.286771-2-borissh1983@gmail.com Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
This commit is contained in:
parent
5ec27fa6b9
commit
e4426ddf78
|
|
@ -525,7 +525,7 @@ Description:
|
|||
|
||||
Valid values:
|
||||
"Unknown", "NiMH", "Li-ion", "Li-poly", "LiFe",
|
||||
"NiCd", "LiMn"
|
||||
"NiCd", "LiMn", "PbAc", "NiZn", "RAM", "ZnAr"
|
||||
|
||||
|
||||
What: /sys/class/power_supply/<supply_name>/voltage_avg,
|
||||
|
|
|
|||
|
|
@ -124,6 +124,10 @@ static const char * const POWER_SUPPLY_TECHNOLOGY_TEXT[] = {
|
|||
[POWER_SUPPLY_TECHNOLOGY_LiFe] = "LiFe",
|
||||
[POWER_SUPPLY_TECHNOLOGY_NiCd] = "NiCd",
|
||||
[POWER_SUPPLY_TECHNOLOGY_LiMn] = "LiMn",
|
||||
[POWER_SUPPLY_TECHNOLOGY_PbAc] = "PbAc",
|
||||
[POWER_SUPPLY_TECHNOLOGY_NiZn] = "NiZn",
|
||||
[POWER_SUPPLY_TECHNOLOGY_RAM] = "RAM",
|
||||
[POWER_SUPPLY_TECHNOLOGY_ZnAr] = "ZnAr",
|
||||
};
|
||||
|
||||
static const char * const POWER_SUPPLY_CAPACITY_LEVEL_TEXT[] = {
|
||||
|
|
|
|||
|
|
@ -83,6 +83,10 @@ enum {
|
|||
POWER_SUPPLY_TECHNOLOGY_LiFe,
|
||||
POWER_SUPPLY_TECHNOLOGY_NiCd,
|
||||
POWER_SUPPLY_TECHNOLOGY_LiMn,
|
||||
POWER_SUPPLY_TECHNOLOGY_PbAc,
|
||||
POWER_SUPPLY_TECHNOLOGY_NiZn,
|
||||
POWER_SUPPLY_TECHNOLOGY_RAM,
|
||||
POWER_SUPPLY_TECHNOLOGY_ZnAr,
|
||||
};
|
||||
|
||||
enum {
|
||||
|
|
|
|||
|
|
@ -74,7 +74,8 @@ for DEVNAME in $supplies; do
|
|||
test_sysfs_prop_optional model_name
|
||||
test_sysfs_prop_optional manufacturer
|
||||
test_sysfs_prop_optional serial_number
|
||||
test_sysfs_prop_optional_list technology "Unknown","NiMH","Li-ion","Li-poly","LiFe","NiCd","LiMn"
|
||||
test_sysfs_prop_optional_list technology "Unknown","NiMH","Li-ion","Li-poly","LiFe","NiCd"\
|
||||
,"LiMn","PbAc","NiZn","RAM","ZnAr"
|
||||
|
||||
test_sysfs_prop_optional cycle_count
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user