Lines Matching full:capacity

174  * @init_capacity:	Indicate if initial capacity measuring should be done
182 * @bat_cap: Structure for battery capacity specific parameters
183 * @avg_cap: Average capacity filter
373 * ab8500_fg_add_cap_sample() - Add capacity to average filter
375 * @sample: the capacity in mAh to add to the filter
377 * A capacity is added to the filter and a new mean capacity is calculated and
412 * The capacity filter is is reset to zero.
433 * @sample: the capacity in mAh to fill the filter with
435 * The capacity filter is filled with a capacity in mAh
848 * ab8500_fg_volt_to_capacity() - Voltage based capacity
850 * @voltage: The voltage to convert to a capacity
852 * Returns battery capacity in per mille based on voltage
871 tbl[i].capacity * 10, in ab8500_fg_volt_to_capacity()
873 tbl[i-1].capacity * 10, in ab8500_fg_volt_to_capacity()
888 * ab8500_fg_uncomp_volt_to_capacity() - Uncompensated voltage based capacity
891 * Returns battery capacity based on battery voltage that is not compensated
946 * ab8500_fg_load_comp_volt_to_capacity() - Load compensated voltage based capacity
949 * Returns battery capacity based on battery voltage that is load compensated
982 * ab8500_fg_convert_mah_to_permille() - Capacity in mAh to permille
984 * @cap_mah: capacity in mAh
986 * Converts capacity in mAh to capacity in permille
994 * ab8500_fg_convert_permille_to_mah() - Capacity in permille to mAh
996 * @cap_pm: capacity in permille
998 * Converts capacity in permille to capacity in mAh
1006 * ab8500_fg_convert_mah_to_uwh() - Capacity in mAh to uWh
1008 * @cap_mah: capacity in mAh
1010 * Converts capacity in mAh to capacity in uWh
1028 * ab8500_fg_calc_cap_charging() - Calculate remaining capacity while charging
1031 * Return the capacity in mAh based on previous calculated capcity and the FG
1032 * accumulator register value. The filter is filled with this capacity
1041 /* Capacity should not be less than 0 */ in ab8500_fg_calc_cap_charging()
1047 * We force capacity to 100% once when the algorithm in ab8500_fg_calc_cap_charging()
1067 * ab8500_fg_calc_cap_discharge_voltage() - Capacity in discharge with voltage
1069 * @comp: if voltage should be load compensated before capacity calc
1071 * Return the capacity in mAh based on the battery voltage. The voltage can
1094 * ab8500_fg_calc_cap_discharge_fg() - Capacity in discharge with FG
1097 * Return the capacity in mAh based on previous calculated capcity and the FG
1110 /* Capacity should not be less than 0 */ in ab8500_fg_calc_cap_discharge_fg()
1120 * Check against voltage based capacity. It can not be lower in ab8500_fg_calc_cap_discharge_fg()
1147 * ab8500_fg_capacity_level() - Get the battery capacity level
1150 * Get the battery capacity level based on the capacity in percent
1174 * ab8500_fg_calculate_scaled_capacity() - Capacity scaling
1177 * Calculates the capacity to be shown to upper layers. Scales the capacity
1178 * to have 100% as a reference from the actual capacity upon removal of charger
1184 int capacity = di->bat_cap.prev_percent; in ab8500_fg_calculate_scaled_capacity() local
1187 return capacity; in ab8500_fg_calculate_scaled_capacity()
1190 * As long as we are in fully charge mode scale the capacity in ab8500_fg_calculate_scaled_capacity()
1196 max(capacity, di->bm->fg_params->maint_thres); in ab8500_fg_calculate_scaled_capacity()
1201 /* Calculates the scaled capacity. */ in ab8500_fg_calculate_scaled_capacity()
1204 capacity = min(100, in ab8500_fg_calculate_scaled_capacity()
1210 if (capacity < cs->disable_cap_level) { in ab8500_fg_calculate_scaled_capacity()
1211 cs->disable_cap_level = capacity; in ab8500_fg_calculate_scaled_capacity()
1217 dev_dbg(di->dev, "Disabling scaled capacity\n"); in ab8500_fg_calculate_scaled_capacity()
1219 capacity = di->bat_cap.prev_percent; in ab8500_fg_calculate_scaled_capacity()
1224 capacity = cs->disable_cap_level; in ab8500_fg_calculate_scaled_capacity()
1229 return capacity; in ab8500_fg_calculate_scaled_capacity()
1233 * ab8500_fg_update_cap_scalers() - Capacity scaling
1237 * the capacity scalers.
1267 * ab8500_fg_check_capacity_limits() - Check if capacity has changed
1269 * @init: capacity is allowed to go up in init mode
1271 * Check if capacity or capacity limit has changed and notify the system
1283 * We do not allow reported capacity level to go up in ab8500_fg_check_capacity_limits()
1302 * If we have received the LOW_BAT IRQ, set capacity to 0 to initiate in ab8500_fg_check_capacity_limits()
1306 dev_dbg(di->dev, "Battery low, set capacity to 0\n"); in ab8500_fg_check_capacity_limits()
1335 "but capacity dropping: %d\n", in ab8500_fg_check_capacity_limits()
1356 * We do not allow reported capacity to go up in ab8500_fg_check_capacity_limits()
1360 "capacity changed from %d to %d (%d)\n", in ab8500_fg_check_capacity_limits()
1369 dev_dbg(di->dev, "capacity not allowed to go up since " in ab8500_fg_check_capacity_limits()
1382 dev_info(di->dev, "capacity=%d (%d)\n", in ab8500_fg_check_capacity_limits()
1424 * Battery capacity calculation state machine for when we're charging
1448 * Read the FG and calculate the new capacity in ab8500_fg_algorithm_charging()
1470 /* Check capacity limits */ in ab8500_fg_algorithm_charging()
1510 dev_dbg(di->dev, "Capacity limits:" in check_sysfs_capacity()
1514 /* If within limits, use the saved capacity and exit estimation...*/ in check_sysfs_capacity()
1520 dev_dbg(di->dev, "Capacity from user out of limits, ignoring"); in check_sysfs_capacity()
1528 * Battery capacity calculation state machine for when we're discharging
1552 * samples to get an initial capacity. in ab8500_fg_algorithm_discharging()
1748 * Entry point for the battery capacity calculation state machine
1794 /* Get an initial capacity calculation */ in ab8500_fg_periodic_work()
2081 * charge_full_design: capacity where battery is considered full
2082 * charge_now: battery capacity in nAh
2083 * capacity: capacity in percent
2084 * capacity_level: capacity level
2096 * batteries is disabled, we always report 100% capacity and in ab8500_fg_get_property()
2097 * capacity level UNKNOWN, since we can't calculate in ab8500_fg_get_property()
2098 * remaining capacity in ab8500_fg_get_property()
2213 /* Save current capacity as maximum */ in ab8500_fg_get_ext_psy_data()
2397 * Used to reset the current battery capacity to be able to
2398 * retrigger a new voltage base capacity calculation. For