Evgeny Zinoviev has uploaded a new patch set (#25) to the change originally created by Alexey Derlaft. ( https://review.coreboot.org/c/coreboot/+/23178 )
Change subject: ec/lenovo/h8: Implement ACPI methods to set battery thresholds ......................................................................
ec/lenovo/h8: Implement ACPI methods to set battery thresholds
There are two known (yet) different ways to manage battery thresholds. This patch implements them and adds a way to enable them for different mainboards.
Tested on W530 with 4.18.3-gentoo kernel. Works fine with new Linux userspace API for controlling battery thresholds, available since 4.17. (/sys/class/power_supply/BAT0/charge_(start|stop)_threshold).
The new API is supported by TLP (you might need to set NATACPI_ENABLE=1 in /etc/tlp.conf).
tpacpi-bat works fine too.
Change-Id: I2a90f9e9b32462b8a5e9bc8d3087ae0fea563ea5 Signed-off-by: Alexey Kharlamov der@2-47.ru Signed-off-by: Evgeny Zinoviev me@ch1p.com --- M src/ec/lenovo/h8/Kconfig M src/ec/lenovo/h8/acpi/thinkpad.asl A src/ec/lenovo/h8/acpi/thinkpad_bat_thresholds.asl A src/ec/lenovo/h8/acpi/thinkpad_bat_thresholds_24.asl A src/ec/lenovo/h8/acpi/thinkpad_bat_thresholds_b0.asl M src/mainboard/lenovo/t400/Kconfig M src/mainboard/lenovo/t400/acpi/ec.asl M src/mainboard/lenovo/t420/Kconfig M src/mainboard/lenovo/t420/acpi/ec.asl M src/mainboard/lenovo/t420s/Kconfig M src/mainboard/lenovo/t420s/acpi/ec.asl M src/mainboard/lenovo/t430/Kconfig M src/mainboard/lenovo/t430/acpi/ec.asl M src/mainboard/lenovo/t430s/Kconfig M src/mainboard/lenovo/t430s/acpi/ec.asl M src/mainboard/lenovo/t520/Kconfig M src/mainboard/lenovo/t520/acpi/ec.asl M src/mainboard/lenovo/t530/Kconfig M src/mainboard/lenovo/t530/acpi/ec.asl M src/mainboard/lenovo/x1_carbon_gen1/Kconfig M src/mainboard/lenovo/x1_carbon_gen1/acpi/ec.asl M src/mainboard/lenovo/x200/Kconfig M src/mainboard/lenovo/x200/acpi/ec.asl M src/mainboard/lenovo/x201/Kconfig M src/mainboard/lenovo/x201/acpi/ec.asl M src/mainboard/lenovo/x220/Kconfig M src/mainboard/lenovo/x220/acpi/ec.asl M src/mainboard/lenovo/x230/Kconfig M src/mainboard/lenovo/x230/acpi/ec.asl 29 files changed, 461 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/78/23178/25