diff options
author | Kevin Hilman <khilman@linaro.org> | 2015-06-29 10:37:23 -0700 |
---|---|---|
committer | Kevin Hilman <khilman@linaro.org> | 2015-06-29 10:37:23 -0700 |
commit | 590e935df0c94b2d7a4584bb26906666176a6133 (patch) | |
tree | bb004c31d277423c7eb0f6bd2c0c1e9d8428e9f2 /drivers/thermal/thermal_core.h | |
parent | 774b195c03ac44c0dbc4e81a3f194779692ce3bd (diff) | |
parent | 91760bceff1f3f5860ff49c14194567f972352e6 (diff) |
Merge branch 'linux-linaro-lsk-v3.18' into linux-linaro-lsk-v3.18-rtlsk-v3.18-18.03-rtlsk-v3.18-18.02-rtlsk-v3.18-17.11-rtlsk-v3.18-17.09-rtlsk-v3.18-17.08-rtlsk-v3.18-17.05-rtlsk-v3.18-17.03-rtlsk-v3.18-16.07-rtlsk-v3.18-16.06-rtlsk-v3.18-16.05-rtlsk-v3.18-16.04-rtlsk-v3.18-16.03-rtlsk-v3.18-16.02-rtlsk-v3.18-16.01-rtlsk-v3.18-15.12-rtlsk-v3.18-15.11-rtlsk-v3.18-15.10-rtlsk-v3.18-15.09-rtlsk-v3.18-15.08-rtlsk-v3.18-15.07-rtlinux-linaro-lsk-v3.18-rt
Diffstat (limited to 'drivers/thermal/thermal_core.h')
-rw-r--r-- | drivers/thermal/thermal_core.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/drivers/thermal/thermal_core.h b/drivers/thermal/thermal_core.h index d15d243de27a..8a6624488cc5 100644 --- a/drivers/thermal/thermal_core.h +++ b/drivers/thermal/thermal_core.h @@ -46,8 +46,11 @@ struct thermal_instance { unsigned long target; /* expected cooling state */ char attr_name[THERMAL_NAME_LENGTH]; struct device_attribute attr; + char weight_attr_name[THERMAL_NAME_LENGTH]; + struct device_attribute weight_attr; struct list_head tz_node; /* node in tz->thermal_instances */ struct list_head cdev_node; /* node in cdev->thermal_instances */ + unsigned int weight; /* The weight of the cooling device */ }; int thermal_register_governor(struct thermal_governor *); @@ -85,13 +88,39 @@ static inline int thermal_gov_user_space_register(void) { return 0; } static inline void thermal_gov_user_space_unregister(void) {} #endif /* CONFIG_THERMAL_GOV_USER_SPACE */ +#ifdef CONFIG_THERMAL_GOV_POWER_ALLOCATOR +int thermal_gov_power_allocator_register(void); +void thermal_gov_power_allocator_unregister(void); +#else +static inline int thermal_gov_power_allocator_register(void) { return 0; } +static inline void thermal_gov_power_allocator_unregister(void) {} +#endif /* CONFIG_THERMAL_GOV_POWER_ALLOCATOR */ + /* device tree support */ #ifdef CONFIG_THERMAL_OF int of_parse_thermal_zones(void); void of_thermal_destroy_zones(void); +int of_thermal_get_ntrips(struct thermal_zone_device *); +bool of_thermal_is_trip_valid(struct thermal_zone_device *, int); +const struct thermal_trip * +of_thermal_get_trip_points(struct thermal_zone_device *); #else static inline int of_parse_thermal_zones(void) { return 0; } static inline void of_thermal_destroy_zones(void) { } +static inline int of_thermal_get_ntrips(struct thermal_zone_device *tz) +{ + return 0; +} +static inline bool of_thermal_is_trip_valid(struct thermal_zone_device *tz, + int trip) +{ + return 0; +} +static inline const struct thermal_trip * +of_thermal_get_trip_points(struct thermal_zone_device *tz) +{ + return NULL; +} #endif #endif /* __THERMAL_CORE_H__ */ |