Lines Matching refs:val
182 const union power_supply_propval *val);
233 * 'val'. The index range returned is 0 to 'tbl_size' - 1. Assumes that
303 int *val)
313 *val = tbl[v];
321 int val)
325 idx = bq24190_find_idx(tbl, tbl_size, val);
508 union power_supply_propval val = { .intval = bdi->charge_type };
524 ret = bq24190_charger_set_charge_type(bdi, &val);
547 u8 val;
557 BQ24190_REG_POC_CHG_CONFIG_SHIFT, &val);
565 bdi->otg_vbus_enabled = (val == BQ24190_REG_POC_CHG_CONFIG_OTG ||
566 val == BQ24190_REG_POC_CHG_CONFIG_OTG_ALT);
748 union power_supply_propval *val)
775 val->intval = type;
781 const union power_supply_propval *val)
796 switch (val->intval) {
814 bdi->charge_type = val->intval;
844 union power_supply_propval *val)
903 val->intval = health;
909 union power_supply_propval *val)
926 val->intval = pg_stat && !batfet_disable;
932 const union power_supply_propval *val);
934 union power_supply_propval *val);
936 union power_supply_propval *val);
938 const union power_supply_propval *val);
941 const union power_supply_propval *val)
943 return bq24190_battery_set_online(bdi, val);
947 union power_supply_propval *val)
949 return bq24190_battery_get_status(bdi, val);
953 union power_supply_propval *val)
955 return bq24190_battery_get_temp_alert_max(bdi, val);
959 const union power_supply_propval *val)
961 return bq24190_battery_set_temp_alert_max(bdi, val);
965 union power_supply_propval *val)
988 val->intval = curr;
994 union power_supply_propval *val)
1005 val->intval = ++v * 128 * 1000;
1010 union power_supply_propval *val)
1032 val->intval = curr;
1037 const union power_supply_propval *val)
1040 int ret, curr = val->intval;
1068 union power_supply_propval *val)
1079 val->intval = voltage;
1084 const union power_supply_propval *val)
1088 if (val->intval > bdi->vreg_max)
1094 ARRAY_SIZE(bq24190_cvc_vreg_values), val->intval);
1098 bdi->vreg = val->intval;
1104 union power_supply_propval *val)
1116 val->intval = iinlimit;
1121 const union power_supply_propval *val)
1127 ARRAY_SIZE(bq24190_isc_iinlim_values), val->intval);
1131 enum power_supply_property psp, union power_supply_propval *val)
1144 ret = bq24190_charger_get_charge_type(bdi, val);
1147 ret = bq24190_charger_get_health(bdi, val);
1150 ret = bq24190_charger_get_online(bdi, val);
1153 ret = bq24190_charger_get_status(bdi, val);
1156 ret = bq24190_charger_get_temp_alert_max(bdi, val);
1159 ret = bq24190_charger_get_precharge(bdi, val);
1162 ret = bq24190_charger_get_charge_term(bdi, val);
1165 ret = bq24190_charger_get_current(bdi, val);
1168 val->intval = bdi->ichg_max;
1172 ret = bq24190_charger_get_voltage(bdi, val);
1175 val->intval = bdi->vreg_max;
1179 ret = bq24190_charger_get_iinlimit(bdi, val);
1182 val->intval = POWER_SUPPLY_SCOPE_SYSTEM;
1186 val->strval = bdi->model_name;
1190 val->strval = BQ24190_MANUFACTURER;
1205 const union power_supply_propval *val)
1218 ret = bq24190_charger_set_online(bdi, val);
1221 ret = bq24190_charger_set_temp_alert_max(bdi, val);
1224 ret = bq24190_charger_set_charge_type(bdi, val);
1227 ret = bq24190_charger_set_current(bdi, val);
1230 ret = bq24190_charger_set_voltage(bdi, val);
1233 ret = bq24190_charger_set_iinlimit(bdi, val);
1266 union power_supply_propval val;
1271 &val);
1277 &val);
1334 union power_supply_propval *val)
1380 val->intval = status;
1386 union power_supply_propval *val)
1420 val->intval = health;
1425 union power_supply_propval *val)
1436 val->intval = !batfet_disable;
1441 const union power_supply_propval *val)
1445 BQ24190_REG_MOC_BATFET_DISABLE_SHIFT, !val->intval);
1449 union power_supply_propval *val)
1461 val->intval = temp;
1466 const union power_supply_propval *val)
1472 ARRAY_SIZE(bq24190_ictrc_treg_values), val->intval);
1476 enum power_supply_property psp, union power_supply_propval *val)
1490 ret = bq24190_battery_get_status(bdi, val);
1493 ret = bq24190_battery_get_health(bdi, val);
1496 ret = bq24190_battery_get_online(bdi, val);
1500 val->intval = POWER_SUPPLY_TECHNOLOGY_UNKNOWN;
1504 ret = bq24190_battery_get_temp_alert_max(bdi, val);
1507 val->intval = POWER_SUPPLY_SCOPE_SYSTEM;
1522 const union power_supply_propval *val)
1536 ret = bq24190_battery_set_online(bdi, val);
1539 ret = bq24190_battery_set_temp_alert_max(bdi, val);