Lines Matching refs:pb
50 struct power_battery *pb = bat->pbat; in power_update_battery() local
58 ret = max77693_get_soc(&pb->bat->state_of_chrg); in power_update_battery()
62 max77693_get_vcell(&pb->bat->voltage_uV); in power_update_battery()
69 struct power_battery *pb = bat->pbat; in power_check_battery() local
83 ret = pmic_reg_read(p, MAX77693_VERSION, &pb->bat->version); in power_check_battery()
90 debug("fg ver: 0x%x\n", pb->bat->version); in power_check_battery()
92 pb->bat->state_of_chrg); in power_check_battery()
95 pb->bat->voltage_uV / 1000000, in power_check_battery()
96 pb->bat->voltage_uV % 1000000, in power_check_battery()
97 pb->bat->capacity); in power_check_battery()
99 if (pb->bat->voltage_uV > 3850000) in power_check_battery()
100 pb->bat->state = EXT_SOURCE; in power_check_battery()
101 else if (pb->bat->voltage_uV < 3600000 || pb->bat->state_of_chrg < 5) in power_check_battery()
102 pb->bat->state = CHARGE; in power_check_battery()
104 pb->bat->state = NORMAL; in power_check_battery()