[PATCH 0/2] power: supply: qcom_battmgr: Add thermal mitigation support
From: DhruvinRajpura
Date: Tue Jun 09 2026 - 05:24:03 EST
Commit c85c191694cb ("power: supply: remove faulty cooling logic")
removed automatic cooling device registration from the power supply
framework. As a result, drivers requiring thermal mitigation must now
explicitly register their own cooling devices with correct semantics.
This series adds thermal mitigation support to the Qualcomm PMIC GLink
battery manager driver by registering a thermal cooling device that
controls the battery fast charge current (FCC) in response to thermal
events. The cooling states map to discrete current limits defined in
the qcom,thermal-mitigation DT property, with state 0 representing the
hardware maximum current queried from firmware and each subsequent state
reducing the current to the next DT-defined value.
The series is structured as follows:
- Patch 1 documents the new qcom,thermal-mitigation DT property in
the qcom,pmic-glink.yaml binding file.
- Patch 2 implements the thermal cooling device registration in the
qcom_battmgr driver, including FCC control via firmware, PDR
restart resilience, and power supply property exposure.
The implementation has been validated on a target where setting the
cooling state via sysfs correctly reduces the observed battery charging
current as expected.
Signed-off-by: Dhruvin Rajpura <drajpura@xxxxxxxxxxxxxxxx>
---
Dhruvin Rajpura (2):
bindings: power: supply: qcom,pmic-glink: Document thermal-mitigation
power: supply: qcom_battmgr: Add thermal mitigation support
.../bindings/soc/qcom/qcom,pmic-glink.yaml | 10 +
drivers/power/supply/qcom_battmgr.c | 256 +++++++++++++++++++++
2 files changed, 266 insertions(+)
---
base-commit: e7ae89a0c97ce2b68b0983cd01eda67cf373517d
change-id: 20260609-cooling_device_reg-8e95c8eaab80
Best regards,
--
DhruvinRajpura <drajpura@xxxxxxxxxxxxxxxx>