Originariamente inviato da
N1m0Y
Qui e
qui trovi molte informazioni utili
edit: ho trovato anche questo.....
codice:
* drivers/cpufreq/cpufreq_zzmoove.c
*
* Copyright (C) 2001 Russell King
* (C) 2003 Venkatesh Pallipadi .
* Jun Nakajima
* (C) 2009 Alexander Clouter
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
* --------------------------------------------------------------------------------------------------------------------------------------------------------
* - ZZMoove Governor Changelog: -
* --------------------------------------------------------------------------------------------------------------------------------------------------------
*
* Version 0.1 - first release
*
*- codebase latest smoove governor version from midnight kernel (https://github.com/mialwe/mngb/)
*- modified frequency tables to match I9300 standard frequency range 200-1400 mhz
*- added cpu hotplug functionality with strictly cpu switching
* (modifications partially taken from ktoonservative governor from
* ktoonsez KT747-JB kernel https://github.com/ktoonsez/KT747-JB)
*
* Version 0.2 - improved
*
*- added tuneables to be able to adjust values on early suspend (screen off) via sysfs instead
* of using only hardcoded defaults
*- modified hotplug implementation to be able to tune threshold range per core indepentently
* and to be able to manually turn cores offline
*
* for this functions following new tuneables were indroduced:
*
* sampling_rate_sleep_multiplier -> sampling rate multiplier on early suspend (possible values 1 or 2, default: 2)
* up_threshold_sleep -> up threshold on early suspend (possible range from above "down_threshold_sleep" up to 100, default: 90)
* down_threshold_sleep -> down threshold on early suspend (possible range from 11 to "under up_threshold_sleep", default: 44)
* smooth_up_sleep -> smooth up scaling on early suspend (possible range from 1 to 100, default: 100)
* up_threshold_hotplug1 -> hotplug threshold for cpu1 (0 disable core1, possible range from "down_threshold" up to 100, default: 68)
* up_threshold_hotplug2 -> hotplug threshold for cpu2 (0 disable core2, possible range from "down_threshold" up to 100, default: 68)
* up_threshold_hotplug3 -> hotplug threshold for cpu3 (0 disable core3, possible range from "down_threshold" up to 100, default: 68)
* down_threshold_hotplug1 -> hotplug threshold for cpu1 (possible range from 11 to under "up_threshold", default: 55)
* down_threshold_hotplug2 -> hotplug threshold for cpu2 (possible range from 11 to under "up_threshold", default: 55)
* down_threshold_hotplug3 -> hotplug threshold for cpu3 (possible range from 11 to under "up_threshold", default: 55)
*
* Version 0.3 - more improvements
*
*- added tuneable "hotplug_sleep" to be able to turn cores offline only on early suspend (screen off) via sysfs
* possible values: 0 do not touch hotplug-settings on early suspend, values 1, 2 or 3 are equivalent to
* cores which should be online at early suspend
*- modified scaling frequency table to match "overclock" freqencies to max 1600 mhz
*- fixed black screen of dead problem in hotplug logic due to missing mutexing on 3-core and 2-core settings
*- code cleaning and documentation
*
* Version 0.4 - limits
*
*- added "soft"-freqency-limit. the term "soft" means here that this is unfortuneately not a hard limit. a hard limit is only possible with
* cpufreq driver which is the freqency "giver" the governor is only the "consultant". So now the governor will scale up to only the given up
* limit on higher system load but if the cpufreq driver "wants" to go above that limit the freqency will go up there. u can see this for
* example with touchboost or wake up freqencies (1000 and 800 mhz) where the governor obviously will be "bypassed" by the cpufreq driver.
* but nevertheless this soft-limit will now reduce the use of freqencies higer than given limit and therefore it will reduce power consumption.
*
* for this function following new tuneables were indroduced:
*
* freq_limit_sleep -> limit freqency on early suspend (possible values 0 disable limit, 200-1600, default: 0)
* freq_limit -> limit freqency on awake (possible values 0 disable limit, 200-1600, default: 0)
*
*- added scaling frequencies to frequency tables for a faster up/down scaling. This should bring more performance but on the other hand it
* can be of course a little bit more power consumptive.
*
* for this function following new tuneables were indroduced:
*
* fast_scaling -> fast scaling on awake (possible values 0 disable or 1 enable, default: 0)
* fast_scaling_sleep (sysfs) -> fast scaling on early suspend (possible values 0 disable or 1 enable, default: 0)
*
*- added tuneable "freq_step_sleep" for setting the freq step at early suspend (possible values same as freq_step 0 to 100, default 5)
*- added DEF_FREQ_STEP and IGNORE_NICE definitions
*- changed downscaling cpufreq relation to the "lower way"
*- code/documentation cleaning
*---------------------------------------------------------------------------------------------------------------------------------------------------------
*- -
*---------------------------------------------------------------------------------------------------------------------------------------------------------
Come potete notare il fast scaling se è impostato a 0 rimane disabilitato, mentre su 1 si abilita (proprio come avevo immaginato io
)
Si vede che ragiono in linguaggio macchina
Stampato su carta Kodak.ciribiribì Kodak( ͡º ͜ʖ ͡º )