diff options
author | Arvid Norlander <lkml@vorpal.se> | 2022-09-02 21:00:35 +0300 |
---|---|---|
committer | Hans de Goede <hdegoede@redhat.com> | 2022-09-09 22:58:16 +0300 |
commit | 89655fbb396aff20bd5247fa6b13a689e2f10f9c (patch) | |
tree | 4ff387f530c3682b42cca22139d7d1680ec5fea2 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | c727ba4cd95a12d8e43b02963d3ba4daddbd100c (diff) | |
download | linux-89655fbb396aff20bd5247fa6b13a689e2f10f9c.tar.xz |
platform/x86: Battery charge mode in toshiba_acpi (internals)
This commit adds the internal functions to control the Toshiba laptop.
Unlike for example ThinkPads where this control is granular here it is
just off/on. When off it charges to 100%. When on it charges to about 80%.
Controlling this setting is done via HCI register 0x00ba. Setting to value
1 will result in limiting the charing to 80% of the battery capacity,
while setting it to 0 will allow charging to 100%.
Reading the current state is a bit weird, and needs a 1 set in the last
position of the query for whatever reason. In addition, the read may
return 0x8d20 (Data not available) rarely, so a retry mechanism is needed.
According to the Windows program used to control the feature the setting
will not take effect until the battery has been discharged to around 50%.
However, in my testing it takes effect as soon as the charge drops below
80%. On Windows Toshiba branded this feature as "Eco charging".
Signed-off-by: Arvid Norlander <lkml@vorpal.se>
Link: https://lore.kernel.org/r/20220902180037.1728546-2-lkml@vorpal.se
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions