How to disable auto boost and lock freq in emui5? - Huawei P9 Questions & Answers

I have disabled powergenie3 and cleared any xmls about perf in /product/etc/hwpg, but find that min freqs of gpu, little core and big core are also boosted when i switch different apps and freqs will be returned to default after the boost.
I find that a service names perfhub boost the freq and i find the way to control part of it through adb shell, such as:
change freq of big core to 2304mhz: service call perfhub 2 i64 2 i64 5 i64 2304000
but i can't control min freq of big core to 480mhz and also can't disable the boost.

Related

[Q] Difference between different governors

What are the differences?
Which one is most power saving?
Had a look around, this guy here seems to explain it pretty well
http://forum.xda-developers.com/showthread.php?t=843406
Hope that helps.
Extracted from governors.txt from my mediafire site ...
CPUFreq governors in the Android Kernel
=======================================
+ performance
The CPUfreq governor "performance" sets the CPU statically to the highest frequency within the borders of scaling_min_freq and scaling_max_freq.
+ powersave
The CPUfreq governor "powersave" sets the CPU statically to the lowest frequency within the borders of scaling_min_freq and scaling_max_freq.
+ userspace
The CPUfreq governor "userspace" allows the user, or any userspace program running with UID "root", to set the CPU to a specific frequency by making a sysfs file "scaling_setspeed" available in the CPU-device directory.
+ ondemand
The CPUfreq governor "ondemand" sets the CPU depending on the current usage. To do this the CPU must have the capability to switch the frequency very quickly. There are a number of sysfs file accessible parameters: sampling_rate, show_sampling_rate_min, up_threshold, ignore_nice_load, sampling_down_factor.
+ conservative
The CPUfreq governor "conservative", much like the "ondemand" governor, sets the CPU depending on the current usage. It differs in behaviour in that it gracefully increases and decreases the CPU speed rather than jumping to max speed the moment there is any load on the CPU. This behaviour more suitable in a battery powered environment. The governor is tweaked in the same manner as the "ondemand" governor through sysfs with the addition of: freq_step & down_threshold
+ interactive
The CPUfreq governor "interactive" is designed for latency-sensitive, interactive workloads. This governor sets the CPU speed depending on usage, similar to "ondemand" and "conservative" governors. However, the governor is more aggressive about scaling the CPU speed up in response to CPU-intensive activity. The tuneable value for this governor are: min_sample_time & go_maxspeed_load
+ smartass (By [email protected])
The smartass governor is a complete rewrite of the interactive governor. CPU spends much more time at the lower frequencies for improved battery life. It gives the phone an automatic Screen Off profile, keeping speeds at a minimum when the phone is idle.
+ savagedzen (By [email protected])
SavagedZen is a governor based on the Smartass governor. With tweaks to paramaters which control how much and how fast cpu ramps up/down. Main difference versus Smartass is that cpu ramps down not in fixed steps, but based on cpu load heuristics, i.e. when cpu load falls below threshold (min_cpu_load), cpu immediately ramps down to a frequency derived from the measured load.
+ interactiveX (By [email protected])
Modified version of interactive with suspend code which locks at lowest clock speed when screen is off. Has a sleep+awake profile, meaning you don't need to set up manual profiles, it will lock at your minimum frequency during screen off
References:
- https://github.com/android/kernel_common/blob/android-2.6.39/Documentation/cpu-freq/governors.txt
- https://github.com/Savaged-Zen/Savaged-Zen/tree/master/drivers/cpufreq
- http://forum.xda-developers.com/showthread.php?p=12944012
- http://www.ziggy471.com/2010/11/07/smartass-governor-info
The OP question about the most power saving governor has been answered - 'powersave'. My question is - what about SavagedZen vs conservative?

[INFO] [v1.0] [27-05-2020] CPU Governor ZZMoove

Hi Guys,
i thought it would be a good idea to put all the infos of the zzmoove governor around here together on one place
for better way to find it, to have a place to dump stuff for future versions and to give support for specific questions.
for now i just copied the allready existend posts here but will edit this further when i have more time
so lets start with the first
initial version:
ZZMoove Governor v0.1
(post from 18th December 2012, 10:27 PM)
Why that “zzmoove” governor and how it works:
I thought it were pretty cool to have one of my favorite governors back from the old SGS1-days on my actual device, so i decided to take the sources and give that a try on top of boeffla kernel. It worked well so this is now the result of that experiment.
More about the internals:
Basically this is the ported SGS1 version of the well known "smoove" governor from the good old midnight kernel from Michael Weingaertner (mialwe) with a modified CPU hotplug implementation of the ktoonservative governor from ktoonesz. The original implementation from ktoonesz worked well but I observed that on idle most of the time only one cpu was going to sleep. Well that was not enough for me so I made a modification to put the other cpu's also to sleep (except cpu0). That means that this governor uses more often only one cpu on idle and as a consequence of that it needs less energy. Depending on System load and governor settings all 4 cores will be instantly up again if it is needed.
In short:
So what you can expect now from this thingy is a battery-friendly behaving hotplug conservative governor which
uses a frequency lookup table for faster upscaling (so called "smooth scaling") So this is more a energy-safer than a performer.
Tuneables/Defaults:
Sampling Rate (default=2) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/sampling_rate
Sampling Down Factor (default=4) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/sampling_down_factor
Up Threshold (default=70) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold
Up Threshold Hotplug (default=68) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_hotplug
Down Threshold (default=52) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold
Down Threshold Hotplug (default=55) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_hotplug
Ignore Nice Load (default=0) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/ignore_nice_load
Freqency Step (default=5) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/freq_step
Smooth Up (default=75) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/smooth_up
Links:
Midnight kernel
KT747 Kernel
Common Infos about Governors,I/O Schedulers etc.
Credits to:
mialwe for his smoove governor
ktoonesz for original hotplug implementation
ZZMoove Governor v0.3
(Post from 25th February 2013, 05:06 PM - "more improvements")
there are now many new possibilities to adjust the governor more precisely via sysfs!
Following new tuneables were introduced in this new version:
The so called "sleep" values which were hardcoded in previous version are now changed
to sysfs-tuneables:
The Smooth Scaling for sleep (Screen off):
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/smooth_up_sleep
possible values from 1 to 100, default: 100
The up/down Threshold for sleep (Screen off):
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_sleep
possible Values from above "down_threshold_sleep" to 100, default: 90
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_sleep
possible Values from 11 to under "up_threshold_sleep", default: 44
The Sampling Rate for sleep (Screen off):
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/sampling_rate_sleep_multiplier
possible values 1 or 2, default: 2
The amound of cores which should run at "screen off":
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/hotplug_sleep
possible Values 0 = do not touch cores (the same behaving as in standard setting of zzmoove) 1, 2 or 3
the number of cores to run on screen off. btw. setting "4" doesn't exist as u can use "0" for that setting!
Beside of that you can now change the hotplug threshold per core independently (thx to gsw5700 for the inital idea!)
and turn cores off completely.
For that purpose following tuneables were introduced and are replacing
the old hotplug up/down threshold tuneables:
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_hotplug1
hotplug up threshold for core 1 - 0 = turn off core 1, possible range from "down_threshold" to 100, default: 68
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_hotplug2
hotplug up threshold for core 2 - 0 = turn off core 2, possible range from "down_threshold" to 100, default: 68
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_hotplug3
hotplug up threshold for core 3 - 0 = turn off core 3, possible range from "down_threshold" to 100, default: 68
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_hotplug1
hotplug down threshold for core 1 - possible range from 11 to under "up_threshold", default: 55
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_hotplug2
hotplug down threshold for core 2 - possible range from 11 to under "up_threshold", default: 55
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_hotplug3
hotplug down threshold for core 3 - possible range from 11 to unter "up_threshold", default: 55
Thanks to:
gsw5700 for the initial Idea "hotplug threshold per core".
brijmathew indirectly for the initial idea "just one core at screen off" (i think he did'nt meant exactly that in his post but hey he switched on the led in my head! *gg*)
ZZMoove Governor v0.4
(Post from 1st May 2013, 10:59 PM - "limits")
Changelog:
Frequency Limits:
First of all there is now a (by me so called) "soft" limit function for limiting frequencies at screen off but also at screen on if u wish. however i recommend to set the screen on limit always with the (if provided) max scaling functionality of the kernel as this is the better way of doing it and "works better" for following reasons: touchboost and wake up frequencies can go above that governor-soft-limit (mostly to 800/1000 mhz) because the governor has no control over these "events" and will be "bypassed" by cpufreq driver! nevertheless by setting this soft limit at screen off the use of frequencies higher than the given limit will be strongly reduced and therefore this will reduce power consumption at screen off. and that was the main intention - saving power if u do not use your phone!
For this function following new tuneables were indroduced to set in sysfs (/sys/devices/system/cpu/cpufreq/zzmoove/):
freq_limit_sleep: limit freqency at screen off (possible values 0 disable limit, 200000-1600000, default: 0)
freq_limit: limit freqency at screen on (possible values 0 disable limit, 200000-1600000, default: 0)
Fast Scaling:
As a second feature in this new version i added the so called (again by me *g*) "fast scaling" for faster up/down scaling! This should bring more performance but on the other hand this can be of course a little bit more power consumptive. try it, it makes things snappier and some people reported that with this setting touch boost can then also be disabled which wasn't really "possible" with previous versions of zzmoove governor.
For this function following new tuneables were indroduced to set in sysfs (/sys/devices/system/cpu/cpufreq/zzmoove/):
fast_scaling: fast scaling at screen on (possible values 0 disable or 1 enable, default: 0)
fast_scaling_sleep: fast scaling at screen off (possible values 0 disable or 1 enable, default: 0)
As last "feature" and to complete the "set" the tuneable "freq_step_sleep" was included to be able to change freq step only at screen off
possible settings are the same as the "freq_step" tuneable which are values from 0% (stops freq scaling) to 100% (switches frequencies from lowest to highest frequency and vice versa like ondmand governor) default is 1 in all settings (bat/opt/perf) at screen off.
ZZMoove Governor v0.5 aka "The Beast"
(performance and fixes)
Changelog:
- completely reworked fast scaling functionality. now using a "line jump" logic instead of fixed freq "colums".
fast scaling now in 4 steps and 2 modes possible (mode 1: only fast scaling up and mode2: fast scaling up/down)
- added support for "Dynamic Screen Frequency Scaling" (original implementation into zzmoove governor highly improved by Yank555)
originated by AndreiLux more info: http://forum.xda-developers.com/showpost.php?p=38499071&postcount=3
- re-enabled broken conservative sampling down factor functionality ("down skip" method).
originated by Stratosk - upstream kernel 3.10rc1: https://git.kernel.org/cgit/linux/k...id=refs/tags/v3.10-rc1&qt=author&q=Stratos+Ka
- changed down threshold check to act like it should.
originated by Stratosk - upstream kernel 3.10rc1: https://git.kernel.org/cgit/linux/k...id=refs/tags/v3.10-rc1&qt=author&q=Stratos+Ka
- implemented/ported "early demand" from ondemand governor.
originated by Stratosk - more info: http://www.semaphore.gr/80-latests/98-ondemand-early-demand
- implemented/ported "sampling down momentum" from ondemand governor.
originated by Stratosk - more info: http://www.semaphore.gr/80-latests/80-sampling-down-momentum
- modified some original conservative code parts regarding frequency scaling which should work better now.
originated by DerTeufel1980: https://github.com/DerTeufel/androi...mmit/6bab622344c548be853db19adf28c3917896f0a0
- added the possibility to use sampling down momentum or conservative "down skip" method.
- increased possible max sampling rate sleep multiplier to 4 and sampling down factor to 100000
accordingly to sampling down momentum implementation.
- added frequency search limit for more efficient frequency searching in scaling "table" and for improving
frequency "hard" and "soft" limit handling.
- added cpu idle exit time handling like it is in lulzactive
again work from ktoonsez : https://github.com/ktoonsez/KT747-JB/commit/a5931bee6ea9e69f386a340229745da6f2443b78
description in lulzactive governor: https://github.com/ktoonsez/KT747-J...f2443b78/drivers/cpufreq/cpufreq_lulzactive.c
- fixed a little scaling step mistake and added overclocking frequencies up to 1800 mhz in scaling frequency "tables".
- fixed possible freezes during start/stop/reload of governor and frequency limit change.
- fixed hotplugging logic at online core 0+3 or 0+2 situations and improved hotplugging in general by
removing mutex locks and skipping hotplugging when it is not needed.
- added possibility to disable hotplugging (that's a debugging relict but i thought maybe someone will find that usefull so i didn't remove it)
- try to fix lags when coming from suspend if hotplug limitation at sleep was active by enabling all offline cores during resume.
- code cleaning and documentation.
for this functions following new tuneables were indroduced:
Early Demand:
early_demand -> switch to enable/disable early demand functionality (possible values 0 disable or 1 enable, default: 0)
grad_up_threshold -> scale up frequency if the load goes up in one step of grad up value (possible range from 11 to 100, default 50)
little example for understanding: when the load rises up in one big 50% step then the
frequency will be scaled up immediately instead of wating till up_threshold is reached.
Fast Scaling (improved):
Fast scaling has now 8 levels which at the same time have 2 modes included. Values from 1-4 equals to scaling jumps in the frequency table and uses the Fast Scaling up but normal scaling down mode. Values from 5-8 equals to 1-4 scaling jumps but uses the fast scaling up and fast scaling down mode.
Hotplugging switch:
disable_hotplug -> switch to enable/disable hotplugging (possible values are any value above 0 to disable hotplugging and 0 to
enable it, default 0)
Sampling Down Factor and Sampling Down Momentum:
Description: From the original author of ondemand_sampling_factor David Niemi:
"This improves performance by reducing the overhead of load evaluation and helping the CPU stay
at its top speed when truly busy, rather than shifting back and forth in speed."
And that "Sampling Down Momentum" function from stratosk does this dynamicly now!
sampling_down_max_momentum -> max sampling down factor which should be set by momentum (0 disable momentum, possible range from sampling_down_factor up to MAX_SAMPLING_DOWN_FACTOR, default 0 disabled)
sampling_down_momentum_sensitivity -> how fast the sampling down factor should be switched (possible values from 1 to 500, default 50)
sampling_down_factor -> depending on which mode is active the factor for sampling rate multiplier which influences the whole
sampling rate or the value for stock "down skip" functionality which influences only the down scaling
mechanism (possible values are from 1 to MAX_SMPLING_DOWN_FACTOR, default 1 disabled)
Original conservative "down skip" or "stock" method can be enabled by setting the momentum tuneable to 0. so if momentum is inactive there will be a fallback to the stock method. as the name "down skip" says this method works "slightly" different from the ondemand stock sampling down method (on which momentum was based on). It just skips the scaling down code for the given samples. if u want to completely disable the sampling down functionality u can achieve this by setting sampling down factor to 1. so concluded: setting sampling_down_momentum = 0 and sampling_down_factor = 1 will disable sampling down completely (that is also the governor default setting)
Dynamic Screen Frequency Scaling:
Dynamicly switches the screen frequency to 40hz or 60hz depending on cpu scaling and hotplug settings. For compiling and enabling this functionality u have to do some more modification to the kernel sources, please take a look at AndreiLux Perseus repository and there at following commit: https://github.com/AndreiLux/Perseus-S3/commit/3476799587d93189a091ba1db26a36603ee43519 After adding this patch u can enable the feature by setting "CPU_FREQ_LCD_FREQ_DFS=y" in your kernel config and if u want to check if it is really working at runtime u can also enable the accounting which AndreiLux added by setting LCD_FREQ_SWITCH_ACCOUNTING=y in the kernel config. If all goes well and u have the DFS up and running u can use following tuneables to do some screen magic: (thx to Yank555 for highly extend and improving this!)
lcdfreq_enable -> to enable/disable LCDFreq scaling (possible values 0 disable or 1 enable, default: 0)
lcdfreq_kick_in_down_delay -> the amount of samples to wait below the threshold frequency before entering low display frequency mode (40hz)
lcdfreq_kick_in_up_delay -> the amount of samples to wait over the threshold frequency before entering high display frequency mode (60hz)
lcdfreq_kick_in_freq -> the frequency threshold - below this cpu frequency the low display frequency will be active
lcdfreq_kick_in_cores -> the number of cores which should be online before switching will be active. (also useable in combination
with kickin_freq)
So this version is a kind of "featured by" release as i took (again *g*) some ideas and work from other projects and even some of that work
comes directly from other devs so i wanna thank and give credits:
First of all to stratosk for his great work "sampling down momentum" and "early demand" and for all the code fixes which found their way into
the upstream kernel version of conservative governor! congrats and props on that stratos, happy to see such a nice and talented dev directly
contibuting to the upstream kernel, that is a real enrichment for all of us!
Second to Yank555 for coming up with the idea and improving/completeing (leaves nothing to be desired now *g*) my first
rudimentary implementation of Dynamic Screen Frequency Scaling from AndreiLux (credits for the idea/work also to him at this point!).
Third to DerTeufel1980 for his first implementation of stratosk's early demand functionality into version 0.3 of zzmoove governor
(even though i had to modify the original implementation a "little bit" to get it working properly ) and for some code optimizations/fixes regarding scaling.
Last but not least again to ktoonsez - I "cherry picked" again some code parts of his ktoonservative governor which should improve this governor
too!
ZZMoove Governor 0.5.1a
(bugfixes)
urgend bugfix release:
- fix governor switching issues (deadlocks) which oviously werend fixed in version v0.5
- optimised scaling function a lot (thx and credits to Yank555!)
ZZMoove Governor 0.5.1b (in cooperation with Yank555)
(bugfixes and more optimisations)
Changelog:
- now really fixed the governor switching issues! (gotcha *****! *g*)
- again some changes in scaling logic from Yank555 (thx and credits)
- simplified some tuneables by using already available stuff instead of using redundant code (thx Yank555)
- reduced/optimised hotplug logic and preperation for automatic detection of available cores
(maybe this fixes also the scaling/core stuck problems)
ZZMoove Governor 0.6 (in cooperation with Yank555)
(flexibility)
Changelog:
- removed fixed scaling lookup tables and use the system frequency table instead
changed scaling logic accordingly for this modification (thx and credits to Yank555)
- reduced new hotplug logic loop to a minimum
- again try to fix stuck issues by using seperate hotplug functions out of dbs_check_cpu (credits to ktoonesz)
- added support for 2 and 8 core systems and added automatic detection of cores were it is needed
(for setting the different core modes you can use the macro 'MAX_CORES'. possible values are: 2,4 or 8, default are 4 cores)
reduced core threshold defaults to only one up/down default and use an array to hold all threshold values
- fixed some mistakes in "frequency tuneables" (Yank555):
stop looping once the frequency has been found
return invalid error if new frequency is not found in the frequency table
ZZMoove Governor 0.6a (in cooperation with Yank555)
(scaling logic flexibility)
Changelog:
- added check if CPU freq. table is in ascending or descending order and scale accordingly
(compatibility for systems with 'inverted' frequency table like it is on OMAP4 platform)
thanks and credits to Yank555!
ZZMoove Governor 0.7 aka "Tamed Beast" (in cooperation with Yank555)
(slow down)
Changelog:
- reindroduced the 'old way' of hotplugging and scaling in form of the 'Legacy Mode' (macros for enabling/disabling this done by Yank555, thx!)
NOTE: this mode can only handle 4 cores and a scaling max frequency up to 1800mhz.
- added hotplug idle threshold for a balanced load at CPU idle to reduce possible higher idle temperatures when running on just one core.
(inspired by @JustArchi observations, thx!)
- added hotplug block cycles to reduce possible hotplugging overhead (credits to @ktoonsez)
- added possibility to disable hotplugging only at suspend (inspired by a request of @STAticKY, thx for the idea)
- introduced hotplug frequency thresholds (credits to Yank555)
- hotplug tuneables handling optimized (credits to Yank555)
- added version information tuneable (credits to Yank555)
for this functions following new tuneables were indroduced:
legacy_mode -> for switching to the 'old' method of scaling/hotplugging. possible values 0 to disable, any values above 0 to enable (default is 0)
NOTE: the legacy mode has to be enabled by uncommenting the macro ENABLE_LEGACY_MODE
hotplug_idle_threshold -> amount of load under which hotplugging should be disabled at idle times (respectively at scaling minimum). possible values 0 disable, from 1 to 100 (default is 0)
hotplug_block_cycles -> slow down hotplugging by waiting a given amount of cycles before plugging. possible values 0 disbale, any values above 0 (default is 0)
disable_hotplug_sleep -> same as disable_hotplug but will only take effect at suspend. possible values 0 disable, any values above 0 to enable (default is 0)
up_threshold_hotplug_freq1 -> hotplug up frequency threshold for core1. possible values 0 disable and range from over down_threshold_hotplug_freq1 to max scaling freqency (default is 0)
up_threshold_hotplug_freq2 -> hotplug up frequency threshold for core2. possible values 0 disable and range from over down_threshold_hotplug_freq2 to max scaling freqency (default is 0)
up_threshold_hotplug_freq3 -> hotplug up frequency threshold for core3. possible values 0 disable and range from over down_threshold_hotplug_freq3 to max scaling freqency (default is 0)
down_threshold_hotplug_freq1 -> hotplug down frequency threshold for core1. possible values 0 disable and range from min saling to under up_threshold_hotplug_freq1 freqency (default is 0)
down_threshold_hotplug_freq2 -> hotplug down frequency threshold for core2. possible values 0 disable and range from min saling to under up_threshold_hotplug_freq2 freqency (default is 0)
down_threshold_hotplug_freq3 -> hotplug down frequency threshold for core3. possible values 0 disable and range from min saling to under up_threshold_hotplug_freq3 freqency (default is 0)
version -> show the version of zzmoove governor
ZZMoove Governor 0.7a
(little fix)
Changelog:
- fixed a glitch in hotplug freq threshold tuneables which prevented setting of values in hotplug down freq thresholds when hotplug
up freq thresholds were set to 0. NOTE: enabling the legacy mode in the source is not part of that fix i just forgot to set it back to standard (disabled) before pushing, sry to lazy to fix that fix now
ZZMoove Governor 0.7b
(compatibility improved and forgotten things)
Changelog:
- fixed stuck at max scaling frequency when using stock kernel sources with unmodified cpufreq driver and without any oc capabilities.
- readded forgotten frequency search optimisation in scaling logic (only effective when using governor soft frequency limit)
- readded forgotten minor optimisation in dbs_check_cpu function.
- as forgotten to switch in last version Legacy Mode now again disabled by default
- minor code format and comment fixes
ZZMoove Governor 0.7c
(again compatibility and optimisations)
Changelog:
- frequency search optimisation now fully compatible with ascending ordered system frequency tables (thx to @psndna88 for testing!)
- again minor optimisations at multiple points in dbs_check_cpu function
- code cleaning - removed some unnecessary things and whitespaces nuked - sry for the bigger diff but from now on it will be clean!
- corrected changelog for previous version regarding limits
ZZMoove Governor 0.7d (bugfix!)
(broken things)
Changelog:
- fixed hotplug up threshold tuneables to be able again to disable cores manually via sysfs by setting them to 0
- fixed the problem caused by a "wrong" tuneable apply order of non sticking values in hotplug down threshold tuneables when
hotplug up values are lower than down values during apply.
NOTE: due to this change right after start of the governor the full validation of given values to these tuneables is disabled till
all the tuneables were set for the first time. so if you set them for example with an init.d script or let them set automatically
with any tuning app be aware that there are illogical value combinations possible then which might not work properly!
simply be sure that all up values are higher than the down values and vice versa. after first set full validation checks are enabled
again and setting of values manually will be checked again.
- fixed a typo in hotplug threshold tuneable macros (would have been only a issue in 8-core mode)
- fixed unwanted disabling of cores when setting hotplug threshold tuneables to lowest or highest possible value
which would be a load of 100%/11% in up/down_hotplug_threshold and/or scaling frequency min/max in up/down_hotplug_threshold_freq
CPU Governor ZZMoove Changelog
ZZMoove Governor 0.8
(cool down baby!)
Changelog:
- indroduced scaling block cycles (in normal and legacy mode) to reduce unwanted jumps to higher frequencies (how high depends on settings) when a load comes up just for a short peroid of time or is hitting the scaling up threshold more often because it is within some higher to mid load range. reducing these jumps lowers CPU temperature in general and may also save some juice. so with this function u can influence the little bit odd scaling behaving when you are running apps like for example games which are constantly 'holding' system load in some range and the freq is scaled up too high for that range. in fact it just looks like so, monitoring apps are mostly too slow to catch load in realtime so you are watching almost only 'the past'. so actually it's not really odd it's more like: an app is stressing the system and holding it on a higher load level, due to this load level scaling up threshold is more often reached (even if monitoring shows a lower load than up_threshold!) the governor scales up very fast (usual zzmoove behaving) and almost never scales down again (even if monitoring shows a lower load than down_threshold!). now in patricular these scaling block cycles are throttling up scaling by just skipping it for the amount of cycles that you have set up and after that are making a forced scale down in addition for the same amount of cycles. this should bring us down to a 'appropriate' frequency when load is hanging around near up threshold.
- indroduced (D)ynamic (S)ampling (R)ate - thx to hellsgod for having the same idea at the same time and pointing me to an example. even though at the end i did 'my way' DSR switches between two sampling rates depending on the given load threshold from an 'idle' to a 'normal' one.
- added read only tuneable 'sampling_rate_current' for DSR to show current SR and internally use this sampling rate instead of automatically changing 'sampling_rate' tuneable in DSR. this keeps things more compatible and avoids problems when governor tuneables are set with tuning apps which are saving actual shown values.
- changed setting of sampling rate in governor from 'sampling_rate' to 'sampling_rate_current' and the value at suspend to 'sampling_rate_idle' value instead of using current active sampling rate to avoid accidentally setting of 'normal operation' sampling rate in sampling rate idle mode which has usually a much lower value.
- indroduced build-in profiles in seperate header file (credits to Yank555 for idea and prototype header file) you can switch between multible build in profiles by just piping a number into the tuneable 'profile_number'. all tuneable values of the set profile will be applied on-the-fly then. if a profile is active and you change any tuneable value from it to a custom one the profile will switch to '0' in 'profile_number' and 'custom' in 'profile' for information. with this profiles support developers can simplify their governor settings handling by adding all their desired and well proven governor settings into the governor itself instead of having to fiddle around with init.d scripts or tuning apps. NOTE: this is just an optional feature, you can still set all tuneables as usual just pay attention that the tuneable 'profile_number' is set to '0' then to avoid overwriting values by any build-in profile! for further details about profiles and adding own ones check provided 'cpufreq_zzmoove_profiles.h' file.
- added 'profiles_version' tuneable to be able to show seperate profiles header file version.
- added enabling of offline cores on governor exit to avoid cores 'stucking' in offline state when switching to a non-hotplug-able governor
and by the way reduced reduntant code by using an inline function for switching cores on and using the better 'sheduled_work_on-way' at all needed places in the code for that purpose.
- moved some code parts to legacy mode macro which has only relevance when including the legacy mode in the governor and in addition excluded it during runtime if legacy mode is disabled.
- improved freq limit handling in tuneables and in dbs_check_cpu function
- changed value restriction from '11' to '1' in hotplug down threshold and grad up tuneables as this restriction is only nessesary in
scaling down tuneable
- added missing fast scaling down/normal scaling up mode to fast scaling functionality (value range 9-12 and only available in non-legacy mode thx @OldBoy.Gr for pointing me to that missing mode!)
- added auto fast scaling aka 'insane' scaling mode to fast scaling functionality - lucky number 13 enables this mode in fast_scaling tuneable NOTE: a really funny mode, try it but keep in mind setting this in combination with a set freq limit (at sleep or awake)would not make much sense as there is not enough frequency range available to jump around then.
- back from the precautious 'mutex_try_lock' to normal 'mutex_lock' in governor 'LIMIT' case -> this should be save again, no deadlocks expected any more since hotplug logic has significantly changed in zzmoove version 0.6
- removed also the no longer required and precautious skipping of hotplugging and dbs_check_cpu on multiple places in code and removed the mutex locks at governor stop and early suspend/late resume
- added hotlug freq thresholds to legacy scaling mode (same usage as in normal scaling mode)
- seperated hotplug down and up block cycles to be more flexible. this replaces 'hotplug_block_cycles' with 'hotplug_block_up_cycles' tuneable and adds one new tunable 'hotplug_block_down_cycles'. functionality is the same as before but u can now differentiate the up and down value.
- added 'early demand sleep' combined with automatic fast scaling (fixed to scaling up mode 2) and if not set already automatic (depending on load) switching of sampling rate sleep multiplier to a fixed minimum possible multiplier of 2. this should avoid mostly audio or general device connection problems with 'resource hungrier' apps like some music players, skype, navigation apps etc. and/or in combination with using bluetooth equipment during screen is off. NOTE: this overwrites a possible fast 'scaling_sleep' setting so use either this or 'fast_scaling_sleep'
- added some missing governor tunebable default value definitions
- removed tuneable apply order exception and removed analog value checks in hotplug threshold and hotplug frequency tuneables to avoid tuneable values not changing issues. NOTE: keep in mind that all 'down' values should be lower then the analog 'up' values and vice versa!
- removed 200 mhz up hotplugging restriction, so up hotplugging starts at 200 mhz now
- removed some unnecessary macros in scaling logic
- added maximum fast scaling and frequency boost to late resume to react wakeup lags
- merged some improvements from ktoonservativeq governor version for the SGS4 (credits to ktoonsez)
changes from here: https://github.com/ktoonsez/KT-SGS4/commits/aosp4.4/drivers/cpufreq/cpufreq_ktoonservativeq.c
Use dedicated high-priority workqueues
Use NEW high-priority workqueue for hotplugging
Improved hotplugging in general by reducing calls to plugging functions if they are currently running,
by reducing calls to external function in up plugging and by changing the down plug loop to an optimized one
- added hotplug boost switch to early demand functionality and up hotplugging function
- added 'hotplug_idle_freq' tuneable to be able to adjust at which frequency idle should begin
- transfered code for frequency table order detection and limit optimisation into a inline function and use this function in START,LIMIT case and early suspend/late resume instead of using redundant code
- execute table order detection and freq limit optimization calculations at 'START' and 'LIMIT' case to avoid possible wrong setting of freq
max after governor start (currently set max frequency value was sometimes not applied) and a wrong soft limit optimization setting after undercutting the soft limit with a lower hard limit value
- minor optimisation in hotplug, hotplug block and in all freq search logic parts
- added debugging sysfs interface (can be included/excluded using #define ZZMOOVE_DEBUG) - credits to Yank555!
- added some missing annotation as a prepareation and mainly to avoid some errors when compiling zzmoove in combination with 3.4+ kernel sources
- fixed hotplugging issues when cpufreq limit was set under one or more hotplugging frequency thresholds NOTE: now hotplugging frequency thresholds will be completely disabled and a fall back to normal load thresholds will happen if the maximal possible frequency will undercut any frequency thresholds
- fixed stopping of up scaling at 100% load when up threshold tuneable is set to the max value of 100
- fixed smooth up not active at 100% load when smooth up tuneable is set to the max value of 100
- fixed many code style and dokumentation issues and made a massive code re-arrangement
for this functions following new tuneables were indroduced:
early_demand_sleep -> same function as early demand on awake but in addition combined with fast scaling and sampling rate switch and only active at sleep. (possible values 0 disable or 1 enable, default is 1)
grad_up_threshold_sleep -> 2 way functionality: early demand sleep grad up (load gradient) threshold and at the same time load threshold for switching internally (tuneables are staying at set values!) sampling_rate_sleep_multiplier to 2 and fast_scaling to 2 (possible values from 1 to 100, default is 35)
hotplug_block_up_cycles -> (replaces hotplug_block_cycles) slow down up hotplugging by waiting a given amount of cycles before plugging. possible values 0 disbale, any values above 0 (default is 0)
hotplug_block_down_cycles -> (replaces hotplug_block_cycles) slow down down hotplugging by waiting a given amount of cycles before plugging. possible values 0 disbale, any values above 0 (default is 0)
hotplug_idle_freq -> freq at which the idle should be active (possible values 0 disable and any possible scaling freq, default is 0)
sampling_rate_current -> read only and shows currently active sampling rate
sampling_rate_idle -> sampling rate which should be used at 'idle times' (possible values are any sampling rate > 'min_sampling_rate', 0 to disable whole function, default is 0)
sampling_rate_idle_delay -> delay in cycles for switching from idle to normal sampling rate and vice versa (possible values are any value and 0 to disable delay, default is 0)
sampling_rate_idle_threshold -> threshold under which idle sampling rate should be active (possible values 1 to 100, 0 to disable function, default is 0)
scaling_block_cycles -> amount of gradients which should be counted (if block threshold is set) and at the same time up scaling should be blocked and after that a forced down scaling should happen (possible values are any value, 0 to disable that function, default is 0)
scaling_bock_freg -> frequency at and above the blocking should be active (possible values are any possible scaling freq, 0 to enable blocking permanently at every frequency, default is 0)
scaling_block_threshold -> gradient (min value) of load in both directions (up/down) to count-up cycles (possible value are 1 to 100, 0 to disable gradient counting)
scaling_block_force_down -> multiplicator for the maximal amount of forced down scaling cycles (force down cycles = block_cycles * force_down) therefore the forced down scaling duration (possible value are 2 to any value, 0 to disable forced down scaling and use only scaling up blocks)
profile -> read only and shows name of currently active profile ('none' = no profile, 'custom' = a profile value has changed)
profile_number -> switches profile (possible value depends on amount of profiles in cpufreq_zzmoove_profiles.h file, please check this file for futher details!) 0 no profile set = tuneable mode, default 0)
version_profiles -> read only and shows version of profile header file
if ZZMOOVE_DEBUG is defined:
debug -> read only and shows various usefull debugging infos
ZZMoove Governor 1.0 Final
(EOL)
Changelog:
EOL commit: https://github.com/zanezam/cpufreq-governor-zzmoove/commit/b22eed13461fbb59b8e9e0121656582d6ef10696
Governor: https://github.com/zanezam/cpufreq-governor-zzmoove/blob/snapdragon/CHANGELOG.txt
Profiles: https://github.com/zanezam/cpufreq-governor-zzmoove/blob/snapdragon/CHANGELOG_PROFILES.txt
Current Test-Versions (obsolete but kept for reference):
Version 1.0 beta8
(outbreak)
Changelog:
https://github.com/zanezam/cpufreq-governor-zzmoove/commit/bef4355a652fdfc268b774e874b355bd269dbc07
Version 1.0 beta7a (bugfix)
(outbreak)
Changelog:
https://github.com/zanezam/cpufreq-governor-zzmoove/commit/1ce22579b0e6dfce0d9916b9f0644e7d707d8587
Version 1.0 beta7 (sync)
(outbreak)
Changelog:
https://github.com/zanezam/cpufreq-governor-zzmoove/commit/52ad61b169c24258ec1b0e6a630bbab5142faa67
Version 1.0 beta6a (Andip71 aka Lord Boeffla)
(outbreak)
Changelog (credits to Andip71):
https://github.com/zanezam/cpufreq-governor-zzmoove/commit/9b01250eb988e86c98d289dabe6773ba748f58dd
Version 1.0 beta6 (feature preview, for opo only atm.)
(outbreak)
Changelog:
https://github.com/zanezam/cpufreq-governor-zzmoove/commit/75c431aeff8354f224e4c688faa1559ac463ab8a
Version 1.0 beta5
(outbreak)
Changelog:
https://github.com/zanezam/cpufreq-governor-zzmoove/commit/1d2727cb9cefe0484573ace9e0dc9b55ba6c26f6
Version 1.0 beta4 (sync)
(outbreak)
Changelog:
- use again the conservative governor usual canceling of dbs work syncron instead of asyncron when exiting the governor as this change was
only needed in combination with older hotplug implementations. as also done in opo version removed again all previously merged kernel crash
fix attempts and precautions as they were not really needed
- bump version to beta4 to bring opo/i9300 versions in sync again
Version 1.0 beta3 (bugfix for opo-bacon)
(outbreak)
Changelog:
- changed back canceling of dbs work to syncron instead of asyncron in dbs_timer_exit function to avoid random kernel chrashes (again oops in smp.c)
when using this governor with the cpufreq implementation of kernel versions 3.10+. problem was initiated by governor restarts during hotplugging
- as an additional precaution check if a core is online before doing critical stuff in dbs_check_cpu main function (might be removeable at a later
time, more analyses/tests will show)
profile header file (Version 0.3 beta2 OPO)
- corrected/adjusted sampling rate values in settings where they were lower than the minimal possible value of 60000
Version 1.0 beta2
(outbreak)
Changelog:
- avoid kernel crash (usually a oops in smp.c) by checking if a core is online before putting work on it: this problem appeared on opo qualcomm
platform with proprietary mpdecision hotplugging service. assumption is that there is a delay between initiating hotplugging events from 'userland'
and gathering core state info in 'kernel land' so under some rare circumestances the governor doesn't 'know about' a changed core state and tries to
put work on a meanwhile offline core or that hotplug event happend during putting work on a core in the governor.
Version 1.0 beta1
(outbreak)
Changelog:
- bump version to 1.0 beta1 because of brought forward plan 'outbreak'
- reworked scaling logic:
removed unessesary calls of external cpufreq function and use a static variable instead to hold the system freq table during runtime fixed frequency stuck on max hard and soft frequency limit (under some circumstances freq was out of scope for the main search loop) and added precautions to avoid problems when for what ever reason the freq table is 'messed' or even not available for the governor fixed not properly working scaling with descend ordered frequency table like it is for example on qualcomm platform added additional propotional scaling mode (mode '1' as usual decide and use the lowest freq, new mode '2' use only propotional frequencies like ondemand governor does - switchable as before in 'scaling_proportional' tuneable)
- use static frequency table variable in all frequency checks agains system frequency table in the governor
- fixed 'update_ts_time_stat idle accounting' (kernel patch for kernel version 3.0.x needed, example available in github zzmoove repository)
- fixed non setting of scaling down threshold tuneables under some circumstances (issue on kernel 3.4 when running multible zzmoove instances)
- changed some variable names in scaling range evaluation and debugging tuneable
- added compatibility for kernel version 3.4 (or higher, but only tested on 3.4.0 yet)
- added compatibility for cpufreq implementation used since kernel version 3.10 (NOTE: for backports u can use the macro CPU_IDLE_TIME_IN_CPUFREQ)
- added support for powersuspend (used on some platforms since kernel version 3.4)
- added support for opo specific 'backlight ext control' (kernel patch for opo bacon devices needed, example available in github zzmoove repository)
- added macros to exclude hotplugging functionality (default in this version is enabled=uncommented)
profile header file (Version 0.3 beta1)
- bump version to 0.3 beta1 because of brought forward plan 'outbreak'
- removed dynamic freq scaling tuneable leftovers
- added macros to switch code depending of used power management implementation
or used supend/resume backlight hook (opo specific)
- added macros to be able to disable hotplugging
Version 0.9 beta4
(slimline)
Changelog:
- removed 'freq_step' functionality as it never had any function in this governor. it was a left over from mialwes 'smoove' governor and also
had no function in his governor back then. so yeah all the 'feelings' about it's influence were placebo
- introduced 'proportional scaling' for more 'connectivity' to current load, this should give more 'balanced' frequencies
in general. when enabled all targeted frequencies in scaling logic will be compared with the ones from system table method and at the end
the lowest of them both will be used. so all used scaling frequencies will be 'tentential' lower in both directions
- added support for exynos4 CPU temperature reading (patches available in zzmoove repositories: https://github.com/zanezam)
this must be enabled via 'CONFIG_EXYNOS4_EXPORT_TEMP=y' in the config of a kernel which has exynos4 CPU temperature export
implementation
included. the default temp polling interval is 1000 ms and can be set with DEF_TMU_READ_DELAY. however the TMU driver has it's own polling
interval which is 10 seconds, so leaving it at the default value of 1 second is recommended temperature reading will only be enabled if the
tuneable 'scaling_block_temp' is set and will be disabled whenever early suspend is entered
- if exynos4 CPU temperature reading is enabled in the code use current CPU temperature in scaling block functionality to be able to 'hold' the cpu
temperatue to the given one in 'scaling_block_temp'. this function is used in combination with the already existent tuneable 'scaling_block_freq'
so u have to set both to enable it. the possible temperature range is 30°C to 80°C (lower temps are making no sense and higher temps would reach
into exynos4 TMU driver trottling range)
- if exynos4 CPU temperature reading is enabled added current CPU temperature to debug info tuneable
- added auto adjustment of all available frequency thresholds when scaling max limit has changed
- again some code style and comment changes/fixes
profile header file (Version 0.2 beta3):
- added scaling block temperature tuneable to all profiles if CONFIG_EXYNOS4_EXPORT_TEMP is defined
- use CPU temperature treshold of 65°C instead of 15 scaling block cycles in game profile if
CONFIG_EXYNOS4_EXPORT_TEMP is defined
- added proportional frequency tuneable to all profiles
- added auto adjust freq thresholds to all profiles (disabled by default)
- enabled scaling proportional in ybat, ybatext, zzbat, zzbatp, zzmod and zzgame profile
- enabled scaling fast down over 1200MHz and resposiveness over 400Mhz with up threshold of 20
in ybat, ybatext, zzbat, zzbatp, and zzmod profile
- added core macros to exclude not used code like it is in governor
- removed freq_step tuneable from all profiles
Version 0.9 beta3
(slimline)
Changelog:
merged some changes originated by ffolkes (all credits and thx to him)
(source https://github.com/ffolkes/android_...44e1e3190d5/drivers/cpufreq/cpufreq_zzmoove.c
- reordered sysfs attributes
description by ffolkes: some apps set tuneables by the order in which they are listed in the filesystem. this causes problems when one
tuneable needs another set first in order to correctly validate. (e.g. you cannot set down_threshold properly until you have first set up_threshold)
- added 'fast down' functionality (based on commits to pegasusq in perseus by andreilux and extended for this version by ZaneZam)
description by ffolkes: fastdown dynamically applies a (presumably) higher up_threshold and down_threshold after a frequency threshold has been reached. the goal is to encourage less time spent on the highest frequencies
- added 'hotplug engage' functionality
description by ffolkes: when set >0, will not bring any cores online until this frequency is met or exceeded
goal: reduce unnecessary cores online at low loads
- added 'scaling responsiveness' functioniality
description by ffolkes: similar to 'frequency for responsiveness' in other governors
defines a frequency below which we use a different up_threshold to help eliminate lag when starting tasks
- instead of failing when set too high in down_threshold tuneables set the value to the highest it can safely go
- increased possible sampling rate sleep multiplier value to a max of 8 (ZaneZam)
- added missing error handling to some tuneables (ZaneZam)
- fixed non setting of 'hotplug_sleep' tuneable when applying profiles (ZaneZam)
- added up/down threshold to debug tuneable (ZaneZam)
- some code style and comment changes/fixes (ZaneZam)
for this functions following new tuneables were introduced:
scaling_fastdown_freq-> will be enabled once this frequency has been met or exceeded (0 to disable, all possible system frequencies, default is 0)
scaling_fastdown_up_threshold-> once the above frequency threshold has been met, this will become the new up_threshold until we fall below the scaling_fastdown_freq again. (range from over fastdown_down_threshold to 100, default is 95)
scaling_fastdown_down_threshold-> once the above frequency threshold has been met, this will become the new down_threshold until we fall below the scaling_fastdown_freq again. (range from 11 to under fastdown_up_threshold, default is 90)
scaling_responsiveness_freq-> will be enabled once this frequency has been met or exceeded (0 to disable, all possible system frequencies, default is 0)
scaling_responsiveness_up_threshold-> the up_threshold that will take effect if scaling_responsiveness_freq is set (range from 11 to 100, default is 30)
hotplug_engage_freq -> will not bring any cores online until this frequency is met or exceeded (0 to disable, any possible system frequencies, default is 0)
profile header file (Version 0.2 beta2):
- added values for following new tuneables (credits to ffolkes):
hotplug_engage_freq (disabled by default in all profiles)
scaling_fastdown_freq (disabled by default in all profiles)
scaling_fastdown_up_threshold (default to 95 in all profiles)
scaling_fastdown_down_threshold (default to 90 in all profiles)
scaling_responsiveness_freq (disabled by default in all profiles)
scaling_responsiveness_up_threshold (default to 30 in all profiles)
- adjusted up/down thresholds for core 2 in moderate setting
- changed sampling rate sleep multiplier from 4 to 6 in all settings (except in default setting)
Version 0.9 beta2
(slimline)
Changelog:
- support for setting a default settings profile at governor start without the need of using the tuneable 'profile_number'
a default profile can be set with the already available macro 'DEF_PROFILE_NUMBER' check zzmoove_profiles.h for details about
which profile numbers are possible. this functionality was only half baken in previous versions, now any given profile will be really
applied when the governor starts. the value '0' (=profile name 'none') in 'DEF_PROFILE_NUMBER' disables this profile hardcoding and
that's also the default in the source. u still can (with or without enabling a default profile in the macro) as usual use the tuneable
'profile_number' to switch to a desired profile via sysfs at any later time after governor has started
- added 'blocking' of sysfs in all tuneables during apply of a settings profile to avoid a possible and unwanted overwriting/double
setting of tuneables mostly in combination with tuning apps where the tuneable apply order isn't influenceable
- added tuneable 'profile_list' for printing out a list of all profiles which are available in the profile header file
- fixed non setting of 'scaling_block_force_down' tuneable when applying profiles
- some documentation added and a little bit of source cleaning
Version 0.9 beta1
(slimline)
Changelog:
- bump version to beta for public
- added/corrected version informations and removed obsolete ones
profile header file (Version 0.2 beta1):
- bump version to beta for public
- corrected version informations
Version 0.9 alpha-2
Changelog:
- added auto fast scaling step tuneables:
afs_threshold1 for step one (range from 1 to 100)
afs_threshold2 for step two (range from 1 to 100)
afs_threshold3 for step three (range from 1 to 100)
afs_threshold4 for step four (range from 1 to 100)
profile header file (Version 0.2alpha-2):
- corrected documentation
- corrected version information
- added auto fast scaling step tuneables and values to all profiles
Version 0.9 alpha1 (Yank555.lu)
Changelog (credits to Yank555!):
- splitted fast_scaling into two separate tunables fast_scaling_up and fast_scaling_down so each can be set individually
to 0-4 (skip 0-4 frequency steps) or 5 to use autoscaling.
- splitted fast_scaling_sleep into two separate tunables fast_scaling_sleep_up and fast_scaling_sleep_down so each
can be set individually to 0-4 (skip 0-4 frequency steps) or 5 to use autoscaling.
- removed legacy mode (necessary to be able to split fast_scaling tunable)
- removed LCD frequency DFS
profile header file (Version 0.2):
- split fast_scaling and fast_scaling_sleep into fast_scaling_up/fast_scaling_down and
fast_scaling_sleep_up/fast_scaling_sleep_down
- adjusted values for profiles Yank Battery and Yank Battery Extreme
Currently in the Workshop:
working on Current versions of ZZMoove big.LITTLE Edition (bLE)
Sources:
https://github.com/zanezam/cpufreq-governor-zzmoove
General project status and repository changes:
NOTE: Changes in repository since 15.08.14
the test repository was deleted and all previous beta and stable commits are available now in the main repository.
all future commits will also land there! branches in this repo are "i9300" the new merged master branch and a new one
was added "desktop" for the "desktop edition" of zzmoove (which is btw. still WIP and far from stable, but it compiles).
Since 12.10.2014 there is a new branch called "opo-bacon" where u can find a special version for One Plus One devices and
some needed additional kernel patches for it.
NOTE: Changes in repository since 12.08.15:
renamed branch 'i9300' to 'exynos' and branch 'opo-bacon' to 'snapdragon'
added CHANGELOG_PROFILES file with the changelog of the profiles header file of this version
updated README with some quick infos about predefinded settings in this version
'desktop' branch synced with current version (same base for all now, just other settings)
new 'develop' branch based on 'snapdragon' version created for quick changes, pull requests, etc.
in short this will be the main develop branch in the future and will provide changes and fixes
earlier. but this branch also shall be considered as more experimental!
NOTE: Changes in repository since 26.05.20:
rebase: fixed all broken links to implementation examples linking to original boeffla kernels (dev has retired and removed all his work)
by using links to my still available forks. deleted 'develop' branch as it's obsolete now since old versions 'snapdragon' and 'exynos' and 'desktop'
are final and EOL now. changed default branch to 'bLE-develop-k49x' which is the newest development version.
Status:
I recently did a formal change by merging all the recent changes from the already
old 'develop' branch into a new final 1.0 version on variants 'exynos',
'snapdragon' and 'desktop' which all totally can be considered as end of life.
After 'some time' of beta state and after many successful implementations
over the years, at it's 'best times' running on tousands of devices in
different kernels, beeing stable as it currently is (used it for years 24/7
on all my meanwhile 10 devices, and still do!) and as it can be (well i have
to admit sometimes it was a beast!! *gg*) im going to make the almost 3 years
old 'develop' version finally the version 1.0 and consider it as stable.
By doing this i'm also closing this old development chapter by making the
'exynos,snapdragon and desktop' versions final and EOL. The 'develop' branch
is now obsolete and gets deleted.
Finally stable, phew what a journey!
Thx to all contributing devs and ppl who contributed with their ideas, tests
and nervs when it did 'mock around'! Last but not least thx to all of those
which let 'the beast' running on their devices! I hope u all enjoyed it like i did!
NOTE: Despite me beeing not as active as some years ago with development i
want to let u know that there meanwhile exists a 'big Little brother' (poor
one even has NO version number at all yet) of ZZMoove governor which is still
happily hopping around on 'newer' devices. This newer version exists already since
about 3 years and were already running in (meanwhile also EOL) boeffla kernels for
the OnePlus 3/5 and also can be found in some recent OnePlus 6 kernels (at least in the ones i
fiddled recently *g*). By the way i shamelessly take the opportunity: If u still
have a OnePlus 6/6T u really you should consider trying one of these builds, more
info can be found here: https://github.com/zanezam/ZZupreme-Builds
ZZMoove still rocks by significantly influencing speed and battery usage in a
positive way! Just saying.
Enjoy!
ZZMoove Governor Settings
Description of how u can switch build in Profiles
Beside of the well known ones like "Yank...","Battery","Performance" etc. settings
i did some new ones for ZZMoove v1.0 in addition which can be checked out
in particular in the new profile exynos header file provided HERE
So for those of u which have not the possibility to switch profiles with kernel dev provided tools/scripts/or what
ever but still want to switch to any of the build in settings you can do following:
use tools like Android Tuner ,SetCPU, Kernel Adiutor or similar tools which are supporting the change of multible tuneables on-the-fly or just do it directly in kernel sysfs via a terminal emulator and give the tuneable "profile_number" one of the following values:
for Default (set governor defaults)
for Yank Battery -> old untouched setting (a very good battery/performance balanced setting DEV-NOTE: highly recommended!)
for Yank Battery Extreme -> old untouched setting (like yank battery but focus on battery saving)
for ZaneZam Battery -> old untouched setting (a more 'harsh' setting strictly focused on battery saving DEV-NOTE: might give some lags!)
for ZaneZam Battery Plus -> NEW! reworked 'faster' battery setting (DEV-NOTE: recommended too! )
for ZaneZam Optimized -> old untouched setting (balanced setting with no focus in any direction DEV-NOTE: relict from back in the days, even though some people still like it!)
for ZaneZam Moderate -> NEW! setting based on 'zzopt' which has mainly (but not strictly only!) 2 cores online
for ZaneZam Performance -> old untouched setting (all you can get from zzmoove in terms of performance but still has the fast down scaling/hotplugging behaving)
for ZaneZam InZane -> NEW! based on performance with new auto fast scaling active. a new experience!
for ZaneZam Gaming -> NEW! based on performance with new scaling block enabled to avoid cpu overheating during gameplay
for ZaneZam Relax -> NEW! based on moderate (except hotplug settings) with relaxed sleep settings (to react audio/bluetooth/wakeup issues)
for asad007 lwk -> NEW! made by xda user asad007 with yet unknown direction
(since version 0.9 beta4: cpu temperature threshold of 65°C enabled if exynos4 cpu temperature reading support was compiled with the governor)
after a tunebable view-refresh in the tools/console u can see the name of the currently set profile in the "profile" tuneable,
but keep in mind not every tool supports returning chars in tunebables as some of them are internally handling them as numbers,
even though in fact they are chars in kernel sysfs so u might see a "-1" then (for example with SetCPU) not so with
Android Tuner which shows (again) what a great app this is.
Some last note for the game profile: plz do not complain about ingame performance issues or lags with this setting.
i tuned it to be more aggressive in terms of bringing freq down. reference game was angy birds star wars *g* calming
down zzmoove while playing this game was really a chellange, don't know why but it stresses the system a lot more
than others and u know how 'hasty' zzmoove can be another test game was temple run 2 and here u can see a significant
improvement with this setting. it's a bit difficult to give u THE universal setting for all games as they differ too much in terms
of how much the system is stressed by them. so we have to share our experiences to further optmize it till i made scaling
blocks more "intelligent" and therefore more automatically (idea already exists!!)
Have fun with all the settings and feel free to report back how they work for you, and/or post new ones! :highfive:
You're the Master of text!
Great and detailed
Gesendet von meinem GT-I9300 mit Tapatalk 2
romskii said:
You're the Master of text!
Great and detailed
Gesendet von meinem GT-I9300 mit Tapatalk 2
Click to expand...
Click to collapse
hehe thx i try my best to make it understandable
but i'm just about editing to shorten this novel
I do not know, but this makes the problem gov.mi / freeze and delay / I do not know where the problem is.?
I use boeffla kernel and I zzmove and still the problem
the gov.pegasusq so good
misacek said:
I do not know, but this makes the problem gov.mi / freeze and delay / I do not know where the problem is.?
I use boeffla kernel and I zzmove and still the problem
the gov.pegasusq so good
Click to expand...
Click to collapse
you are on actual beta boeffla kernel, right? do you have this on all provided settings up to "perf"? Do you uv? if so try to avoid uv for some time just to exclude this. and if you have zram enabled, can u try without this too? or maybe there is some app which is not dancing with the "beast" ? all guessed sorry can not give more advices, actual boeffla/zzmoove version runs without problems on my phone.
Great thanks I'll keep trying and testing
Finally we have a thread for zzmove governor!! :victory:
Great explanations Zane! I don't understand a few things though haha.
This is very useful, thank you very much. I'll try to learn and test tweaks for this governor, but will be probably asking you about some new features I don't get to understand
Thanks!! :good::good:
Enviado desde mi GT-I9300 usando Tapatalk 2
the best is disable touchboost or enable=?
I'm very happy for this thread! !
I will study it to understand better zzmove
un pò di tap qui e là...
Rom: Maya Rom v5.2
Kernel: Boeffla 2.12 beta 8
Modem: Buemc2
Operator: Tim
Recovery: Philz touch
@ZaneZam
I've been trying to setup lcdfreq to stay on 40hz regardless of frequency and cores.. No matter how I set it up I can't get it to sit on 40... I can get it to sit on 40 MOST of the time, but not ALL the time...
Any help appreciated..
Oh and I'm using temasek's ROM (RC5.4.1) and kernel (160613 wolfston with abb)..
Thanks
TP.
core720 said:
the best is disable touchboost or enable=?
Click to expand...
Click to collapse
since version 0.4 u can if u want, on earlier versions it lagged like hell.
it works quite well without touchboost on v0.5.x but for my taste i leave it on as i want my phone as touch responsive as possible.
but just try it maybe u like it without touchboost.
STAticKY said:
@ZaneZam
I've been trying to setup lcdfreq to stay on 40hz regardless of frequency and cores.. No matter how I set it up I can't get it to sit on 40... I can get it to sit on 40 MOST of the time, but ALL the time...
Any help appreciated..
Oh and I'm using temasek's ROM (RC5.4.1) and kernel (160613 wolfston with abb)..
Thanks
TP.
Click to expand...
Click to collapse
ok have u tried to enter 1300000? (assuming 1400000 is your max scaling setting) that should enable it all the time.
i dunno exaclty which lcd freq scaling implementation is used in temaseks kernel but i assume it's the original from
andreilux. in this implementation there is an additional touchboost switch which we removed in the boeffla
implementation. if i remember right this touchboost switch enabales hi frequency on touch. so your settings
might be overwritten by this.
ZaneZam said:
ok have u tried to enter 1300000? (assuming 1400000 is your max scaling setting) that should enable it all the time.
i dunno exaclty which lcd freq scaling implementation is used in temaseks kernel but i assume it's the original from
andreilux. in this implementation there is an additional touchboost switch which we removed in the boeffla
implementation. if i remember right this touchboost switch enabales hi frequency on touch. so your settings
might be overwritten by this.
Click to expand...
Click to collapse
Using max CPU freq at 1400 with lcdfreq freq threshold at 1300. Touch boost turned off.... Baffles me. I've also tryed setting max CPU freq to 1200 and lcdfreq freq threshold to 1300 because of something tema or yank said.. Can't remember what it was off hand.. I'll have a look back
TP.
core720 said:
the best is disable touchboost or enable=?
Click to expand...
Click to collapse
Zane
Enviado desde mi GT-I9300 usando Tapatalk 2
core720 said:
Zane
Enviado desde mi GT-I9300 usando Tapatalk 2
Click to expand...
Click to collapse
He answered you 3 posts up...
TP.
STAticKY said:
Using max CPU freq at 1400 with lcdfreq freq threshold at 1300. Touch boost turned off.... Baffles me. I've also tryed setting max CPU freq to 1200 and lcdfreq freq threshold to 1300 because of something tema or yank said.. Can't remember what it was off hand.. I'll have a look back
TP.
Click to expand...
Click to collapse
What Zane meant is that in Perseus, there was a touch boost for LCDfreq (I believe to remember sth like that at least), this has nothing to do with CPU touch boost. Whenever you touched the screen, LCDfreq would be bumped to 60Hz no matter what, with the idea to remove lags when actively using the device.
In case Temasek has that in his kernel, that would be something we do not have in either Boeffla nor mine ... LCDfreq scaling is purely based on the CPU freq (as per the tunables), touching the screen will not change anything in our implementation.
Might be worth checking...
JP.
Yank555 said:
What Zane meant is that in Perseus, there was a touch boost for LCDfreq (I believe to remember sth like that at least), this has nothing to do with CPU touch boost. Whenever you touched the screen, LCDfreq would be bumped to 60Hz no matter what, with the idea to remove lags when actively using the device.
In case Temasek has that in his kernel, that would be something we do not have in either Boeffla nor mine ... LCDfreq scaling is purely based on the CPU freq (as per the tunables), touching the screen will not change anything in our implementation.
Might be worth checking...
JP.
Click to expand...
Click to collapse
Yea I don't think he has that implemented. Upon touching the screen while benching, while its at 40hz it stays at 40hz
TP.

[Q&A] [INFO] [v1.0 beta5] [07-01-2015] CPU Governor ZZMoove

Q&A for [INFO] [v1.0 beta5] [07-01-2015] CPU Governor ZZMoove
Some developers prefer that questions remain separate from their main development thread to help keep things organized. Placing your question within this thread will increase its chances of being answered by a member of the community or by the developer.
Before posting, please use the forum search and read through the discussion thread for [INFO] [v1.0 beta5] [07-01-2015] CPU Governor ZZMoove. If you can't find an answer, post it here, being sure to give as much information as possible (firmware version, steps to reproduce, logcat if available) so that you can get help.
Thanks for understanding and for helping to keep XDA neat and tidy!
ZaneZam said:
Hi Guys,
i thought it would be a good idea to put all the infos of the zzmoove governor around here together on one place
for better way to find it, to have a place to dump stuff for future versions and to give support for specific questions.
for now i just copied the allready existend posts here but will edit this further when i have more time
so lets start with the first
initial version:
ZZMoove Governor v0.1
(post from 18th December 2012, 10:27 PM)
Why that “zzmoove” governor and how it works:
I thought it were pretty cool to have one of my favorite governors back from the old SGS1-days on my actual device, so i decided to take the sources and give that a try on top of boeffla kernel. It worked well so this is now the result of that experiment.
More about the internals:
Basically this is the ported SGS1 version of the well known "smoove" governor from the good old midnight kernel from Michael Weingaertner (mialwe) with a modified CPU hotplug implementation of the ktoonservative governor from ktoonesz. The original implementation from ktoonesz worked well but I observed that on idle most of the time only one cpu was going to sleep. Well that was not enough for me so I made a modification to put the other cpu's also to sleep (except cpu0). That means that this governor uses more often only one cpu on idle and as a consequence of that it needs less energy. Depending on System load and governor settings all 4 cores will be instantly up again if it is needed.
In short:
So what you can expect now from this thingy is a battery-friendly behaving hotplug conservative governor which
uses a frequency lookup table for faster upscaling (so called "smooth scaling") So this is more a energy-safer than a performer.
Tuneables/Defaults:
Sampling Rate (default=2) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/sampling_rate
Sampling Down Factor (default=4) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/sampling_down_factor
Up Threshold (default=70) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold
Up Threshold Hotplug (default=68) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_hotplug
Down Threshold (default=52) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold
Down Threshold Hotplug (default=55) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_hotplug
Ignore Nice Load (default=0) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/ignore_nice_load
Freqency Step (default=5) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/freq_step
Smooth Up (default=75) tuneable: /sys/devices/system/cpu/cpufreq/zzmoove/smooth_up
Links:
Midnight kernel
KT747 Kernel
Common Infos about Governors,I/O Schedulers etc.
Credits to:
mialwe for his smoove governor
ktoonesz for original hotplug implementation
ZZMoove Governor v0.3
(Post from 25th February 2013, 05:06 PM - "more improvements")
there are now many new possibilities to adjust the governor more precisely via sysfs!
Following new tuneables were introduced in this new version:
The so called "sleep" values which were hardcoded in previous version are now changed
to sysfs-tuneables:
The Smooth Scaling for sleep (Screen off):
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/smooth_up_sleep
possible values from 1 to 100, default: 100
The up/down Threshold for sleep (Screen off):
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_sleep
possible Values from above "down_threshold_sleep" to 100, default: 90
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_sleep
possible Values from 11 to under "up_threshold_sleep", default: 44
The Sampling Rate for sleep (Screen off):
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/sampling_rate_sleep_multiplier
possible values 1 or 2, default: 2
The amound of cores which should run at "screen off":
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/hotplug_sleep
possible Values 0 = do not touch cores (the same behaving as in standard setting of zzmoove) 1, 2 or 3
the number of cores to run on screen off. btw. setting "4" doesn't exist as u can use "0" for that setting!
Beside of that you can now change the hotplug threshold per core independently (thx to gsw5700 for the inital idea!)
and turn cores off completely.
For that purpose following tuneables were introduced and are replacing
the old hotplug up/down threshold tuneables:
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_hotplug1
hotplug up threshold for core 1 - 0 = turn off core 1, possible range from "down_threshold" to 100, default: 68
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_hotplug2
hotplug up threshold for core 2 - 0 = turn off core 2, possible range from "down_threshold" to 100, default: 68
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/up_threshold_hotplug3
hotplug up threshold for core 3 - 0 = turn off core 3, possible range from "down_threshold" to 100, default: 68
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_hotplug1
hotplug down threshold for core 1 - possible range from 11 to under "up_threshold", default: 55
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_hotplug2
hotplug down threshold for core 2 - possible range from 11 to under "up_threshold", default: 55
tuneable -> /sys/devices/system/cpu/cpufreq/zzmoove/down_threshold_hotplug3
hotplug down threshold for core 3 - possible range from 11 to unter "up_threshold", default: 55
Thanks to:
gsw5700 for the initial Idea "hotplug threshold per core".
brijmathew indirectly for the initial idea "just one core at screen off" (i think he did'nt meant exactly that in his post but hey he switched on the led in my head! *gg*)
ZZMoove Governor v0.4
(Post from 1st May 2013, 10:59 PM - "limits")
Changelog:
Frequency Limits:
First of all there is now a (by me so called) "soft" limit function for limiting frequencies at screen off but also at screen on if u wish. however i recommend to set the screen on limit always with the (if provided) max scaling functionality of the kernel as this is the better way of doing it and "works better" for following reasons: touchboost and wake up frequencies can go above that governor-soft-limit (mostly to 800/1000 mhz) because the governor has no control over these "events" and will be "bypassed" by cpufreq driver! nevertheless by setting this soft limit at screen off the use of frequencies higher than the given limit will be strongly reduced and therefore this will reduce power consumption at screen off. and that was the main intention - saving power if u do not use your phone!
For this function following new tuneables were indroduced to set in sysfs (/sys/devices/system/cpu/cpufreq/zzmoove/):
freq_limit_sleep: limit freqency at screen off (possible values 0 disable limit, 200000-1600000, default: 0)
freq_limit: limit freqency at screen on (possible values 0 disable limit, 200000-1600000, default: 0)
Fast Scaling:
As a second feature in this new version i added the so called (again by me *g*) "fast scaling" for faster up/down scaling! This should bring more performance but on the other hand this can be of course a little bit more power consumptive. try it, it makes things snappier and some people reported that with this setting touch boost can then also be disabled which wasn't really "possible" with previous versions of zzmoove governor.
For this function following new tuneables were indroduced to set in sysfs (/sys/devices/system/cpu/cpufreq/zzmoove/):
fast_scaling: fast scaling at screen on (possible values 0 disable or 1 enable, default: 0)
fast_scaling_sleep: fast scaling at screen off (possible values 0 disable or 1 enable, default: 0)
As last "feature" and to complete the "set" the tuneable "freq_step_sleep" was included to be able to change freq step only at screen off
possible settings are the same as the "freq_step" tuneable which are values from 0% (stops freq scaling) to 100% (switches frequencies from lowest to highest frequency and vice versa like ondmand governor) default is 1 in all settings (bat/opt/perf) at screen off.
ZZMoove Governor v0.5 aka "The Beast"
(performance and fixes)
Changelog:
- completely reworked fast scaling functionality. now using a "line jump" logic instead of fixed freq "colums".
fast scaling now in 4 steps and 2 modes possible (mode 1: only fast scaling up and mode2: fast scaling up/down)
- added support for "Dynamic Screen Frequency Scaling" (original implementation into zzmoove governor highly improved by Yank555)
originated by AndreiLux more info: http://forum.xda-developers.com/showpost.php?p=38499071&postcount=3
- re-enabled broken conservative sampling down factor functionality ("down skip" method).
originated by Stratosk - upstream kernel 3.10rc1: https://git.kernel.org/cgit/linux/k...id=refs/tags/v3.10-rc1&qt=author&q=Stratos+Ka
- changed down threshold check to act like it should.
originated by Stratosk - upstream kernel 3.10rc1: https://git.kernel.org/cgit/linux/k...id=refs/tags/v3.10-rc1&qt=author&q=Stratos+Ka
- implemented/ported "early demand" from ondemand governor.
originated by Stratosk - more info: http://www.semaphore.gr/80-latests/98-ondemand-early-demand
- implemented/ported "sampling down momentum" from ondemand governor.
originated by Stratosk - more info: http://www.semaphore.gr/80-latests/80-sampling-down-momentum
- modified some original conservative code parts regarding frequency scaling which should work better now.
originated by DerTeufel1980: https://github.com/DerTeufel/androi...mmit/6bab622344c548be853db19adf28c3917896f0a0
- added the possibility to use sampling down momentum or conservative "down skip" method.
- increased possible max sampling rate sleep multiplier to 4 and sampling down factor to 100000
accordingly to sampling down momentum implementation.
- added frequency search limit for more efficient frequency searching in scaling "table" and for improving
frequency "hard" and "soft" limit handling.
- added cpu idle exit time handling like it is in lulzactive
again work from ktoonsez : https://github.com/ktoonsez/KT747-JB/commit/a5931bee6ea9e69f386a340229745da6f2443b78
description in lulzactive governor: https://github.com/ktoonsez/KT747-J...f2443b78/drivers/cpufreq/cpufreq_lulzactive.c
- fixed a little scaling step mistake and added overclocking frequencies up to 1800 mhz in scaling frequency "tables".
- fixed possible freezes during start/stop/reload of governor and frequency limit change.
- fixed hotplugging logic at online core 0+3 or 0+2 situations and improved hotplugging in general by
removing mutex locks and skipping hotplugging when it is not needed.
- added possibility to disable hotplugging (that's a debugging relict but i thought maybe someone will find that usefull so i didn't remove it)
- try to fix lags when coming from suspend if hotplug limitation at sleep was active by enabling all offline cores during resume.
- code cleaning and documentation.
for this functions following new tuneables were indroduced:
Early Demand:
early_demand -> switch to enable/disable early demand functionality (possible values 0 disable or 1 enable, default: 0)
grad_up_threshold -> scale up frequency if the load goes up in one step of grad up value (possible range from 11 to 100, default 50)
little example for understanding: when the load rises up in one big 50% step then the
frequency will be scaled up immediately instead of wating till up_threshold is reached.
Fast Scaling (improved):
Fast scaling has now 8 levels which at the same time have 2 modes included. Values from 1-4 equals to scaling jumps in the frequency table and uses the Fast Scaling up but normal scaling down mode. Values from 5-8 equals to 1-4 scaling jumps but uses the fast scaling up and fast scaling down mode.
Hotplugging switch:
disable_hotplug -> switch to enable/disable hotplugging (possible values are any value above 0 to disable hotplugging and 0 to
enable it, default 0)
Sampling Down Factor and Sampling Down Momentum:
Description: From the original author of ondemand_sampling_factor David Niemi:
"This improves performance by reducing the overhead of load evaluation and helping the CPU stay
at its top speed when truly busy, rather than shifting back and forth in speed."
And that "Sampling Down Momentum" function from stratosk does this dynamicly now!
sampling_down_max_momentum -> max sampling down factor which should be set by momentum (0 disable momentum, possible range from sampling_down_factor up to MAX_SAMPLING_DOWN_FACTOR, default 0 disabled)
sampling_down_momentum_sensitivity -> how fast the sampling down factor should be switched (possible values from 1 to 500, default 50)
sampling_down_factor -> depending on which mode is active the factor for sampling rate multiplier which influences the whole
sampling rate or the value for stock "down skip" functionality which influences only the down scaling
mechanism (possible values are from 1 to MAX_SMPLING_DOWN_FACTOR, default 1 disabled)
Original conservative "down skip" or "stock" method can be enabled by setting the momentum tuneable to 0. so if momentum is inactive there will be a fallback to the stock method. as the name "down skip" says this method works "slightly" different from the ondemand stock sampling down method (on which momentum was based on). It just skips the scaling down code for the given samples. if u want to completely disable the sampling down functionality u can achieve this by setting sampling down factor to 1. so concluded: setting sampling_down_momentum = 0 and sampling_down_factor = 1 will disable sampling down completely (that is also the governor default setting)
Dynamic Screen Frequency Scaling:
Dynamicly switches the screen frequency to 40hz or 60hz depending on cpu scaling and hotplug settings. For compiling and enabling this functionality u have to do some more modification to the kernel sources, please take a look at AndreiLux Perseus repository and there at following commit: https://github.com/AndreiLux/Perseus-S3/commit/3476799587d93189a091ba1db26a36603ee43519 After adding this patch u can enable the feature by setting "CPU_FREQ_LCD_FREQ_DFS=y" in your kernel config and if u want to check if it is really working at runtime u can also enable the accounting which AndreiLux added by setting LCD_FREQ_SWITCH_ACCOUNTING=y in the kernel config. If all goes well and u have the DFS up and running u can use following tuneables to do some screen magic: (thx to Yank555 for highly extend and improving this!)
lcdfreq_enable -> to enable/disable LCDFreq scaling (possible values 0 disable or 1 enable, default: 0)
lcdfreq_kick_in_down_delay -> the amount of samples to wait below the threshold frequency before entering low display frequency mode (40hz)
lcdfreq_kick_in_up_delay -> the amount of samples to wait over the threshold frequency before entering high display frequency mode (60hz)
lcdfreq_kick_in_freq -> the frequency threshold - below this cpu frequency the low display frequency will be active
lcdfreq_kick_in_cores -> the number of cores which should be online before switching will be active. (also useable in combination
with kickin_freq)
So this version is a kind of "featured by" release as i took (again *g*) some ideas and work from other projects and even some of that work
comes directly from other devs so i wanna thank and give credits:
First of all to stratosk for his great work "sampling down momentum" and "early demand" and for all the code fixes which found their way into
the upstream kernel version of conservative governor! congrats and props on that stratos, happy to see such a nice and talented dev directly
contibuting to the upstream kernel, that is a real enrichment for all of us!
Second to Yank555 for coming up with the idea and improving/completeing (leaves nothing to be desired now *g*) my first
rudimentary implementation of Dynamic Screen Frequency Scaling from AndreiLux (credits for the idea/work also to him at this point!).
Third to DerTeufel1980 for his first implementation of stratosk's early demand functionality into version 0.3 of zzmoove governor
(even though i had to modify the original implementation a "little bit" to get it working properly ) and for some code optimizations/fixes regarding scaling.
Last but not least again to ktoonsez - I "cherry picked" again some code parts of his ktoonservative governor which should improve this governor
too!
ZZMoove Governor 0.5.1a
(bugfixes)
urgend bugfix release:
- fix governor switching issues (deadlocks) which oviously werend fixed in version v0.5
- optimised scaling function a lot (thx and credits to Yank555!)
ZZMoove Governor 0.5.1b (in cooperation with Yank555)
(bugfixes and more optimisations)
Changelog:
- now really fixed the governor switching issues! (gotcha *****! *g*)
- again some changes in scaling logic from Yank555 (thx and credits)
- simplified some tuneables by using already available stuff instead of using redundant code (thx Yank555)
- reduced/optimised hotplug logic and preperation for automatic detection of available cores
(maybe this fixes also the scaling/core stuck problems)
ZZMoove Governor 0.6 (in cooperation with Yank555)
(flexibility)
Changelog:
- removed fixed scaling lookup tables and use the system frequency table instead
changed scaling logic accordingly for this modification (thx and credits to Yank555)
- reduced new hotplug logic loop to a minimum
- again try to fix stuck issues by using seperate hotplug functions out of dbs_check_cpu (credits to ktoonesz)
- added support for 2 and 8 core systems and added automatic detection of cores were it is needed
(for setting the different core modes you can use the macro 'MAX_CORES'. possible values are: 2,4 or 8, default are 4 cores)
reduced core threshold defaults to only one up/down default and use an array to hold all threshold values
- fixed some mistakes in "frequency tuneables" (Yank555):
stop looping once the frequency has been found
return invalid error if new frequency is not found in the frequency table
ZZMoove Governor 0.6a (in cooperation with Yank555)
(scaling logic flexibility)
Changelog:
- added check if CPU freq. table is in ascending or descending order and scale accordingly
(compatibility for systems with 'inverted' frequency table like it is on OMAP4 platform)
thanks and credits to Yank555!
ZZMoove Governor 0.7 aka "Tamed Beast" (in cooperation with Yank555)
(slow down)
Changelog:
- reindroduced the 'old way' of hotplugging and scaling in form of the 'Legacy Mode' (macros for enabling/disabling this done by Yank555, thx!)
NOTE: this mode can only handle 4 cores and a scaling max frequency up to 1800mhz.
- added hotplug idle threshold for a balanced load at CPU idle to reduce possible higher idle temperatures when running on just one core.
(inspired by @JustArchi observations, thx!)
- added hotplug block cycles to reduce possible hotplugging overhead (credits to @ktoonsez)
- added possibility to disable hotplugging only at suspend (inspired by a request of @STAticKY, thx for the idea)
- introduced hotplug frequency thresholds (credits to Yank555)
- hotplug tuneables handling optimized (credits to Yank555)
- added version information tuneable (credits to Yank555)
for this functions following new tuneables were indroduced:
legacy_mode -> for switching to the 'old' method of scaling/hotplugging. possible values 0 to disable, any values above 0 to enable (default is 0)
NOTE: the legacy mode has to be enabled by uncommenting the macro ENABLE_LEGACY_MODE
hotplug_idle_threshold -> amount of load under which hotplugging should be disabled at idle times (respectively at scaling minimum). possible values 0 disable, from 1 to 100 (default is 0)
hotplug_block_cycles -> slow down hotplugging by waiting a given amount of cycles before plugging. possible values 0 disbale, any values above 0 (default is 0)
disable_hotplug_sleep -> same as disable_hotplug but will only take effect at suspend. possible values 0 disable, any values above 0 to enable (default is 0)
up_threshold_hotplug_freq1 -> hotplug up frequency threshold for core1. possible values 0 disable and range from over down_threshold_hotplug_freq1 to max scaling freqency (default is 0)
up_threshold_hotplug_freq2 -> hotplug up frequency threshold for core2. possible values 0 disable and range from over down_threshold_hotplug_freq2 to max scaling freqency (default is 0)
up_threshold_hotplug_freq3 -> hotplug up frequency threshold for core3. possible values 0 disable and range from over down_threshold_hotplug_freq3 to max scaling freqency (default is 0)
down_threshold_hotplug_freq1 -> hotplug down frequency threshold for core1. possible values 0 disable and range from min saling to under up_threshold_hotplug_freq1 freqency (default is 0)
down_threshold_hotplug_freq2 -> hotplug down frequency threshold for core2. possible values 0 disable and range from min saling to under up_threshold_hotplug_freq2 freqency (default is 0)
down_threshold_hotplug_freq3 -> hotplug down frequency threshold for core3. possible values 0 disable and range from min saling to under up_threshold_hotplug_freq3 freqency (default is 0)
version -> show the version of zzmoove governor
ZZMoove Governor 0.7a
(little fix)
Changelog:
- fixed a glitch in hotplug freq threshold tuneables which prevented setting of values in hotplug down freq thresholds when hotplug
up freq thresholds were set to 0. NOTE: enabling the legacy mode in the source is not part of that fix i just forgot to set it back to standard (disabled) before pushing, sry to lazy to fix that fix now
ZZMoove Governor 0.7b
(compatibility improved and forgotten things)
Changelog:
- fixed stuck at max scaling frequency when using stock kernel sources with unmodified cpufreq driver and without any oc capabilities.
- readded forgotten frequency search optimisation in scaling logic (only effective when using governor soft frequency limit)
- readded forgotten minor optimisation in dbs_check_cpu function.
- as forgotten to switch in last version Legacy Mode now again disabled by default
- minor code format and comment fixes
ZZMoove Governor 0.7c
(again compatibility and optimisations)
Changelog:
- frequency search optimisation now fully compatible with ascending ordered system frequency tables (thx to @psndna88 for testing!)
- again minor optimisations at multiple points in dbs_check_cpu function
- code cleaning - removed some unnecessary things and whitespaces nuked - sry for the bigger diff but from now on it will be clean!
- corrected changelog for previous version regarding limits
ZZMoove Governor 0.7d (bugfix!)
(broken things)
Changelog:
- fixed hotplug up threshold tuneables to be able again to disable cores manually via sysfs by setting them to 0
- fixed the problem caused by a "wrong" tuneable apply order of non sticking values in hotplug down threshold tuneables when
hotplug up values are lower than down values during apply.
NOTE: due to this change right after start of the governor the full validation of given values to these tuneables is disabled till
all the tuneables were set for the first time. so if you set them for example with an init.d script or let them set automatically
with any tuning app be aware that there are illogical value combinations possible then which might not work properly!
simply be sure that all up values are higher than the down values and vice versa. after first set full validation checks are enabled
again and setting of values manually will be checked again.
- fixed a typo in hotplug threshold tuneable macros (would have been only a issue in 8-core mode)
- fixed unwanted disabling of cores when setting hotplug threshold tuneables to lowest or highest possible value
which would be a load of 100%/11% in up/down_hotplug_threshold and/or scaling frequency min/max in up/down_hotplug_threshold_freq
Click to expand...
Click to collapse
Thanks for great inputs
Hi!
Where I can read is responsible for what in one way or another option?
Now I'm interested in the inputboost options.
What's the difference between inputboost_cycles and inputboost_punch_cycles?
What give these options: inputboost_punch_epenmove and inputboost_punch_fingermove?
Forgive me if I ask stupid questions))
Thanks!
ilfat12 said:
Hi!
Where I can read is responsible for what in one way or another option?
Now I'm interested in the inputboost options.
What's the difference between inputboost_cycles and inputboost_punch_cycles?
What give these options: inputboost_punch_epenmove and inputboost_punch_fingermove?
Forgive me if I ask stupid questions))
Thanks!
Click to expand...
Click to collapse
hi ilfat12,
you can get more infos about the new features here : https://github.com/zanezam/cpufreq-governor-zzmoove/commit/75c431aeff8354f224e4c688faa1559ac463ab8a
and especially for the info u are searching i want to quote ffolkes description from here http://www.plasmakernel.com/?p=214:
Added native input booster to ZZMoove (based on faux123′s intelliactive)
I’ve added my own port of the native input booster from intelliactive into ZZMoove. Input events such as buttons, touchkeys, and the touchscreen will temporarily modify different ZZMoove settings. Using this allows for extremely conservative governor settings to be used without affecting performance. The boost is made up of two stages; the first is meant to be a very short high speed burst, just a few hundred milliseconds. The second stage is a reduced up threshold that is applied for the duration of the entire boost.
Click to expand...
Click to collapse
in short this means: inputboost_cycles = main switch = duration of whole input boost
inputboost_punch_cycles = duration of the freq "punch" therefore the freq boost duration
inputboost_punch_epenmove and inputboost_punch_fingermove are addons to this functionality
and are influencing the boost of the freq in following way: if one of these tuneables are set then
either on epen move (for devices with epen) or on finger move the punch will be reinitialized constantly
without expiring so actually its behaving like the regular system touch booster which has every device in some
way implemented. so that mode is kind of redundant if u use the system touch booster in addition, exception would be
if u want to overwrite the system booster with the governor boost. if i use it i usually like to use the native booster with
fingerdown enabled thats a good compromise i think.
hope it's somehow more understandable now for u
and hey never be sorry to ask, there are no stupid questions only stupid people who don't ask
Deep Sleep
How do I enable deep sleep mode at zzmove? Because mine is not working
Henriquefeira said:
How do I enable deep sleep mode at zzmove? Because mine is not working
Click to expand...
Click to collapse
you mean the governor "sleep" settings? it depends on the used kernel and how it has implemented zzmoove. they can be switched off by intention in the source code or are disabled automatically because no power management implementation or display state detection is used in the kernel.
but if u mean that u have wake locks and your device doesn't deep sleep then you have another problem which is not related to kernel/governors
in that case u can check what service/app is keeping your device awake with better battery stats for example to find the root cause.
Default profile Set.
Is this possible to make make yang battery extreme (3) profile set by default.....? Every time i set this but changed automatically zzrelax(11).....After unlock my phone....!
Hi ZaneZam. I use your Governor with Boeffla Kernel Beta on my S5.
I use the optimized profile with following additional tunables:
Fast Scaling Sleep Up: 5
Fast Scaling Sleep Down: 5
Fast Scaling Up: 5
Fast Scaling Down: 5
Sampling Rate Sleep Multiplier: 2
I use apps like Facebook or Chrome and than the phone freezes and reboots. This happened 2 times every day.
I checked the Insane profile and that's very similar to the optimized with my tunables. Why it doesn't work?
tuhinxp04 said:
Is this possible to make make yang battery extreme (3) profile set by default.....? Every time i set this but changed automatically zzrelax(11).....After unlock my phone....!
Click to expand...
Click to collapse
Yes it is possible either via a default value in the governor itself or maybe via the tool u use to switch it which u didn't reveal to us
i just can say that there is nothing included from my side which changes a profile "at sleep" so it must be something which is dealing with the tuneables automatically. I can imagine some kind of "at sleep changing settings" mode.
Solvin said:
Hi ZaneZam. I use your Governor with Boeffla Kernel Beta on my S5.
I use the optimized profile with following additional tunables:
Fast Scaling Sleep Up: 5
Fast Scaling Sleep Down: 5
Fast Scaling Up: 5
Fast Scaling Down: 5
Sampling Rate Sleep Multiplier: 2
I use apps like Facebook or Chrome and than the phone freezes and reboots. This happened 2 times every day.
I checked the Insane profile and that's very similar to the optimized with my tunables. Why it doesn't work?
Click to expand...
Click to collapse
hm I don't have to ask if u are using uv/oc, don't I? maybe any chance of a crash log? the S5 seems still disliking zzmoove in some situations.
ZaneZam said:
Yes it is possible either via a default value in the governor itself or maybe via the tool u use to switch it which u didn't reveal to us
i just can say that there is nothing included from my side which changes a profile "at sleep" so it must be something which is dealing with the tuneables automatically. I can imagine some kind of "at sleep changing settings" mode.
hm I don't have to ask if u are using uv/oc, don't I? maybe any chance of a crash log? the S5 seems still disliking zzmoove in some situations.
Click to expand...
Click to collapse
I don't use UV, only OC but without OC it's the same. How can I create a crashlog?
Solvin said:
I don't use UV, only OC but without OC it's the same. How can I create a crashlog?
Click to expand...
Click to collapse
good at least no uv in case of boeffla kernel its quite easy to create a crash log: just let the crash happen with kernel logger enabled (don't forget to enable it beforehand in config app!) then after system is up again right after the crash-reboot. go to action menu->create debug file. this file will be created in boeffla-data folder on your sdcard and is called "debug-date-time.txt" (the coming popup shows it more exactly) send this file to [email protected] then i can see what happend - hopefully, as the S5 crash logs are almost never much meaningful. but maybe u can give me the crucial hint with this log, lets see. the "good thing" for me is that u can reproduce it! thx in advance...
OK I will do that and send it to you. Thank you!
Currently no reboots or freezes. I think that was the problem:
http://forum.cyanogenmod.org/topic/114602-random-reboots/#entry534858
Today I got a Greenify update from playstore with that changes.
I hope that solved my problem.
And it crashed again (reboot). I send you the crashlog via mail
Solvin said:
And it crashed again (reboot). I send you the crashlog via mail
Click to expand...
Click to collapse
thx for the log, it rebooted yes but it didn't crash (at least the kernel did not!)
so in short: the log is clean, no kernel problem in my opinion but one thing: you have UV set to "custom" in boeffla config which means "the setting for custom values"
and which could still contain values u have changed previously (or have changed by a settings preset)! if u really want stock settings then choose "no undervolting"!
Lord boeffla recently changed the naming from "none" to "custom" upon the advice of me because i had one user which had a similar problem like u (i ask about uv because
of a reason, it's "smelling like that" *g*) and this user had previously tested values still active because he thought "none" is "off" so try to choose "no undervolting" then
u really have no uv values set.
hope this stabilizes things for u. otherwise feel free to get back with another log
:fingers-crossed:
ZaneZam said:
thx for the log, it rebooted yes but it didn't crash (at least the kernel did not!)
so in short: the log is clean, no kernel problem in my opinion but one thing: you have UV set to "custom" in boeffla config which means "the setting for custom values"
and which could still contain values u have changed previously (or have changed by a settings preset)! if u really want stock settings then choose "no undervolting"!
Lord boeffla recently changed the naming from "none" to "custom" upon the advice of me because i had one user which had a similar problem like u (i ask about uv because
of a reason, it's "smelling like that" *g*) and this user had previously tested values still active because he thought "none" is "off" so try to choose "no undervolting" then
u really have no uv values set.
hope this stabilizes things for u. otherwise feel free to get back with another log
:fingers-crossed:
Click to expand...
Click to collapse
Damn! I thought it was off, but you are right, my device was UV. But that was a stock setting from the kernel. I hope that was the Problem. Thank you very much ZaneZam.
Samsung Galaxy S5 - G900F
ROM: CM12.1 Nightly
Kernel: Boeffla 2.2-beta2
CP/BL: G900FXXU1BOH4
Recovery: TWRP 2.8.7.0
Can I get some help with my LG G3 zzmove profile 2 /5 settings? It runs good with the default settings, but I'd like to get some more performance and speed and get rid of the lag I have. SlimSaber 5.1.1 Nebula 12.0 using Kernel Adiutor
Someone explain about profile? i read it many time but dont understand it.
thaibinh262 said:
Someone explain about profile? i read it many time but dont understand it.
Click to expand...
Click to collapse
profiles are just predefined settings but included in the governor itself and switchable via a tuneable.
nytebird said:
Can I get some help with my LG G3 zzmove profile 2 /5 settings? It runs good with the default settings, but I'd like to get some more performance and speed and get rid of the lag I have. SlimSaber 5.1.1 Nebula 12.0 using Kernel Adiutor
Click to expand...
Click to collapse
still relevant? . sry completely missed that I would suggest to try all other settings then and see... if none of them suits u u anyway have to adjust the tuneables in particular to. make things better.. nut this is a huge topic then.
music_state
What does music_state tuneable do?

kernel adiutor settings for MI5

i have tried many kernel...from them...dragon xia and xceed works the best...
the thing is i am a moderate use guy...just anime episodes ...songs...web surfing and lots of calls...
i main aim is to get better battery life....performance doesnt matter to me much...as long as its stable...
from my experience xceed gives better battery life then dragon xia...but since i am new to these kind of stuff....
i would really love to have knowledge from you guys...
i would love to see if someone can provide me with the adiutor settings they have used...
currently i am on resurrection remix rom 5.8.4 (mi5 standard)
i really want a better battery life from my device
Like how much battery life you are getting? SOT as well as overall usage + SOT.. try my setup on dragonxia.. I don't use it now though..
*CPU 3 &4
Min - 307
Max - 1401
Gov - interactive
*CPU 1 & 2
Min - 307
Max - 1036
Gov - interactive
*Input boost freq core 1 - 556
*Input boost freq core 2 - disabled
*Input boost freq core 3 - 729
*Input boost freq core 4 - disabled
*Touch boost - disabled
*Set GPU at max
*Turn on backlight dimmer
*I/O sched - bfq
*Swap - 100
With daily usage on this, I can say that there's no performance decrease..it actually performs well and battery life is pretty awesome..
Tip: you can personally tweak the kernel depending on your usage..rule of thumb, CPU 3 & 4 (cores with lower clock speed) is the main driver over all..means CPU interaction triggers from here most of the time..and CPU 1 & 2 (higher clock speed) will work if you're doing extensive task like gaming..
viking_kong16 said:
Like how much battery life you are getting? SOT as well as overall usage + SOT.. try my setup on dragonxia.. I don't use it now though..
*CPU 3 &4
Min - 307
Max - 1401
Gov - interactive
*CPU 1 & 2
Min - 307
Max - 1036
Gov - interactive
*Input boost freq core 1 - 556
*Input boost freq core 2 - disabled
*Input boost freq core 3 - 729
*Input boost freq core 4 - disabled
*Touch boost - disabled
*Set GPU at max
*Turn on backlight dimmer
*I/O sched - bfq
*Swap - 100
With daily usage on this, I can say that there's no performance decrease..it actually performs well and battery life is pretty awesome..
Tip: you can personally tweak the kernel depending on your usage..rule of thumb, CPU 3 & 4 (cores with lower clock speed) is the main driver over all..means CPU interaction triggers from here most of the time..and CPU 1 & 2 (higher clock speed) will work if you're doing extensive task like gaming..
Click to expand...
Click to collapse
What does swappiness do actually?
Sent from my MI 5 using Tapatalk
cheaterfruity said:
What does swappiness do actually?
Click to expand...
Click to collapse
Speed up read and write speed of the zram which is enabled by default in our RAM.. which means snappy switching of apps..
viking_kong16 said:
Speed up read and write speed of the zram which is enabled by default in our RAM.. which means snappy switching of apps..
Click to expand...
Click to collapse
Consumes more battery?
Sent from my MI 5 using Tapatalk
cheaterfruity said:
Consumes more battery?
Click to expand...
Click to collapse
Nope.. our phone is using zram as swap..not internal storage.. zram is actually a compressed RAM that sits within RAM itself.. try to google it..

Tasker CPU frequency set does not work correctly

Hi
I am trying to control my CPU governor and Frequency through Tasker, and it also works to some degree, the governor works and frequency control on 4 cores works.
However I have a Sony Xperia Z5 with Linage OS custom ROM running. I can through the Action in Tasker get the frequencies for CPU 0 - 3, but not for 4 - 7. What I know ( I could be mistaken) is that the first 4 cores are low power cores and the other 4 are high performance/ power cores.
There is a file for all the cores where you can see the frequency stepping and I've check and this file is there for the first 4 cores and correctly indicates the stepping from 384MHz to 1550MHz.
However for core 4 to 7 only core 5 have a stepping file which also correctly shows the stepping for the high performance cores which is 384Mhz to 1960Mhz.
The Action in Tasker does as mentioned above only set the frequency control for the first 4 cores. not the last 4 cores. How do I fix this. ? I was thinking that i could copy the cpufreq folder from CPU 5 to the other 3 "CPU's" (4,6,7). However The Tasker Action still cannot find the correct stepping for Core 5 even though the stepping file is available.
I'm not sure the above makes sense, so please ask for clarification. Hope anyone have an input for this problem because i cannot be the only one.
Regards

Categories

Resources