summaryrefslogtreecommitdiff
path: root/include/linux/cpufreq.h
diff options
context:
space:
mode:
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>2012-03-13 19:18:39 -0400
committerDave Jones <davej@redhat.com>2012-03-14 14:45:03 -0400
commita7b422cda5084db7265c3b23310a959b43b47529 (patch)
tree32cb3e1dbde6b23814cc4e9c432db92754e89679 /include/linux/cpufreq.h
parent562a6cbe1cf2edf0a87a659eb26095400322430e (diff)
provide disable_cpufreq() function to disable the API.
useful for disabling cpufreq altogether. The cpu frequency scaling drivers and cpu frequency governors will fail to register. Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Signed-off-by: Dave Jones <davej@redhat.com>
Diffstat (limited to 'include/linux/cpufreq.h')
-rw-r--r--include/linux/cpufreq.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/cpufreq.h b/include/linux/cpufreq.h
index 6216115c7789..8ff442753c75 100644
--- a/include/linux/cpufreq.h
+++ b/include/linux/cpufreq.h
@@ -35,6 +35,7 @@
#ifdef CONFIG_CPU_FREQ
int cpufreq_register_notifier(struct notifier_block *nb, unsigned int list);
int cpufreq_unregister_notifier(struct notifier_block *nb, unsigned int list);
+extern void disable_cpufreq(void);
#else /* CONFIG_CPU_FREQ */
static inline int cpufreq_register_notifier(struct notifier_block *nb,
unsigned int list)
@@ -46,6 +47,7 @@ static inline int cpufreq_unregister_notifier(struct notifier_block *nb,
{
return 0;
}
+static inline void disable_cpufreq(void) { }
#endif /* CONFIG_CPU_FREQ */
/* if (cpufreq_driver->target) exists, the ->governor decides what frequency