diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-05-09 09:40:49 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-05-09 09:40:49 -0700 |
commit | b29bdba51924f6fd5971352ba111784dee3a5853 (patch) | |
tree | 95f8b7adfd75ce1d6c86b06f9347247aefecd075 /include/linux/cpu_cooling.h | |
parent | e0fd9affeb64088eff407dfc98bbd3a5c17ea479 (diff) | |
parent | de6558dc964f6a3243218f17d8032ad810864e2b (diff) |
Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux
Pull thermal management update from Zhang Rui:
"The most important one is to build thermal core and governor and cpu
cooling code into one module. This fixes a regression that thermal
core does not work if it is built as module, since 3.7. I'll backport
them to stable kernel once those changes are in upstream.
The largest batch is the thermal kernel-doc & coding style
updates/cleanups from Eduardo.
Highlights:
- build all thermal framework code into one module to fix a
regression that thermal does not work if it is built as module.
- Marvell Armada 370/XP thermal sensor driver
- thermal core/cpu cooling kernel-doc & coding style updates and
cleanups.
- Add Eduardo Valentin as thermal sub-maintainer, both in mailing
list and patchwork. He will help me on arm thermal drivers."
* 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux: (68 commits)
thermal: db8500_cpufreq_cooling: remove usage of IS_ERR_OR_NULL()
thermal: thermal_core: remove usage of IS_ERR_OR_NULL
thermal: cpu_cooling: improve line breaking
thermal: cpu_cooling: alignment improvements
thermal: cpu_cooling: remove checkpatch.pl warning
thermal: cpu_cooling: remove trailing blank line
thermal: cpu_cooling: align on open parenthesis
thermal: cpu_cooling: standardize comment style
thermal: cpu_cooling: standardize end of function
thermal: cpu_cooling: remove trailing white spaces
Thermal: update documentation for thermal_zone_device_register
thermal: update kernel-doc for thermal_zone_device_register
thermal: update kernel-doc for create_trip_attrs
thermal: update kernel-doc for thermal_cooling_device_register
thermal: update kernel-doc for thermal_zone_unbind_cooling_device
thermal: update kernel-doc for thermal_zone_bind_cooling_device
thermal: use EXPORT_SYMBOL_GPL
thermal: rename notify_thermal_framework to thermal_notify_framework
thermal: update driver license
thermal: use strlcpy instead of strcpy
...
Diffstat (limited to 'include/linux/cpu_cooling.h')
-rw-r--r-- | include/linux/cpu_cooling.h | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/include/linux/cpu_cooling.h b/include/linux/cpu_cooling.h index 40b4ef54cc7..282e2702841 100644 --- a/include/linux/cpu_cooling.h +++ b/include/linux/cpu_cooling.h @@ -25,34 +25,39 @@ #define __CPU_COOLING_H__ #include <linux/thermal.h> +#include <linux/cpumask.h> -#define CPUFREQ_COOLING_START 0 -#define CPUFREQ_COOLING_STOP 1 - -#if defined(CONFIG_CPU_THERMAL) || defined(CONFIG_CPU_THERMAL_MODULE) +#ifdef CONFIG_CPU_THERMAL /** * cpufreq_cooling_register - function to create cpufreq cooling device. * @clip_cpus: cpumask of cpus where the frequency constraints will happen */ -struct thermal_cooling_device *cpufreq_cooling_register( - const struct cpumask *clip_cpus); +struct thermal_cooling_device * +cpufreq_cooling_register(const struct cpumask *clip_cpus); /** * cpufreq_cooling_unregister - function to remove cpufreq cooling device. * @cdev: thermal cooling device pointer. */ void cpufreq_cooling_unregister(struct thermal_cooling_device *cdev); + +unsigned long cpufreq_cooling_get_level(unsigned int, unsigned int); #else /* !CONFIG_CPU_THERMAL */ -static inline struct thermal_cooling_device *cpufreq_cooling_register( - const struct cpumask *clip_cpus) +static inline struct thermal_cooling_device * +cpufreq_cooling_register(const struct cpumask *clip_cpus) { return NULL; } -static inline void cpufreq_cooling_unregister( - struct thermal_cooling_device *cdev) +static inline +void cpufreq_cooling_unregister(struct thermal_cooling_device *cdev) { return; } +static inline +unsigned long cpufreq_cooling_get_level(unsigned int, unsigned int) +{ + return THERMAL_CSTATE_INVALID; +} #endif /* CONFIG_CPU_THERMAL */ #endif /* __CPU_COOLING_H__ */ |