aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/cpufreq.h
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2013-05-21 03:52:16 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2013-05-21 03:52:16 -0400
commite1b73cba13a0cc68dd4f746eced15bd6bb24cda4 (patch)
treeb1c9e10730724024a700031ad56c20419dabb500 /include/linux/cpufreq.h
parent98304ad186296dc1e655399e28d5973c21db6a73 (diff)
parentc7788792a5e7b0d5d7f96d0766b4cb6112d47d75 (diff)
Merge tag 'v3.10-rc2' into drm-intel-next-queued
Backmerge Linux 3.10-rc2 since the various (rather trivial) conflicts grew a bit out of hand. intel_dp.c has the only real functional conflict since the logic changed while dev_priv->edp.bpp was moved around. Also squash in a whitespace fixup from Ben Widawsky for i915_gem_gtt.c, git seems to do something pretty strange in there (which I don't fully understand tbh). Conflicts: drivers/gpu/drm/i915/i915_reg.h drivers/gpu/drm/i915/intel_dp.c Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'include/linux/cpufreq.h')
-rw-r--r--include/linux/cpufreq.h21
1 files changed, 16 insertions, 5 deletions
diff --git a/include/linux/cpufreq.h b/include/linux/cpufreq.h
index a22944ca0526..037d36ae63e5 100644
--- a/include/linux/cpufreq.h
+++ b/include/linux/cpufreq.h
@@ -106,6 +106,7 @@ struct cpufreq_policy {
106 * governors are used */ 106 * governors are used */
107 unsigned int policy; /* see above */ 107 unsigned int policy; /* see above */
108 struct cpufreq_governor *governor; /* see below */ 108 struct cpufreq_governor *governor; /* see below */
109 void *governor_data;
109 110
110 struct work_struct update; /* if update_policy() needs to be 111 struct work_struct update; /* if update_policy() needs to be
111 * called, but you're in IRQ context */ 112 * called, but you're in IRQ context */
@@ -178,9 +179,11 @@ static inline unsigned long cpufreq_scale(unsigned long old, u_int div, u_int mu
178 * CPUFREQ GOVERNORS * 179 * CPUFREQ GOVERNORS *
179 *********************************************************************/ 180 *********************************************************************/
180 181
181#define CPUFREQ_GOV_START 1 182#define CPUFREQ_GOV_START 1
182#define CPUFREQ_GOV_STOP 2 183#define CPUFREQ_GOV_STOP 2
183#define CPUFREQ_GOV_LIMITS 3 184#define CPUFREQ_GOV_LIMITS 3
185#define CPUFREQ_GOV_POLICY_INIT 4
186#define CPUFREQ_GOV_POLICY_EXIT 5
184 187
185struct cpufreq_governor { 188struct cpufreq_governor {
186 char name[CPUFREQ_NAME_LEN]; 189 char name[CPUFREQ_NAME_LEN];
@@ -229,6 +232,13 @@ struct cpufreq_driver {
229 struct module *owner; 232 struct module *owner;
230 char name[CPUFREQ_NAME_LEN]; 233 char name[CPUFREQ_NAME_LEN];
231 u8 flags; 234 u8 flags;
235 /*
236 * This should be set by platforms having multiple clock-domains, i.e.
237 * supporting multiple policies. With this sysfs directories of governor
238 * would be created in cpu/cpu<num>/cpufreq/ directory and so they can
239 * use the same governor with different tunables for different clusters.
240 */
241 bool have_governor_per_policy;
232 242
233 /* needed by all drivers */ 243 /* needed by all drivers */
234 int (*init) (struct cpufreq_policy *policy); 244 int (*init) (struct cpufreq_policy *policy);
@@ -268,8 +278,8 @@ int cpufreq_register_driver(struct cpufreq_driver *driver_data);
268int cpufreq_unregister_driver(struct cpufreq_driver *driver_data); 278int cpufreq_unregister_driver(struct cpufreq_driver *driver_data);
269 279
270 280
271void cpufreq_notify_transition(struct cpufreq_freqs *freqs, unsigned int state); 281void cpufreq_notify_transition(struct cpufreq_policy *policy,
272 282 struct cpufreq_freqs *freqs, unsigned int state);
273 283
274static inline void cpufreq_verify_within_limits(struct cpufreq_policy *policy, unsigned int min, unsigned int max) 284static inline void cpufreq_verify_within_limits(struct cpufreq_policy *policy, unsigned int min, unsigned int max)
275{ 285{
@@ -329,6 +339,7 @@ const char *cpufreq_get_current_driver(void);
329 *********************************************************************/ 339 *********************************************************************/
330int cpufreq_get_policy(struct cpufreq_policy *policy, unsigned int cpu); 340int cpufreq_get_policy(struct cpufreq_policy *policy, unsigned int cpu);
331int cpufreq_update_policy(unsigned int cpu); 341int cpufreq_update_policy(unsigned int cpu);
342bool have_governor_per_policy(void);
332 343
333#ifdef CONFIG_CPU_FREQ 344#ifdef CONFIG_CPU_FREQ
334/* query the current CPU frequency (in kHz). If zero, cpufreq couldn't detect it */ 345/* query the current CPU frequency (in kHz). If zero, cpufreq couldn't detect it */