aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/power
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/power')
-rw-r--r--drivers/power/power_supply_sysfs.c7
-rw-r--r--drivers/power/sec_battery_u1.c16
2 files changed, 11 insertions, 12 deletions
diff --git a/drivers/power/power_supply_sysfs.c b/drivers/power/power_supply_sysfs.c
index 009e905..a647e74 100644
--- a/drivers/power/power_supply_sysfs.c
+++ b/drivers/power/power_supply_sysfs.c
@@ -42,14 +42,15 @@ static ssize_t power_supply_show_property(struct device *dev,
struct device_attribute *attr,
char *buf) {
static char *type_text[] = {
- "Battery", "UPS", "Mains", "USB",
- "USB_DCP", "USB_CDP", "USB_ACA"
+ "Unknown", "Battery", "UPS", "Mains", "USB",
+ "USB_DCP", "USB_CDP", "USB_ACA",
+ "DOCK", "MISC", "WIRELESS", "OTG"
};
static char *status_text[] = {
"Unknown", "Charging", "Discharging", "Not charging", "Full"
};
static char *charge_type[] = {
- "Unknown", "N/A", "Trickle", "Fast"
+ "Unknown", "N/A", "Trickle", "Fast", "Slow"
};
static char *health_text[] = {
"Unknown", "Good", "Overheat", "Dead", "Over voltage",
diff --git a/drivers/power/sec_battery_u1.c b/drivers/power/sec_battery_u1.c
index 3dcd150..112a55d 100644
--- a/drivers/power/sec_battery_u1.c
+++ b/drivers/power/sec_battery_u1.c
@@ -214,7 +214,7 @@
#endif
#ifdef CONFIG_TARGET_LOCALE_NA
-#define FULL_CHARGE_COND_VOLTAGE (4000 * 1000) /* 4.00 V */
+#define FULL_CHARGE_COND_VOLTAGE (4150 * 1000) /* 4.15 V */
#else
#define FULL_CHARGE_COND_VOLTAGE (4150 * 1000) /* 4.15 V */
#endif
@@ -527,14 +527,6 @@ static int sec_bat_get_property(struct power_supply *ps,
break;
#endif
case POWER_SUPPLY_PROP_CAPACITY:
-#ifdef CONFIG_TARGET_LOCALE_NA
- if (info->charging_status != POWER_SUPPLY_STATUS_FULL
- && info->batt_soc == 100) {
- val->intval = 99;
- break;
- }
-#endif /*CONFIG_TARGET_LOCALE_NA */
-
if (info->charging_status == POWER_SUPPLY_STATUS_FULL) {
val->intval = 100;
break;
@@ -1993,6 +1985,9 @@ static bool sec_bat_check_ing_level_trigger(struct sec_bat_info *info)
#endif
if (info->batt_vcell >=
FULL_CHARGE_COND_VOLTAGE) {
+#if defined(CONFIG_TARGET_LOCALE_NA)
+ if (info->batt_soc > 99){
+#endif
/* USB full charged */
info->charging_int_full_count++;
if (info->
@@ -2010,6 +2005,9 @@ static bool sec_bat_check_ing_level_trigger(struct sec_bat_info *info)
__func__,
info->
charging_int_full_count);
+#if defined(CONFIG_TARGET_LOCALE_NA)
+ }
+#endif
} else {
info->charging_int_full_count =
0;