Skip to content

Commit 779873e

Browse files
harshimogalapallisre
authored andcommitted
power: supply: mt6370: Fix missing error code in mt6370_chg_toggle_cfo()
When mt6370_chg_field_get() suceeds, ret is set to zero and returning zero when flash led is still in strobe mode looks incorrect. Fixes: 233cb8a ("power: supply: mt6370: Add MediaTek MT6370 charger driver") Signed-off-by: Harshit Mogalapalli <[email protected]> Reviewed-by: AngeloGioacchino Del Regno <[email protected]> Reviewed-by: ChiaEn Wu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Sebastian Reichel <[email protected]>
1 parent dc77721 commit 779873e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/power/supply/mt6370-charger.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,7 @@ static int mt6370_chg_toggle_cfo(struct mt6370_priv *priv)
324324

325325
if (fl_strobe) {
326326
dev_err(priv->dev, "Flash led is still in strobe mode\n");
327-
return ret;
327+
return -EINVAL;
328328
}
329329

330330
/* cfo off */

0 commit comments

Comments
 (0)