diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/power/charger-manager.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/power/charger-manager.c b/drivers/power/charger-manager.c index c1ed3c99c059..7098a1ce2d3c 100644 --- a/drivers/power/charger-manager.c +++ b/drivers/power/charger-manager.c @@ -1720,6 +1720,11 @@ static int charger_manager_probe(struct platform_device *pdev) return -EINVAL; } + if (!desc->psy_fuel_gauge) { + dev_err(&pdev->dev, "No fuel gauge power supply defined\n"); + return -EINVAL; + } + /* Counting index only */ while (desc->psy_charger_stat[i]) i++; |