Skip to content

Commit 7e6311f

Browse files
kcxtsre
authored andcommitted
power: supply: qcom_pmi8998_charger: fix charger status
The INHIBIT_CHARGE status bit means the battery has reached a pre-programmed charge limit which is some voltage offset below the target float voltage. This should be reported as a STATUS_FULL rather than UNKNOWN, fix it. Signed-off-by: Caleb Connolly <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Sebastian Reichel <[email protected]>
1 parent f57f583 commit 7e6311f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/power/supply/qcom_pmi8998_charger.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -517,9 +517,9 @@ static int smb2_get_prop_status(struct smb2_chip *chip, int *val)
517517
*val = POWER_SUPPLY_STATUS_NOT_CHARGING;
518518
return rc;
519519
case TERMINATE_CHARGE:
520+
case INHIBIT_CHARGE:
520521
*val = POWER_SUPPLY_STATUS_FULL;
521522
return rc;
522-
case INHIBIT_CHARGE:
523523
default:
524524
*val = POWER_SUPPLY_STATUS_UNKNOWN;
525525
return rc;

0 commit comments

Comments
 (0)