OSDN Git Service

power_supply: add POWER_SUPPLY_PROP_{COLD,HOT}_TEMP properties
authorSubbaraman Narayanamurthy <subbaram@codeaurora.org>
Sat, 12 Aug 2017 01:37:26 +0000 (18:37 -0700)
committerSubbaraman Narayanamurthy <subbaram@codeaurora.org>
Fri, 1 Sep 2017 02:25:32 +0000 (19:25 -0700)
Add POWER_SUPPLY_PROP_COLD_TEMP and POWER_SUPPLY_PROP_HOT_TEMP
properties to represent Cold and Hot JEITA thresholds of the
battery.

Change-Id: Id5e16a4f7b20bb05d997277d20db05fc08db9f33
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
drivers/power/power_supply_sysfs.c
include/linux/power_supply.h

index a45a514..2e9ff2a 100644 (file)
@@ -247,6 +247,8 @@ static struct device_attribute power_supply_attrs[] = {
        POWER_SUPPLY_ATTR(low_power),
        POWER_SUPPLY_ATTR(temp_cool),
        POWER_SUPPLY_ATTR(temp_warm),
+       POWER_SUPPLY_ATTR(temp_cold),
+       POWER_SUPPLY_ATTR(temp_hot),
        POWER_SUPPLY_ATTR(system_temp_level),
        POWER_SUPPLY_ATTR(resistance),
        POWER_SUPPLY_ATTR(resistance_capacitive),
index 982b93c..8b8a46c 100644 (file)
@@ -199,6 +199,8 @@ enum power_supply_property {
        POWER_SUPPLY_PROP_LOW_POWER,
        POWER_SUPPLY_PROP_COOL_TEMP,
        POWER_SUPPLY_PROP_WARM_TEMP,
+       POWER_SUPPLY_PROP_COLD_TEMP,
+       POWER_SUPPLY_PROP_HOT_TEMP,
        POWER_SUPPLY_PROP_SYSTEM_TEMP_LEVEL,
        POWER_SUPPLY_PROP_RESISTANCE,
        POWER_SUPPLY_PROP_RESISTANCE_CAPACITIVE,