Message ID | 1348776554-10019-32-git-send-email-mathieu.poirier@linaro.org |
---|---|
State | New |
Headers | show |
diff --git a/drivers/power/ab8500_fg.c b/drivers/power/ab8500_fg.c index 0e71e7e..5e4a46b 100644 --- a/drivers/power/ab8500_fg.c +++ b/drivers/power/ab8500_fg.c @@ -2258,9 +2258,9 @@ static int ab8500_fg_get_ext_psy_data(struct device *dev, void *data) case POWER_SUPPLY_PROP_TECHNOLOGY: switch (ext->type) { case POWER_SUPPLY_TYPE_BATTERY: - if (!di->flags.batt_id_received) { + if (!di->flags.batt_id_received && + di->bat->batt_id != BATTERY_UNKNOWN) { const struct abx500_battery_type *b; - b = &(di->bat->bat_type[di->bat->batt_id]); di->flags.batt_id_received = true;