power: supply: qcom_battmgr: add OOI chemistry
authorChristopher Ruehl <chris.ruehl@gtsys.com.hk>
Mon, 11 Aug 2025 15:22:09 +0000 (17:22 +0200)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Sat, 6 Sep 2025 21:25:31 +0000 (23:25 +0200)
The ASUS S15 xElite model report the Li-ion battery with an OOI, hence this
update the detection and return the appropriate type.

Signed-off-by: Christopher Ruehl <chris.ruehl@gtsys.com.hk>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/qcom_battmgr.c

index 99808ea..fdb2d1b 100644 (file)
@@ -982,7 +982,8 @@ static void qcom_battmgr_sc8280xp_strcpy(char *dest, const char *src)
 
 static unsigned int qcom_battmgr_sc8280xp_parse_technology(const char *chemistry)
 {
-       if (!strncmp(chemistry, "LIO", BATTMGR_CHEMISTRY_LEN))
+       if ((!strncmp(chemistry, "LIO", BATTMGR_CHEMISTRY_LEN)) ||
+           (!strncmp(chemistry, "OOI", BATTMGR_CHEMISTRY_LEN)))
                return POWER_SUPPLY_TECHNOLOGY_LION;
        if (!strncmp(chemistry, "LIP", BATTMGR_CHEMISTRY_LEN))
                return POWER_SUPPLY_TECHNOLOGY_LIPO;