2022-09-02 08:45:39

by Martin Kepplinger

[permalink] [raw]
Subject: [PATCH v2 3/6] arm64: dts: imx8mq-librem5: Add bq25895 as max17055's power supply

From: Sebastian Krzyszkowiak <[email protected]>

This allows the userspace to notice that there's not enough
current provided to charge the battery, and also fixes issues
with 0% SOC values being considered invalid.

Signed-off-by: Sebastian Krzyszkowiak <[email protected]>
Signed-off-by: Martin Kepplinger <[email protected]>
---
arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi | 1 +
1 file changed, 1 insertion(+)

diff --git a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi
index 8da7b87c1aa1f..7e6c4ad438092 100644
--- a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi
@@ -1109,6 +1109,7 @@ bat: fuel-gauge@36 {
interrupts = <20 IRQ_TYPE_LEVEL_LOW>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_gauge>;
+ power-supplies = <&bq25895>;
maxim,over-heat-temp = <700>;
maxim,over-volt = <4500>;
maxim,rsns-microohm = <5000>;
--
2.30.2