Implement lagfree governor
/drivers/cpufreq/Kconfig
blob:46fb51d7f4e82c24bc4188007e14764a4f576fb3 -> blob:5ca4726eb98ef1761adcbb21a82532686a846d4b
--- drivers/cpufreq/Kconfig
+++ drivers/cpufreq/Kconfig
@@ -100,6 +100,19 @@ config CPU_FREQ_DEFAULT_GOV_CONSERVATIVE
governor. If unsure have a look at the help section of the
driver. Fallback governor will be the performance governor.
+
+config CPU_FREQ_DEFAULT_GOV_LAGFREE
+ bool "lagfree"
+ select CPU_FREQ_GOV_LAGFREE
+ select CPU_FREQ_GOV_PERFORMANCE
+ help
+ Use the CPUFreq governor 'lagfree' as default. This allows
+ you to get a full dynamic frequency capable system by simply
+ loading your cpufreq low-level hardware driver.
+ Be aware that not all cpufreq drivers support the lagfree
+ governor. If unsure have a look at the help section of the
+ driver. Fallback governor will be the performance governor.
+
config CPU_FREQ_DEFAULT_GOV_INTERACTIVE
bool "interactive"
select CPU_FREQ_GOV_INTERACTIVE
@@ -206,6 +219,71 @@ config CPU_FREQ_GOV_CONSERVATIVE
If in doubt, say N.
+config CPU_FREQ_GOV_LAGFREE
+ tristate "'lagfree' cpufreq governor"
+ depends on CPU_FREQ
+ help
+ 'lagfree' - this driver is rather similar to the 'ondemand'
+ governor both in its source code and its purpose, the difference is
+ its optimisation for better suitability in a battery powered
+ environment. The frequency is gracefully increased and decreased
+ rather than jumping to 100% when speed is required.
+
+config LAGFREE_MAX_LOAD
+ int "Max CPU Load"
+ default 50
+ depends on CPU_FREQ_GOV_LAGFREE
+ help
+ CPU freq will be increased if measured load > max_cpu_load;
+
+config LAGFREE_MIN_LOAD
+ int "Min CPU Load"
+ default 15
+ depends on CPU_FREQ_GOV_LAGFREE
+ help
+ CPU freq will be decrease if measured load < min_cpu_load;
+
+config LAGFREE_FREQ_STEP_DOWN
+ int "Frequency Step Down"
+ default 108000
+ depends on CPU_FREQ_GOV_LAGFREE
+ help
+ Max freqeuncy delta when ramping down.
+
+config LAGFREE_FREQ_SLEEP_MAX
+ int "Max Sleep frequeny"
+ default 384000
+ depends on CPU_FREQ_GOV_LAGFREE
+ help
+ Max freqeuncy for screen off.
+
+config LAGFREE_FREQ_AWAKE_MIN
+ int "Min Awake frequeny"
+ default 384000
+ depends on CPU_FREQ_GOV_LAGFREE
+ help
+ Min freqeuncy for screen on.
+
+config LAGFREE_FREQ_STEP_UP_SLEEP_PERCENT
+ int "Freq step up percent sleep"
+ default 20
+ depends on CPU_FREQ_GOV_LAGFREE
+ help
+ Frequency percent to step up while screen off.
+
+config CPU_FREQ_MIN_TICKS
+ int "Ticks between governor polling interval."
+ default 10
+ help
+ Minimum number of ticks between polling interval for governors.
+
+config CPU_FREQ_SAMPLING_LATENCY_MULTIPLIER
+ int "Sampling rate multiplier for governors."
+ default 1000
+ help
+ Sampling latency rate multiplied by the cpu switch latency.
+ Affects governor polling.
+
config SEC_DVFS
bool "DVFS job"
default n