diff options
author | Rong Dian <b38775@freescale.com> | 2012-09-12 10:12:01 +0800 |
---|---|---|
committer | Rong Dian <b38775@freescale.com> | 2012-09-12 14:10:47 +0800 |
commit | 32c701b585adacd31ae9b25954f1e96f994cc4ae (patch) | |
tree | 8876ada174ff92154464f12e31c9d9c11e3b3fba /drivers/power | |
parent | fb4aa1bb751bac62deff8cca5c7985c25fcba982 (diff) |
ENGR00223679-3 battery: Fix codes formatting
Just fix codes formatting,there's no functionality
change in codes
Signed-off-by: Rong Dian <b38775@freescale.com>
Diffstat (limited to 'drivers/power')
-rwxr-xr-x | drivers/power/sabresd_battery.c | 44 |
1 files changed, 22 insertions, 22 deletions
diff --git a/drivers/power/sabresd_battery.c b/drivers/power/sabresd_battery.c index a069d4b276a5..648922139790 100755 --- a/drivers/power/sabresd_battery.c +++ b/drivers/power/sabresd_battery.c @@ -203,28 +203,28 @@ static void max8903_charger_update_status(struct max8903_data *data) } if (data->charger_online == 0 && data->usb_charger_online == 0) { data->battery_status = POWER_SUPPLY_STATUS_DISCHARGING; - } else { - if (gpio_get_value(data->pdata->chg) == 0) { - data->battery_status = POWER_SUPPLY_STATUS_CHARGING; - } else if (data->ta_in && gpio_get_value(data->pdata->chg) == 1) { - if (!data->pdata->feature_flag) { - if (data->percent >= 99) - data->battery_status = POWER_SUPPLY_STATUS_FULL; - else - data->battery_status = POWER_SUPPLY_STATUS_NOT_CHARGING; - } else { - data->battery_status = POWER_SUPPLY_STATUS_FULL; - } - } else if (data->usb_in && gpio_get_value(data->pdata->chg) == 1) { - if (!data->pdata->feature_flag) { - if (data->percent >= 99) - data->battery_status = POWER_SUPPLY_STATUS_FULL; - else - data->battery_status = POWER_SUPPLY_STATUS_NOT_CHARGING; - } else { - data->battery_status = POWER_SUPPLY_STATUS_FULL; - } - } + } else { + if (gpio_get_value(data->pdata->chg) == 0) { + data->battery_status = POWER_SUPPLY_STATUS_CHARGING; + } else if (data->ta_in && gpio_get_value(data->pdata->chg) == 1) { + if (!data->pdata->feature_flag) { + if (data->percent >= 99) + data->battery_status = POWER_SUPPLY_STATUS_FULL; + else + data->battery_status = POWER_SUPPLY_STATUS_NOT_CHARGING; + } else { + data->battery_status = POWER_SUPPLY_STATUS_FULL; + } + } else if (data->usb_in && gpio_get_value(data->pdata->chg) == 1) { + if (!data->pdata->feature_flag) { + if (data->percent >= 99) + data->battery_status = POWER_SUPPLY_STATUS_FULL; + else + data->battery_status = POWER_SUPPLY_STATUS_NOT_CHARGING; + } else { + data->battery_status = POWER_SUPPLY_STATUS_FULL; + } + } } pr_debug("chg: %d\n", gpio_get_value(data->pdata->chg)); pr_debug("dc: %d\n", gpio_get_value(data->pdata->dok)); |