Blame view
drivers/cpufreq/cpufreq_performance.c
1.36 KB
d2912cb15 treewide: Replace... |
1 |
// SPDX-License-Identifier: GPL-2.0-only |
1da177e4c Linux-2.6.12-rc2 |
2 3 4 5 |
/* * linux/drivers/cpufreq/cpufreq_performance.c * * Copyright (C) 2002 - 2003 Dominik Brodowski <linux@brodo.de> |
1da177e4c Linux-2.6.12-rc2 |
6 |
*/ |
db7011516 cpufreq: Improve ... |
7 |
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt |
1da177e4c Linux-2.6.12-rc2 |
8 9 |
#include <linux/cpufreq.h> #include <linux/init.h> |
5ff0a2680 cpufreq: Clean up... |
10 |
#include <linux/module.h> |
1da177e4c Linux-2.6.12-rc2 |
11 |
|
e788892ba cpufreq: governor... |
12 |
static void cpufreq_gov_performance_limits(struct cpufreq_policy *policy) |
1da177e4c Linux-2.6.12-rc2 |
13 |
{ |
e788892ba cpufreq: governor... |
14 15 16 |
pr_debug("setting to %u kHz ", policy->max); __cpufreq_driver_target(policy, policy->max, CPUFREQ_RELATION_H); |
1da177e4c Linux-2.6.12-rc2 |
17 |
} |
32ee8c3e4 [CPUFREQ] Lots of... |
18 |
|
de1df26b7 cpufreq: Clean up... |
19 |
static struct cpufreq_governor cpufreq_gov_performance = { |
1da177e4c Linux-2.6.12-rc2 |
20 |
.name = "performance", |
1da177e4c Linux-2.6.12-rc2 |
21 |
.owner = THIS_MODULE, |
e788892ba cpufreq: governor... |
22 |
.limits = cpufreq_gov_performance_limits, |
1da177e4c Linux-2.6.12-rc2 |
23 |
}; |
1da177e4c Linux-2.6.12-rc2 |
24 |
|
1da177e4c Linux-2.6.12-rc2 |
25 26 27 28 |
static int __init cpufreq_gov_performance_init(void) { return cpufreq_register_governor(&cpufreq_gov_performance); } |
1da177e4c Linux-2.6.12-rc2 |
29 30 31 32 |
static void __exit cpufreq_gov_performance_exit(void) { cpufreq_unregister_governor(&cpufreq_gov_performance); } |
de1df26b7 cpufreq: Clean up... |
33 34 35 36 37 38 39 40 41 42 43 44 |
#ifdef CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE struct cpufreq_governor *cpufreq_default_governor(void) { return &cpufreq_gov_performance; } #endif #ifndef CONFIG_CPU_FREQ_GOV_PERFORMANCE_MODULE struct cpufreq_governor *cpufreq_fallback_governor(void) { return &cpufreq_gov_performance; } #endif |
1da177e4c Linux-2.6.12-rc2 |
45 46 47 48 49 50 |
MODULE_AUTHOR("Dominik Brodowski <linux@brodo.de>"); MODULE_DESCRIPTION("CPUfreq policy governor 'performance'"); MODULE_LICENSE("GPL"); fs_initcall(cpufreq_gov_performance_init); module_exit(cpufreq_gov_performance_exit); |