[Q] HD2 Undervolting - HD2 Android Q&A, Help & Troubleshooting and Genera

Hello everyone!
Does anyone knows if it exists a "tool" for undervolting or also if exist some vCore table that is working good giving a boost to the battery life?
It would be nice if someone posts some guide about
Thanks everyone

mrbr0wn said:
Hello everyone!
Does anyone knows if it exists a "tool" for undervolting or also if exist some vCore table that is working good giving a boost to the battery life?
It would be nice if someone posts some guide about
Thanks everyone
Click to expand...
Click to collapse
Of course there is a way
You can use SetCPU (paid app) or CPU Master (free ,search xda) and some more apps.
You can select the govenor of the kernel (smartass etc. ) and overvolt/overclock and undervolt your CPU if you have a kernel like tytung etc.
Battery boosting:
I just use smartass governor and undervolt a little bit ,which saves much energy.
#
Hope this is what you needed to know.

Uh?It sounds new to me! Really i can use SetCPU to undervolt? O.O

Yes.
If you set max frequenz to 800mhz, Kernel will just get up to that speed..
Sent from my HTC HD2 using XDA Premium App

...nope...i was talkin' about *undervolting*, not *underCLOCKING*...

mrbr0wn said:
...nope...i was talkin' about *undervolting*, not *underCLOCKING*...
Click to expand...
Click to collapse
Oh sry.
Was thinking you meant this.
Since I dont use this I cant help youy
Sent from my HTC HD2 using xda premium

No problem
Hope someone else can help me or suggest me the right way!

some builds are capable of being undervolted right from the start using a txt config file. I think DL desire has that.
Raf's new kernel also supports undervolting if I'm not wrong, but you have to do it manually. some CM7 roms can be undervolted manually as well.
I've never heard of an app that helps you do that, and I don't think one will be released soon with google trying to lock up every thing on android that more and more devices become unable to be rooted.

On Typhoon Cyanogen mod, I just edit the /system/etc/init.d/98cpuvoltage to my proven settings, and then flash the rom. According to Tyween, it's best to have 1 proven undervolt settings, and some extra for testing, so you won't make your phone un-usable.
To open a file, use Gscript lite, or terminal emulator, and type:
Sh /filepath/filename
Use a linux compatible text editor, like notepad++ to edit the settings.
My settings are this, but they might not work on your cpu.
Code:
#!/system/bin/sh
# set vdd_levels on boot by dorimanx (XDA Developers)
echo '245000 850' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '384000 875' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '422400 900' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '460800 925' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '499200 950' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '537600 950' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '576000 1000' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '614400 1025' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '652800 1050' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '691200 1075' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '729600 1100' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '768000 1100' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '806400 1125' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '844800 1150' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '883200 1150' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '921600 1175' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '960000 1175' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '998400 1200' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '1036800 1200' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '1075200 1225' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '1113600 1250' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '1152000 1250' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
echo '1190400 1275' > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels

thanks everybody for the replies, i started to "study" the question before to see your msgs, i found the file in /etc/init.d/ and started to lower the vCores... the thing that really sounds strange to me is that i've taken another file from a forum (that should be already undervolted, even if only a bit), lowered again in the middle range freqs (like from 499200 to 1036800), stressed cpu, and never had a restart/freeze...it seems to me a little strange....it could means 3 things:
1- i'm not really changing the voltages (even if i can see my settings in /sys/devices/system..ecc)
2 - by default, the cpu works with too high voltages
3 - i own a VVEEEEEEERRRY lucky hd2 that can handle undervolting very well
(3bis - the program that i'm using to stress the cpu isn't working XD) [checked with top/htop, cpu load goes to 100% and stay here during the stress test, so it should be working good ]
does anyone knows a way to see the "live" cpu voltage as it happens with the clock? i mean, a way to see the cpu voltage in real time!
thanks

Maybe this is what your are looking for:
http://forum.xda-developers.com/showthread.php?t=1223639
Sent from my HTC HD2 using xda premium

just to update the post...
made some experiments....
245000: 850
384000: 850
422400: 875
460800: 875
499200: 875
537600: 900
576000: 950
614400: 975
652800: 975
691200: 1025
729600: 1025
768000: 1050
806400: 1075
844800: 1075
883200: 1100
921600: 1125
960000: 1150
998400: 1150
1036800: 1175
1075200: 1175
1113600: 1175
1152000: 1200
1190400: 1225
that seems to be the best vdd table that i can use...max undervolting, no strange reboot or similar...i have some random FC atm, but i'm not really shure that undervolting is causing this! i'll take a look and eventually, update again the post

Related

favorite/best SIMPLE compcache and linux-swap scripts?

I've been playing a little bit with Compcache and Linux-swap on the latest Cyanogen ROMs, but it seems like there are so many variations of these scripts out there that I don't know 100% that the performance I'm seeing is because of the swap method used (compcache, compcache with backing swap or pure Linux-swap) or the particularities of the script. I'd like to set up some Gscripts with the SIMPLEST Compcache, Compcache with backing swap and pure Linux-swap scripts so that I can reboot with no userinit.sh, run a Gscript and see how the phone performs and get an idea of how they each perform with various settings (size and swappiness).
You'll notice that this is NOT posted in the development section, so feel free to explain to me what any scripts you want to share do or don't do. I'm sure others will benefit as well.
Thanks!
not one? (here's what I'm playing with now)
Ok, here is what I am playing with now:
(Generl stuff/mods, mostly commented out.)
Code:
#!/system/bin/sh
uname_r=`uname -r`
moddir=`find /system/modules -type d -name $uname_r`
insmod=/system/bin/insmod
$insmod $moddir/compcache/xvmalloc.ko;
$insmod $moddir/compcache/ramzswap.ko #disksize_kb=32000;
#$insmod $moddir/compcache/ramzswap.ko backing_swap=/dev/block/mmcblk0p3 memlimit_kb=32000;
mknod /dev/ramzswap0 b 253 0;
echo 20 > /proc/sys/vm/swappiness;
#echo 1 > /proc/sys/vm/page-cluster; # default: 3 Changes Page clustering from 8 to 2.
#echo 5 > /proc/sys/vm/laptop_mode; # default: 0 Helps keep SSD from getting worn.
#echo 5000 > /proc/sys/vm/dirty_expire_centisecs; # default: 3000
#echo 800 > /proc/sys/vm/dirty_writeback_centisecs; # default: 500
#echo 10 > /proc/sys/vm/dirty_background_ratio; # default: 5
#echo 16 > /proc/sys/vm/dirty_ratio; # default: 10
echo 2000000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate
swapon /dev/ramzswap0;
#swapon /dev/block/mmcblk0p3;
#echo 200 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/powersave_bias;
#echo 128000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq;
#echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq;
Note: I believe these are correct for recent CM builds with a Linux-swap partition. If you are using anything else, do some research first.
Did you get any testing done on this?
Am interested as well.
(+ If you' re at it test a swap files instead of a swap partition as well, it shouldn't make any difference, see http://forum.xda-developers.com/showthread.php?p=4136554#post4136554)
I played with a variety of different setting with decent results
I wouldn't say that I "tested" any specific settings combinations exactly, but like many I found that Linux-swap set to a relatively low swappiness (20-30) gave me better results than compcache, but that was before switching to the latest Cyanogen ROMs with the tweaked kernel to better use compcache (SWAP_FREE_NOTIFY patch) AND compcache enabled by default. Since then I've mostly been using the ROMs without any userinit because the performance is so good already.
I keep meaning to find a copy of the settings used by miketaylor00 because he seems to think they're quite good (when someone says swappiness 28 works much better than swappiness 30, it makes me think he's tested pretty extensively ), but laziness or apathy has stymied my attempts thus far.
**EDIT**
nm, found infoz already.

Fix for lowered max CPU rate in media players

I was playing around with adjusting and monitoring the CPU rate on my A43, and I discovered an oddity. I have the device set to overdrive, so normally it can do 1ghz. But I noticed that inside Netflix's video player (not just the Netflix app, the video player), the CPU speed was only 800mhz and there was some stuttering. Looking more carefully, I noticed that somehow as soon as the video player started up, the maximum scaling frequency went down to 800mhz. Exit, and it goes back to 1ghz. I then found that the same happens in Youtube and the Archos Video player.
How annoying, though maybe there is some good reason for it? Is it perhaps that the video hardware can't handle the greater speed? Does anybody know?
Anyway, I have a simple fix: You just have to turn off the write permissions on /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq after the values have been all set. I don't know if any of the CPU speed utilities like SetCPU let you do this.
I fix this by setting my CPU speed settings via a script that runs on boot. (I run it via a tiny utility I wrote which I am not presently releasing, but you could also run it via Script Manager.) The script I use is:
Code:
cd /sys/devices/system/cpu/cpu0/cpufreq
echo conservative > scaling_governor
chmod 644 scaling_max_freq
echo 1000000 > scaling_max_freq
chmod 444 scaling_max_freq
echo 300000 > scaling_min_freq
echo 150000 > conservative/sampling_rate
echo 70 > conservative/up_threshold
The crucial line is the "chmod 444 scaling_max_freq" which sets the scaling_max_freq file to read-only. (Of course, a determined app that wants to change it can just chmod 644 scaling_max_freq and write to it. But whatever is doing the switch 800mhz isn't THAT determined.)
The result is that Star Trek plays smoothly at 1ghz in Netflix, as it should, while the built-in video player when playing lower-resolution videos uses 800mhz, as it also should.
If you have a device with a higher top speed than 1000000, just change the 1000000 to whatever your top speed is.
If you want to check if your device has the issue, start up a video, and then while the video is playing, do:
Code:
adb shell cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
If it's less than the top speed of your device, you have the issue.
But maybe it's supposed to be like that?
arpruss said:
The script I use is:
Code:
cd /sys/devices/system/cpu/cpu0/cpufreq
echo conservative > scaling_governor
chmod 644 scaling_max_freq
echo 1000000 > scaling_max_freq
chmod 444 scaling_max_freq
echo 300000 > scaling_min_freq
echo 150000 > conservative/sampling_rate
echo 70 > conservative/up_threshold
Click to expand...
Click to collapse
Would I run this script verbatim for interactive mode? Or change 'conservative' in the script to 'interactive'?
EDIT I think I get it...... gonna play for a bit....
I think the stock ROM only supports ondemand, conservative and performance.
arpruss said:
I think the stock ROM only supports ondemand, conservative and performance.
Click to expand...
Click to collapse
I'm on Uruk 1.0, err, well both, but I dominantly run on Uruk
wokker666 said:
I'm on Uruk 1.0, err, well both, but I dominantly run on Uruk
Click to expand...
Click to collapse
I see. Then, yes, you do need to change things to set up whatever settings you want for interactive. Are you using any CPU-setting utility? I don't know how well my script will work with a CPU-setting utility. The one I tried automatically set read/write permissions to the files, which undoes the effects of my script.
I think I got it
I can confirm that SetCPU does reset the permissions, killing SU permissions to the app seems to fix that
I remade the script to go a little something like...
Code:
cd /sys/devices/system/cpu/cpu0/cpufreq
echo interactive > scaling_governor
chmod 644 scaling_max_freq
echo 1000000 > scaling_max_freq
chmod 444 scaling_max_freq
chmod 644 scaling_min_freq
echo 600000 > scaling_min_freq
chmod 444 scaling_min_freq
The scaling_min_freq part may seem useless, but it further sets what you want in stone
So far after a few reboots, everything seems to be working just fine, and the system dosen't scale the cpu to 800000 when in video!
Nice!
Thanks!
Any idea WHY Archos did that 800mhz scaling?
Maybe it's just a bug. I think they initially wanted the device to run at 800MHz, and then later added an Overdrive mode at 1000. So the 800 could be a leftover, no?
arpruss said:
Any idea WHY Archos did that 800mhz scaling?
Maybe it's just a bug. I think they initially wanted the device to run at 800MHz, and then later added an Overdrive mode at 1000. So the 800 could be a leftover, no?
Click to expand...
Click to collapse
I think they did it to help conserve the battery, if you use your unit for mostly video, it would make sense to not burn through your battery at 1ghz...
On that note, my system with the settings I just made, in video it REALLY scales to my settings.... it dominantly runs at 600mhz, not 1ghz - maybe it's the interactive mode kicking in, it just dosent see the demand - I can't test in real time right now though, no linux machine as of yet, but time in state shows mostly 600mhz, and some 1ghz
wokker666 said:
I think they did it to help conserve the battery, if you use your unit for mostly video, it would make sense to not burn through your battery at 1ghz...
Click to expand...
Click to collapse
But that's what the scaling is for. When the video doesn't need the higher speed, it scales it down, and when it needs it, it scales it up. Star Trek on Netflix needs 1000, while different xvid videos that I have need different speeds.
By the way, I noticed that they also set scaling_min_freq to 800 in the video player. So, my script also needs a line:
Code:
chmod 444 scaling_min_freq
at the end.
arpruss said:
But that's what the scaling is for. When the video doesn't need the higher speed, it scales it down, and when it needs it, it scales it up. Star Trek on Netflix needs 1000, while different xvid videos that I have need different speeds.
Click to expand...
Click to collapse
Most of what I was testing are .mkv's of all sorts of flavors, they probably dont need to bump up the speed - I should find a hd vid to test with.
By the way, I noticed that they also set scaling_min_freq to 800 in the video player. So, my script also needs a line:
Code:
chmod 444 scaling_min_freq
at the end.
Click to expand...
Click to collapse
I knew I threw that in for a reason
It looks like the writing of the modified frequencies is done by /system/bin/powerd, and it's requested by /usr/bin/avos when the DSP is called for.
arpruss said:
It looks like the writing of the modified frequencies is done by /system/bin/powerd, and it's requested by /usr/bin/avos when the DSP is called for.
Click to expand...
Click to collapse
I wonder if this is something that can be manually changed, or maybe Sauron take a look at it and implement the changes in the next Uruk?
On another note, I gotta say, after locking down my cpu with this script, plus a few other settings in an app I have (autokiller memory optimizer), my system has never run better, very snappy!!!

[DISCUSSION] RAM and services, sluggishness and slowness

Since our phone has little ram and many apps like running services we probably don't need in the background (youtube, google search, K9 mail/gmail for those of us checking emails manually), is there any way to optimize our phones by limiting the apps when it comes to services? I mean, is there any way to not let an app run a background service?
I tried freezing app autostarts with Autostarts, but I couldn't do it for some apps. I am also using FastReboot but I feel that it is only a workaround.
I keep feeling that my phone runs faster when it has 60+ free mb of RAM, but this is hard to accomplish. What do you guys think?
By the way, I also felt that Juwe RAM Script and the Sysctl config posted in the script's thread didn't do anything to my RAM.
--
Update @ Aug/21:
There's a script that works in all cellphones the same and it was created by zeppelinrox. Read about it here: http://forum.xda-developers.com/showthread.php?t=991276
For some reason, settings don't stick after reboot for us no matter what we do. This has been confirmed to happen in GingerDX and in MiniCM (confirmed by me) on CM7. We still don't know why
Alternatively, some users have suggested introducing the script in build.prop (read bellow). In my case, even without the values not sticking, my phone is smoother. You can try the following at your own risk:
This is some info that Pjay12 gathered from other posts:
Pjay12 said:
Here goes -
Credits to Zeppelinrox and alfsamsung
I tried to make this as noob-friendly as possible.
First steps - Run the script and reboot once (just in case) It will create a 99SuperCharger in init.d, deleting this is not necessary.
Uninstall/freeze AMM, AKMO, Minfree Manager, whatever else you have that can alter Minfree values.
This may differ with each rom but delete any other ramscript from etc/init.d
[On a standard GingerDX these are the files that should be in init.d
01sysctl
03firstboot
04modules
05mountsd
06gingerdx
06mountdl
10apps2sd
20userinit
99SuperCharger <-- after running the SuperCharger Script]
Changes -
1. system/etc/hw_config :
Add these lines to the bottom
# tweak launcher hard to kill from supercharger
echo "0,3,5,7,14,15" > /sys/module/lowmemorykiller/parameters/adj
echo "1536,2048,6656,7168,7680,8192" > /sys/module/lowmemorykiller/parameters/minfree
echo "0" > /proc/sys/kernel/panic
echo "0" > /proc/sys/vm/oom_kill_allocating_task
echo "0" > /proc/sys/vm/panic_on_oom
echo "1" > /proc/sys/kernel/panic_on_oops
echo "0" > /proc/sys/kernel/panic
The values in bold are my settings (Balanced 3 option in supercharger)
Values you will see are 6 ,8 ,26 ,28 ,30 ,32.
Change them to your desired values.
[Additional (how it works) - <value> * 4 / 1024 (<value/256)
Example - 1536/256 = 6, 8192*4/1024 = 32]
2. data/local.prop :
Make sure it looks like this-
ro.FOREGROUND_APP_ADJ=0
ro.VISIBLE_APP_ADJ=3
ro.PERCEPTIBLE_APP_ADJ=2
ro.HEAVY_WEIGHT_APP_ADJ=4
ro.SECONDARY_SERVER_ADJ=5
ro.BACKUP_APP_ADJ=6
ro.HOME_APP_ADJ=2
ro.HIDDEN_APP_MIN_ADJ=7
ro.EMPTY_APP_ADJ=15
ro.FOREGROUND_APP_MEM=1536
ro.VISIBLE_APP_MEM=2048
ro.PERCEPTIBLE_APP_MEM=1024
ro.HEAVY_WEIGHT_APP_MEM=6656
ro.SECONDARY_SERVER_MEM=6656
ro.BACKUP_APP_MEM=7168
ro.HOME_APP_MEM=1024
ro.HIDDEN_APP_MEM=7168
ro.EMPTY_APP_MEM=8192
Now reboot and check sys/module/lowmemorykiller/parameters/minfree (long press and select view as text) Your values should be what you put as the bold text in hw_config.
Click to expand...
Click to collapse
Pjay12 said:
--------------------------------------------------------------------------------------------------------------
OPTIONAL -
The following may or may not affect your phones performance. DO NOT rely on quadrants or any other benchmarks for performance. Its your own experience.
1. hw_config
Add these lines-
# we love fast sd speed
echo 512 > /sys/devices/virtual/bdi/179:0/read_ahead_kb
# sysctl and ram tweak
echo "0" > /proc/sys/vm/swappiness
echo "2000" > /proc/sys/vm/dirty_writeback_centisecs
echo "1000" > /proc/sys/vm/dirty_expire_centisecs
echo "200" > /proc/sys/vm/vfs_cache_pressure
echo "80" > /proc/sys/vm/dirty_ratio
echo "40" > /proc/sys/vm/dirty_background_ratio
echo "0" > /proc/sys/vm/oom_kill_allocating_task
echo "2048" > /proc/sys/vm/min_free_kbytes
NOTE -
The above lines under "#sysctl and ram tweak" are alfsamsung's original tweaks.
If you haven't flashed kickasskernel, the below lines are editted with a few kickasskernels values (its what I use) If you want to try it, REPLACE the above lines under #sysctl and ram tweak with the lines below.
# sysctl and ram tweak
echo "0" > /proc/sys/vm/swappiness
echo "2000" > /proc/sys/vm/dirty_writeback_centisecs
echo "1000" > /proc/sys/vm/dirty_expire_centisecs
echo "20" > /proc/sys/vm/vfs_cache_pressure
echo "95" > /proc/sys/vm/dirty_ratio
echo "60" > /proc/sys/vm/dirty_background_ratio
echo "0" > /proc/sys/vm/oom_kill_allocating_task
echo "8192" > /proc/sys/vm/min_free_kbytes
2. system/build.prop
Add these lines to the bottom #wifi network etc..
rild.libpath=/system/lib/libril-qc-1.so
rild.libargs=-d
/dev/smd0
ro.ril.hsxpa=2
ro.ril.hsupa.category=5
ro.ril.enable.a52=1
ro.ril.enable.a53=1
ro.ril.def.agps.mode=2
ro.ril.gprsclass=12
ro.ril.def.agps.mode=2
ro.telephony.default_network=0
wifi.interface=wlan0
wifi.supplicant_scan_interval=90
#windows management
ro.sf.lcd_density=160
windowsmgr.max_events_per_sec=60
settings.display.autobacklight=1
settings.display.brightness=160
# The OpenGL ES API level that is natively supported by this device.
ro.opengles.version=131072
debug.sf.hw=1
# Tweaks
debug.sf.hw=1
ro.compcache.default=0
#media
ro.workaround.noautofocus=1
media.stagefright.enable-player=true
media.stagefright.enable-meta=true
media.stagefright.enable-scan=true
media.stagefright.enable-http=true
ro.media.dec.jpeg.memcap=10000000
ro.media.enc.file.format = 3gp,mp4
ro.media.enc.vid.codec = m4v,h263
ro.media.enc.vid.h263.width = 176,352
ro.media.enc.vid.h263.height = 144,288
ro.media.enc.vid.h263.bps = 64000,800000
ro.media.enc.vid.h263.fps = 1,30
ro.media.enc.vid.m4v.width = 176,352
ro.media.enc.vid.m4v.height = 144,288
ro.media.enc.vid.m4v.bps = 64000,800000
ro.media.enc.vid.m4v.fps = 1,30
# For SD storage insert notification sound
persist.service.mount.playsnd = 0
#dalvik options (more tweaks)
dalvik.vm.execution-mode=int:jit
dalvik.vm.heapsize=40m
dalvik.vm.dexopt-flags=m=y
#Other tweaks
mot.proximity.delay=400
When editting build.prop, you may have to make changes to both system/build.prop AND system/bin/build.prop
alfsamsung said:
- mot.proximity.delay=400 - sets the delay of screen on when using proximity sensor in calls (mseconds)
Click to expand...
Click to collapse
The important lines above are in bold. Make sure they are the same.
Reboot and check sys/module/lowmemorykiller/parameters/minfree. Values should be the same. If they aren't, feel free to PM. Hope it helps.
If it helps hit thanks for the respective contributors.
Enjoy.
Cheers.
Pjay
Click to expand...
Click to collapse
Dexter_prog said:
Since our phone has little ram and many apps like running services we probably don't need in the background (youtube, google search, K9 mail/gmail for those of us checking emails manually), is there any way to optimize our phones by limiting the apps when it comes to services? I mean, is there any way to not let an app run a background service?
I tried freezing app autostarts with Autostarts, but I couldn't do it for some apps. I am also using FastReboot but I feel that it is only a workaround.
I keep feeling that my phone runs faster when it has 60+ free mb of RAM, but this is hard to accomplish. What do you guys think?
By the way, I also felt that Juwe RAM Script and the Sysctl config posted in the script's thread didn't do anything to my RAM.
Click to expand...
Click to collapse
Same problem! Now I use Gingerdx 007 and i have the same problem i had with 006 and froyobread before that! My phone works like a charm, couldn`t be better! BUT....verry often it becomes so laggy and there is apsolutelly no way to fix it exept restart and it`s becoming really anoying. Sometimes i don`t use it for few hours and it simply "bricks" in my pocket! I can`t even answer if someone calls me. I know it has something to do with ram memory but nothing helps! Fast reboot makes it work for like 10 seconds and it`s stuck again. Advanced task killer kills apps in background and there they are again after couple of seconds. I`m not really sure that it will ever be fixed, whatever it is.
I dont have that problems, I reboot only when error comes up, or I battery drained.
Just uninstall those system apps..
Sent from my X8 using Tapatalk
woodpeckerlo said:
Same problem! Now I use Gingerdx 007 and i have the same problem i had with 006 and froyobread before that! My phone works like a charm, couldn`t be better! BUT....verry often it becomes so laggy and there is apsolutelly no way to fix it exept restart and it`s becoming really anoying. Sometimes i don`t use it for few hours and it simply "bricks" in my pocket! I can`t even answer if someone calls me. I know it has something to do with ram memory but nothing helps! Fast reboot makes it work for like 10 seconds and it`s stuck again. Advanced task killer kills apps in background and there they are again after couple of seconds. I`m not really sure that it will ever be fixed, whatever it is.
Click to expand...
Click to collapse
before gingerDx I was using Fast Reboot + automemory manager (set on aggressive or whatever the highest setting was) and it kind of did the trick. But it still seems that there's no way to beat a phone with low ram.
Just use Autokiller memory optimizer, and if you can, buy the donate version, so you can edit the upper settings. just set the 3 lower value to : 80,90,100
and if you have the donate version, just set the 3rd value to 60, and you'll have a fast system. but dont try to set the first and second value too high,
Dexter_prog said:
Since our phone has little ram and many apps like running services we probably don't need in the background (youtube, google search, K9 mail/gmail for those of us checking emails manually), is there any way to optimize our phones by limiting the apps when it comes to services? I mean, is there any way to not let an app run a background service?
I tried freezing app autostarts with Autostarts, but I couldn't do it for some apps. I am also using FastReboot but I feel that it is only a workaround.
I keep feeling that my phone runs faster when it has 60+ free mb of RAM, but this is hard to accomplish. What do you guys think?
By the way, I also felt that Juwe RAM Script and the Sysctl config posted in the script's thread didn't do anything to my RAM.
Click to expand...
Click to collapse
Juwe helps me. You have to put it in /etc/init.d and chmod 777 it. But i'm now using supercharger script, i think my phone is faster now.
Note: my signature has not been changed yet because i am now testing.
Try changing dirty ratio to 95 and dirty background ratio to 60 and vfs cache pressure to 10 and turn on OOM (not sure about this).
My minfrees are: 6,8,16,20,22,60
What's superchargerscript? Is it this one? http://forum.xda-developers.com/showthread.php?t=991276
I'm using the browser to browse Facebook and Twitter bcoz their app runs in background so I uninstalled them using Titanium Backup. And I have a little imprpvement.
Sent from my X8 using XDA App
The more the apps installed the more ram will be used. I dont know if it is possible to add ram but the only solution is to free some.
Dexter_prog said:
What's superchargerscript? Is it this one? http://forum.xda-developers.com/showthread.php?t=991276
Click to expand...
Click to collapse
Yeah. And i'm also using kernel tweaks by the same guy and turbo 3g. I'm testing them so quality assurance for x8 is not present yet.
@deedii in gdx my partition dont work it show memory card corrupted.........
i tried with cwc recovery to partition.....
can u help me??
#sorry for weak english
ithunter said:
@deedii in gdx my partition dont work it show memory card corrupted.........
i tried with cwc recovery to partition.....
can u help me??
#sorry for weak english
Click to expand...
Click to collapse
It should work as CWM partitions to ext 3. Set swap size to 0 and reboot your phone first to be sure that the sd card is really corrupted.
I partitioned with CWM and had no problems.
Only got lags when app needs more memory and system trying to kill background/stopped apps. That's really annoying, especially when IM gone sleep and was accidentally killed instead of some useless crap.
@ithunter oh im sorry sweetie but i dont use partition..
Using cwm partition ext sometime no work. i use minitool partition .
[email protected]
FroyoBread v024
|ax8smartass|x8mddi|x8gesture|
|x8uv|x8bootsound|Ext4|
|V6superchargerscript|Oc691mhz|
*Dont be shy ..if help click thank to me. 囧*
kakho55 said:
Using cwm partition ext sometime no work. i use minitool partition .
[email protected]
FroyoBread v024
|ax8smartass|x8mddi|x8gesture|
|x8uv|x8bootsound|Ext4|
|V6superchargerscript|Oc691mhz|
*Dont be shy ..if help click thank to me. 囧*
Click to expand...
Click to collapse
yes finally i use cwm partition with swip 0 size and it work better .... m happy
@deedii tyo to use it make little bit faster.....
actually i dont wanna tweak my phone a lot im satisfied with my settings right now.. thanks so much for the info btw
I heard bout this SuperCharger did someone already use this one? Hmm does it really boost our x8? hmm..
Here is the easiest way to install this script.
Install SuperCharger
btw how do you see version of busybox installed in your system? in gdx7? Sorry Im Noob.
deedii said:
I heard bout this SuperCharger did someone already use this one? Hmm does it really boost our x8? hmm..
Here is the easiest way to install this script.
Install SuperCharger
btw how do you see version of busybox installed in your system? in gdx7? Sorry Im Noob.
Click to expand...
Click to collapse
check with lsmod on terminal it may show... i am also noobs ^_^
deedii said:
I heard bout this SuperCharger did someone already use this one? Hmm does it really boost our x8? hmm..
Here is the easiest way to install this script.
Install SuperCharger
btw how do you see version of busybox installed in your system? in gdx7? Sorry Im Noob.
Click to expand...
Click to collapse
You can check busybox version by installing Busybox installer from the market

Power/performance kernel tuning and tweaks

As suggested in LineageOS thread the discussion on kernel tweaks forks here.
Let's continue!
The recent post:
Zola III said:
Well you can use different profiles in Kernel Auditor but forgot anything turbo especially in GPU intensive games where you actually need to save on CPU power consumption but CPU frequency must stay high enough to allow full speed RAM operations (as that's the way it goes with Snapdragon boards) so that you have better headroom for GPU & less throttling by thermal engine. Think 500MHz is a best achievable sustained frequency & even that is achieved only when CPU power usage is tuned on stock MiUI & otherwise I can get GPU to get throttled down to 450MHz in less than a 30 min. A one GHz for a CPU is really golden middle regarding performance/power consumption no matter what lithographic processes is used to make it, it's simply tied to silicone as essential material.
Click to expand...
Click to collapse
HELIUM, LOCKED bootloader, [ROM][UNOFFICIAL][7.1.1][HYDROGEN/HELIUM]LineageOS 14.1 r.03-27-2017 by*nijel8
This is my Init.d script I presently use, I've cumulated here your previous draft proposals and hints, please forgive me for its deficiencies and help to improve it:
Code:
#!/system/bin/sh
#
sleep 3;
################################# helper functions to allow Android init like script
function write() {
echo -n $2 > $1
}
function copy() {
cat $1 > $2
}
function get-set-forall() {
for f in $1 ; do
cat $f
write $f $2
done
}
################################
# Enable governor for LITTLE CPUs (perrf cluster):
write /sys/devices/system/cpu/cpu0/online 1
write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor "interactive"
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/above_hispeed_delay 40000
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/go_hispeed_load 96
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_rate 20000
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/hispeed_freq 1017600
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/io_is_busy 1
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads "80 400000:87 1017600:95 1190400:99"
#1305600
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/min_sample_time 20000
write /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq 400000
# Enable governor for Big CUSs (power cluster):
write /sys/devices/system/cpu/cpu4/online 1
write /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor "interactive"
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/above_hispeed_delay 40000
###interactive/above_hispeed_delay 40000
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/go_hispeed_load 96
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/timer_rate 20000
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/hispeed_freq 1017600
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/io_is_busy 1
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/target_loads "87 400000:90 1017600:95 1382400:99"
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/min_sample_time 20000
write /sys/devices/system/cpu/cpu4/cpufreq/scaling_min_freq 400000
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/max_freq_hysteresis 60000
# Configure core_ctl
write /sys/devices/system/cpu/cpu0/core_ctl/not_preferred "1 0 0 0"
write /sys/devices/system/cpu/cpu0/core_ctl/busy_up_thres 90
write /sys/devices/system/cpu/cpu0/core_ctl/busy_down_thres 80
write /sys/devices/system/cpu/cpu0/core_ctl/min_cpus 1
write /sys/devices/system/cpu/cpu0/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/not_preferred "1 0 0 0"
write /sys/devices/system/cpu/cpu4/core_ctl/min_cpus 1
write /sys/devices/system/cpu/cpu4/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/busy_up_thres 90
write /sys/devices/system/cpu/cpu4/core_ctl/busy_down_thres 80
write /sys/devices/system/cpu/cpu4/core_ctl/offline_delay_ms 200
write /sys/devices/system/cpu/cpu4/core_ctl/task_thres 4
write /sys/devices/system/cpu/cpu4/core_ctl/is_big_cluster 1
# set cpu_boost parameters
write /sys/module/cpu_boost/parameters/input_boost_freq "0:1190400 1:0 2:0 3:0 4:0 5:0 6:0 7:0"
write /sys/module/cpu_boost/parameters/input_boost_ms 200
write /proc/sys/kernel/sched_upmigrate_min_nice 15
# set (super) packing parameters
write /sys/devices/system/cpu/cpu0/sched_mostly_idle_freq 400000
write /sys/devices/system/cpu/cpu4/sched_mostly_idle_freq 400000
################################
# IO
echo 'deadline' > /sys/block/mmcblk0/queue/scheduler
# GPU
echo '133333333' > /sys/class/kgsl/kgsl-3d0/devfreq/min_freq
echo '20' > /sys/module/adreno_idler/parameters/adreno_idler_downdifferential
echo 'Y' > /sys/module/adreno_idler/parameters/adreno_idler_active
echo '550000000' > /sys/class/kgsl/kgsl-3d0/max_gpuclk
echo 'simple_ondemand' > /sys/class/kgsl/kgsl-3d0/devfreq/governor
echo '20' > /sys/module/adreno_idler/parameters/adreno_idler_idlewait
################################
Please forgive me its imperfection, treat it as a draft. Please review it. Thank you very much!
HELIUM, LOCKED bootloader, [ROM][UNOFFICIAL][7.1.1][HYDROGEN/HELIUM]LineageOS 14.1 r.03-27-2017 by*nijel8
Their isn't much to continue. Leaking is sustainable up to 1.4GHz (up to 1.6GHz on newer FinFET lithography). So the base & upper range that you don't want to go over for anything more than just burst start is pretty much same for all boards. I already described & wrote what should be done particularly for msm8956 & msm8976.
Script as it is so far; 2+2 core's
S652 octa core
Code:
#!/system/bin/sh
#
################################################################################
# helper functions to allow Android init like script
function write() {
echo -n $2 > $1
}
function copy() {
cat $1 > $2
}
function get-set-forall() {
for f in $1 ; do
cat $f
write $f $2
done
}
################################################################################
# Enable governor for LITTLE CPUs (perrf cluster)
write /sys/devices/system/cpu/cpu0/online 1
write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor "interactive"
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/above_hispeed_delay 40000
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/go_hispeed_load 90
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_rate 20000
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/hispeed_freq 1017600
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/io_is_busy 1
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads "87 400000:93 1017600:95 1190400:95"
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/min_sample_time 20000
write /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq 400000
# Enable governor for Big CUSs (power cluster)
write /sys/devices/system/cpu/cpu4/online 1
write /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor "interactive"
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/above_hispeed_delay 40000
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/go_hispeed_load 93
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/timer_rate 20000
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/hispeed_freq 998400
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/io_is_busy 1
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/target_loads "87 400000:93 998400:95 1190400:95 1382400:97"
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/min_sample_time 20000
write /sys/devices/system/cpu/cpu4/cpufreq/scaling_min_freq 400000
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/max_freq_hysteresis 60000
# Configure core_ctl
write /sys/devices/system/cpu/cpu0/core_ctl/not_preferred "1 0 1 0"
write /sys/devices/system/cpu/cpu0/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu0/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu0/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu0/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/not_preferred "1 0 1 0"
write /sys/devices/system/cpu/cpu4/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu4/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu4/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu4/core_ctl/offline_delay_ms 200
write /sys/devices/system/cpu/cpu4/core_ctl/task_thres 4
write /sys/devices/system/cpu/cpu4/core_ctl/is_big_cluster 1
# set cpu_boost parameters
write /sys/module/cpu_boost/parameters/input_boost_freq "0:1017600 1:0 2:0 3:0 4:0 5:0 6:0 7:0"
write /sys/module/cpu_boost/parameters/input_boost_ms 200
write /proc/sys/kernel/sched_upmigrate_min_nice 15
write /proc/sys/kernel/sched_upmigrate 87
# set (super) packing parameters
write /sys/devices/system/cpu/cpu0/sched_mostly_idle_freq 400000
write /sys/devices/system/cpu/cpu4/sched_mostly_idle_freq 400000
S650 hexa core
Code:
#!/system/bin/sh
#
################################################################################
# helper functions to allow Android init like script
function write() {
echo -n $2 > $1
}
function copy() {
cat $1 > $2
}
function get-set-forall() {
for f in $1 ; do
cat $f
write $f $2
done
}
################################################################################
# Enable governor for LITTLE CPUs (perrf cluster)
write /sys/devices/system/cpu/cpu0/online 1
write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor "interactive"
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/above_hispeed_delay 40000
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/go_hispeed_load 90
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_rate 20000
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/hispeed_freq 1017600
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/io_is_busy 1
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads "87 400000:93 1017600:95 1190400:95"
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/min_sample_time 20000
write /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq 400000
# Enable governor for Big CUSs (power cluster)
write /sys/devices/system/cpu/cpu4/online 1
write /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor "interactive"
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/above_hispeed_delay 40000
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/go_hispeed_load 93
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/timer_rate 20000
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/hispeed_freq 998400
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/io_is_busy 1
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/target_loads "87 400000:93 998400:95 1190400:95 1382400:97"
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/min_sample_time 20000
write /sys/devices/system/cpu/cpu4/cpufreq/scaling_min_freq 400000
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/max_freq_hysteresis 60000
# Configure core_ctl
write /sys/devices/system/cpu/cpu0/core_ctl/not_preferred "1 0 1 0"
write /sys/devices/system/cpu/cpu0/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu0/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu0/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu0/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/not_preferred "1 1"
write /sys/devices/system/cpu/cpu4/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu4/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu4/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu4/core_ctl/offline_delay_ms 200
write /sys/devices/system/cpu/cpu4/core_ctl/task_thres 4
write /sys/devices/system/cpu/cpu4/core_ctl/is_big_cluster 1
# set cpu_boost parameters
write /sys/module/cpu_boost/parameters/input_boost_freq "0:1017600 1:0 2:0 3:0 4:0 5:0 6:0 7:0"
write /sys/module/cpu_boost/parameters/input_boost_ms 200
write /proc/sys/kernel/sched_upmigrate_min_nice 15
write /proc/sys/kernel/sched_upmigrate 87
# set (super) packing parameters
write /sys/devices/system/cpu/cpu0/sched_mostly_idle_freq 400000
write /sys/devices/system/cpu/cpu4/sched_mostly_idle_freq 400000
You've written the frequency of one GHz is the most optimal because of silicon's physical properties, so this is very universal phenomenon (like e.g. resonance frequency) thus it applies to every silicon chip, is this right?
So I had some free time so I'm bringing back our TWRP flashable tweaks compatible only with ROM's that are based on nijel8 trees. You just have to flash it through TWRP. I also included addon.d script so tweaks will be kept after dirty flashing a ROM.
Which script you should pick?
It all depends on how you use the device. For some Zolla's will work better, for some mine will work better. Test it yourself(with and without core_ctl) and tell us how it goes.
Remember to pick zip for your device! Hydrogen is for Mi Max(2/16GB or 3/32GB) and Helium is for Mi Max Prime(3/64GB or 4/128GB). Don't mess it up or you might end into a bootloop.
Thanks to @Zola III for his tweaks.
@ioy
I don't really think you understand heuristics still.
1401600:99 & 1804800:99 are top frequencies per both clusters & it's a bit funny to try to manage their up scale load as their is no frequency behind it. You need a brick at big cluster at around 1.4GHz so find as I wrote earlier.
above_hispeed_delay "29000 1382400:39000" should be set to 40000 as the main scheduler tick rate is set to 20000 so every two ticks to decide to go over a GHz is perfectly enough. In many cases default scheduler tick rate is set to 40000 for maximum responsiveness that our eay sight can register I put it ti the 20000 rt clock ticks which is equivalent to a time needed for a blink of an eye. Anything in between isn't needed.
# note: Zola III proposed this to be applied to core 5 (cpu5)
Nope! It's understud it will be applied across the cluster & for msm8956 their is no need to apply anything more as their is only one more big core (cpu5) with shared L2 memory with cpu4. However on msm8976 (S652) it needs to be applied to cpu6 so that it is instructed specifically to use that core & keep it idle instead cpu5 as that way it has second L2 cache In use both cores keep exclusive not shared memory access to the L2 cache leading to bigger instruction output. & only with set min_cpus 2 for big cluster & not_preferred "1 0 1 0" instructing that it would be two core's permanently idling and that it should be a first one and third one in the cluster.
Same thing goes for a small cluster but this time around it's universal across both boards.
Edit at the end me by only putting min_cpus 2 & not_preferred "1 0 1 0" is all needed to be done without specific applying anything to cpu2 & cpu6 as core ctr is the one that controls which cores should be online and setup is applied for whole cluster anyway from a first core (cpu0, cpu4).
One more thing don't modify deadline;
echo '1473' > /sys/class/timed_output/vibrator/vtg_level
It's ridiculous & only hurts true output.
Find the script as I wrote on other form & try it.
@Zola III
Could you write here some setting for little cluster core_ctl? I want try it with setting of 2 little + 1 big and don't know with what's values should start on that busy up and busy down.
Anyone have the voltage tables for Hydrogen and Helium? I heard of the Kenzo sources for the SD650 having these tables, I couldn't find them though.
Don't laugh, I'm trying that initial Ghostpepper governor setup with forced steps to efficient frequencies and skipping less efficient ones. The latest version seems to have a more gradual stepping through all frequencies instead of the quick and hard jumps of the initial version.
Jerry08 said:
Did you test your settings? Im using different rom than nijel8, so no not_prefered setting. I test it myself and with this I have no lag. 1382mhz is not used by big cluster for me so 1190mhz is right. And that lovely smoothness and 4900 score on multicolore on Geekbench makes me stay there. Oh and the 99 on 1401600 is leftover from firsts setups. Dunno why I didn't remove it since I removed from 1804mhz.
Edit: Damn didn't see that @ioy, thought it was about my setup.
Another thing is that there is no difference in battery between 400mhz and 691mhz on little cluster so I recommend setting 691mhz.
Click to expand...
Click to collapse
Currently I don't test anything as my max is still locked but in the past I did very much work about it & some of it you can find hire:
https://forum.xda-developers.com/galaxy-s3-neo/orig-development/kernel-n1kernel-t3208957
Well 1.4GHz top is also applied & to your settings, 1.2GHz if you want to save a little more going above it is absurd.
Well even 400 & 691MHz are on the same VVD 691 will still use considerable more power but it will also have less reason to jump up on smaller loads so it's easier to contain. Problem appears more if min is set to 400MHz but not good contained there so that it jumps more frequently to the 691 & in that case it actually do spend considerable more power even than its set to min 691. & I do know that for a fact by experimenting. How ever I find 400 MHz min as more reasonable to save some juice & contain it not to bump over without real need after all we have hi speed load tunable there to make a fast bridge jump over in case of any real significant workload. It's not how 691MHz isn't reasonable if you want to go for more performance orientated setup (it will still use approximately 2x power than set to 400) but it also brings the other part of the problem & that would be how 1GHz & 691MHz are relatively close together so hi speed load should also be adjusted in this case more towards 1.2GHz. I don't intend to push performance metrics so I will remain at the balanced approach (400 min, 1GHz hispeed_freq) as an optimal.
Edit:
By the way 85 for an calculated load for a scaling up frequency or hi speed load is way to aggressive with IO is busy signaling enabled, without it its ok so bump it up a bit.
Zola III said:
Currently I don't test anything as my max is still locked but in the past I did very much work about it & some of it you can find hire:
https://forum.xda-developers.com/galaxy-s3-neo/orig-development/kernel-n1kernel-t3208957
Well 1.4GHz top is also applied & to your settings, 1.2GHz if you want to save a little more going above it is absurd.
Well even 400 & 691MHz are on the same VVD 691 will still use considerable more power but it will also have less reason to jump up on smaller loads so it's easier to contain. Problem appears more if min is set to 400MHz but not good contained there so that it jumps more frequently to the 691 & in that case it actually do spend considerable more power even than its set to min 691. & I do know that for a fact by experimenting. How ever I find 400 MHz min as more reasonable to save some juice & contain it not to bump over without real need after all we have hi speed load tunable there to make a fast bridge jump over in case of any real significant workload. It's not how 691MHz isn't reasonable if you want to go for more performance orientated setup (it will still use approximately 2x power than set to 400) but it also brings the other part of the problem & that would be how 1GHz & 691MHz are relatively close together so hi speed load should also be adjusted in this case more towards 1.2GHz. I don't intend to push performance metrics so I will remain at the balanced approach (400 min, 1GHz hispeed_freq) as an optimal.
Click to expand...
Click to collapse
Well setting of 400mhz as min was making too much jumping to 691mhz just like u said so I keep 691 so it sits there for long time. I will try higher setting of high frequency next battery cycle.
Jerry08 said:
@Zola III
Could you write here some setting for little cluster core_ctl? I want try it with setting of 2 little + 1 big and don't know with what's values should start on that busy up and busy down.
Click to expand...
Click to collapse
OK I will. Tell me which SoC do you have?
Zola III said:
OK I will. Tell me which SoC do you have?
Click to expand...
Click to collapse
652 helium.
Jerry08 said:
Well setting of 400mhz as min was making too much jumping to 691mhz just like u said so I keep 691 so it sits there for long time. I will try higher setting of high frequency next battery cycle.
Click to expand...
Click to collapse
No wonder that it jumps with calculated scaling up frequently set to 85 with IO is busy signaling enabled...
---------- Post added at 08:20 PM ---------- Previous post was at 08:03 PM ----------
Jerry08 said:
652 helium.
Click to expand...
Click to collapse
OK try like this for two little & one big;
# Configure core_ctl
write /sys/devices/system/cpu/cpu0/core_ctl/not_preferred "1 0 1 0"
write /sys/devices/system/cpu/cpu0/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu0/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu0/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu0/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/not_preferred "1 0 0 0"
write /sys/devices/system/cpu/cpu4/core_ctl/min_cpus 1
write /sys/devices/system/cpu/cpu4/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu4/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu4/core_ctl/offline_delay_ms 200
write /sys/devices/system/cpu/cpu4/core_ctl/task_thres 4
write /sys/devices/system/cpu/cpu4/core_ctl/is_big_cluster 1
This would be for a two + two combo & only on Helium (S652):
# Configure core_ctl
write /sys/devices/system/cpu/cpu0/core_ctl/not_preferred "1 0 1 0"
write /sys/devices/system/cpu/cpu0/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu0/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu0/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu0/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/not_preferred "1 0 1 0"
write /sys/devices/system/cpu/cpu4/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu4/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu4/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu4/core_ctl/offline_delay_ms 200
write /sys/devices/system/cpu/cpu4/core_ctl/task_thres 4
write /sys/devices/system/cpu/cpu4/core_ctl/is_big_cluster 1
Two + two should be most suitable deal performance wise especially regarding inter core (& cross cluster regarding it) communication very important for thread migration between clusters.
Best regards.
Zola III said:
No wonder that it jumps with calculated scaling up frequently set to 85 with IO is busy signaling enabled...
---------- Post added at 08:20 PM ---------- Previous post was at 08:03 PM ----------
OK try like this for two little & one big;
# Configure core_ctl
write /sys/devices/system/cpu/cpu0/core_ctl/not_preferred "1 0 1 0"
write /sys/devices/system/cpu/cpu0/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu0/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu0/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu0/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/not_preferred "1 0 0 0"
write /sys/devices/system/cpu/cpu4/core_ctl/min_cpus 1
write /sys/devices/system/cpu/cpu4/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu4/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu4/core_ctl/offline_delay_ms 200
write /sys/devices/system/cpu/cpu4/core_ctl/task_thres 4
write /sys/devices/system/cpu/cpu4/core_ctl/is_big_cluster 1
This would be for a two + two combo & only on Helium (S652):
# Configure core_ctl
write /sys/devices/system/cpu/cpu0/core_ctl/not_preferred "1 0 1 0"
write /sys/devices/system/cpu/cpu0/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu0/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu0/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu0/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/not_preferred "1 0 1 0"
write /sys/devices/system/cpu/cpu4/core_ctl/min_cpus 2
write /sys/devices/system/cpu/cpu4/core_ctl/max_cpus 4
write /sys/devices/system/cpu/cpu4/core_ctl/busy_up_thres 78
write /sys/devices/system/cpu/cpu4/core_ctl/busy_down_thres 55
write /sys/devices/system/cpu/cpu4/core_ctl/offline_delay_ms 200
write /sys/devices/system/cpu/cpu4/core_ctl/task_thres 4
write /sys/devices/system/cpu/cpu4/core_ctl/is_big_cluster 1
Two + two should be most suitable deal performance wise especially regarding inter core (& cross cluster regarding it) communication very important for thread migration between clusters.
Best regards.
Click to expand...
Click to collapse
Okay I'm a test it tomorrow when I discharge battery. And that not_prefered doesn't work for me cause I'm using AICP and not nijel8's LOS and as I remember right nijel8 fixed something in core_ctl to make it work.
Jerry08 said:
Okay I'm a test it tomorrow when I discharge battery. And that not_prefered doesn't work for me cause I'm using AICP and not nijel8's LOS and as I remember right nijel8 fixed something in core_ctl to make it work.
Click to expand...
Click to collapse
Don't really know about it on AICP, what is & how implemented. Core ctrl is developed originally by Motorola and CAF for CAF obviously (read the CAF as the AOSP) fany part is all for max is based upon Lineage including AOSP alike ROM's. The not_preferred is actually used to mark which core's should be those kept active idling. If not_preferred works as it should please do & post (full) results for PCmark works 2.0 test
If it's not a to big problem for you regarding both 2+1 & 2+2 setup. Thanks in advance.
Zola III said:
Don't really know about it on AICP, what is & how implemented. Core ctrl is developed originally by Motorola and CAF for CAF obviously (read the CAF as the AOSP) fany part is all for max is based upon Lineage including AOSP alike ROM's. The not_preferred is actually used to mark which core's should be those kept active idling. If not_preferred works as it should please do & post (full) results for PCmark works 2.0 test
If it's not a to big problem for you regarding both 2+1 & 2+2 setup. Thanks in advance.
Click to expand...
Click to collapse
I'm sure that not preferred parameters doesn't work for me cause its using Strix los kernel. And yes I'll test both setups just give me few days as I'm testing new setups with at least 1 full battery cycle or more if I don't find it lagging or stuttering.
Zola III said:
@ioy
I don't really think you understand heuristics still.
1401600:99 & 1804800:99 are top frequencies per both clusters & it's a bit funny to try to manage their up scale load as their is no frequency behind it. You need a brick at big cluster at around 1.4GHz so find as I wrote earlier.
Click to expand...
Click to collapse
And what about this:
Code:
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads "80 400000:87 1017600:95 1190400:99"
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/target_loads "87 400000:90 1017600:95 1382400:99"
BTW what does the first number after "target_loads" mean?
HELIUM, LOCKED bootloader, [ROM][UNOFFICIAL][7.1.1][HYDROGEN/HELIUM]LineageOS 14.1 r.03-27-2017 by*nijel8
ioy said:
And what about this:
Code:
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads "80 400000:87 1017600:95 1190400:99"
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/target_loads "87 400000:90 1017600:95 1382400:99"
HELIUM, LOCKED bootloader, [ROM][UNOFFICIAL][7.1.1][HYDROGEN/HELIUM]LineageOS 14.1 r.03-27-2017 by*nijel8
Click to expand...
Click to collapse
Actuality try like this:
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads "87 400000:90 1017600:93 1190400:95"
write /sys/devices/system/cpu/cpu4/cpufreq/interactive/target_loads "87 400000:90 1017600:93 1382400:95"
99 is bit to much & this is also with IO is busy idling enabled considered in.
Why's 99 too much? I have visibly better Ampere readings with this (while reading the forum through TapaTalk).
What does the first number after "target_loads" mean?
About busy idling, do you mean this:
write /sys/devices/system/cpu/cpu0/cpufreq/interactive/io_is_busy 1
is this right?
@Zola III
Well I decided to set up little cluster core_ctl today and it seems that it needs that not_prefered setting as after I set up 2+1(or 2+2 later) I ran into network problems. It was stopping network for few seconds every minute. So sorry but I won't be able to test it.

[Kernel][3.4.113] Chrono Kernel R5.10

Custom kernel for Samsung Galaxy S Advance
Code:
/*
* Your (probably expired) warranty is now void.
*
* I am not responsible for bricked devices, dead SD cards,
* thermonuclear war, or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this kernel
* before flashing it! YOU are choosing to make these modifications, and if
* you point the finger at me for messing up your device, I will laugh at you.
*/
Features:
Universal kernel for JB, KK, LP and MM-based ROMs
CPU, GPU and DDR OC support
more governors and I/O schedulers
Lite kernel - some kernel features moved as modules
F2FS support
ABB-charger tweaks
many others features and tweaks...
Credits:
@dh.harald and @hafidzduddin for contribution on U8500 platform sources
@ Team Canjica for a base for this kernel
@ Nova Fusion for F2FS implementation
@zwliew for contribution on TC kernel
@cocafe for LiveOPP, GPU OC, abbamp and abb-charger tweaks and many cool patches which I've used from his kernel
@faux123 for dynamic Fsync implementation
@Christopher83 for dynamic management of dirty page writebacks implementation
@KINGbabasula for contribution on TC kernel sources
@boype for SIOPlus tweaks and OndemandPlus governor
@Adi_Pat for abbamp, kernel tweaks
@PolishVodka for initramfs scripts for 4.2.x and 5.0.x
@Rox for help in fixing initramfs scripts for 4.1.2
@ace2nutzer for optimization CPU OC and for whatever scripts which I have used in my kernel
@Meticulus for BLN, Sweep2wake and Doubletap2wake
@mkaluza for huge LiveOPP/Mali improvements and Dynamic governor
@yanpol199 for help with F2FS support in TWRP
@ all users who tests this kernel and directs the development along the right path
@ all those users, who I forgot to mention (PM me if so)
Team Win for TWRP recovery
Samsung for opening kernel source
Linus Torvalds for Linux sources
Special Thanks:
@isaak, @enkflr, @Pdevo, @prometej-zg for donating this phone!
[*]@S.AMU for providing FTP-Server
Source Code:
LK 3.10.y based releases
r5.7.x (LK 3.4.y based releases)
Installation:
Flash temporary kernel (if coming from other recoveries than TWRP 3.1.1)
Reboot recovery
Flash kernel zip
Compatibility:
I only add those ROMs that are confirmed to work by me or someone else:
Stock 4.1.2 ROM
LineageOS 11
CyanogenMod 13
Notice: this kernel is not compatible with NovathorSettings app, be sure to remove it before installing a kernel!
Download:
FTP
XDA:DevDB Information
Chrono Kernel, Kernel for the Samsung Galaxy S Advance I9070
Contributors
ChronoMonochrome, cocafe, faux123, zwliew, mkaluza, Meticulus, KINGbabasula, ace2nutzer, TeamCanjica
Source Code: https://github.com/ChronoMonochrome/Chrono_Kernel-1/commits/master
Kernel Special Features:
Version Information
Status: Stable
Current Stable Version: R5.7.1
Stable Release Date: 1974-11-11
Beta Release Date: 1974-11-11
Created 2018-03-09
Last Updated 2018-04-16
Changelogs and features
Changelog
R5.9.1
Resolved (hopefully) deepsleep issues *
Fixed touchkey not working issue **
* tested in about 24 hours so far with ~6 hours of deep sleep on UltimateROM 6.0.1 without any issues with wakelocks.
** It seems that in r5.9 was introduced a bug - touch keys weren't working (at least, on 6.0.1) after device wake up.
R5.9
Bring up all the latest CK code from Codina kernel
Fix a severe performance issue on r5.8.2 build
BLN is finally FIXED! *
* Apparently, issues with BLN were related to Janice touchkey driver that was putting the device to sleep (when the display is off) regardless of a BLN wakelock usage. Reverting this behavior seemed to enable BLN to work.
R5.8.2
In-kernel vibrator fix for Android 6.0+
R5.8.1
PowerHAL fixes for 4.4.4
Experimental fix for CPU governor issue on 4.4.4
LCDCLK: revert to TeamCanjica kernel implementation
R5.8
Memory management hugely improved (finally LMK works properly)
Fixed powersave interface on JB 4.1.2 stock
Experimental fixes to PowerHAL on 4.4.4
LiveOPP: merged changes from refresh kernel (removed some CPU freq steps)
Dynamic: adjust tunables (same like in refresh kernel)
Possible vibrator fix on 6.0+ (not tested)
(old changelog)
R5.7.1
Initial build for janice (kernel sources based on LineageOS 15.1 kernel for Codina)
Fixed bluetooth issue on 4.1.2
Squash-reverted GPU-related code logic from CPU governor Dynamic
J4FS module code cleanup
Reverted forcing minimum CPU freq to 800 MHz
Enabled CONFIG_CPUSETS (required by Android 6.0.x+ ROMs to function properly)
Kernel Tweaks:
(GPU/CPU undervolting and related tweaks)
Undervolting the CPU/GPU will bring battery savings but possible instability.
1) to undervolt CPU use ChronoKernel app or via init.d scripts:
Code:
echo *cpufreq* varm=xx > /sys/kernel/liveopp/arm_summary
for example, following sets voltage varm=0x10 for 200 MHz:
Code:
echo 200000 varm=0x10 > /sys/kernel/liveopp/arm_summary
or
Code:
echo 200000 varm-=10 > /sys/kernel/liveopp/arm_summary
(default varm voltage for 200 MHz is 0x1a but, code above sets 0x1a - 0xa(10) = 0x10 )
2) to undervolt GPU use init.d script:
Code:
echo x vape=yy > /sys/kernel/mali/mali_dvfs_config
Example:
Code:
echo 2 vape=0x1c > /sys/kernel/mali/mali_dvfs_config
"2" stands for DVFS idx (look at mali_boost_high/mali_boost_low).
To prevent overriding of such settings by ChronoKernel app, add line to your init.d script after GPU undervolting
Code:
chmod 444 /sys/kernel/mali/mali_dvfs_config
Don't change voltage of both GPU/CPU at the same time - otherwise if you'll get reboot if won't know what it caused. The same is for different frequencies - if you'll change voltage of too many steps you won't know which frequency caused reboot. It's not easy process, though, following method simplifies it: https://github.com/mkaluza/i9070_kernel_CoCore-E/wiki/Undervolting-janice .
3) Custom LiveOPP table.
By default some LiveOPP steps such as 100, 200, 500 ... MHz aren't used. You can re-enable those by following way:
Code:
echo 200000 enable=1 > /sys/kernel/liveopp/arm_summary
Or use CK app instead. Don't enable it unless it uses the same voltage as 400 MHz. The same is for the rest frequencies - until some of them uses same voltage, no point to enable steps with lower freq. I've added 100 MHz just to further make some tests with it once again. It can't use lower varm than 200 MHz - that's why it's disabled by default. Furthermore, not all phones well keep undervoltage, that's why 100-400 MHz steps uses same stock voltage varm=0x1a.
UPD. thanks to @borkins for this nice editor LiveOPP ARM steps: http://forum.xda-developers.com/showpost.php?p=60311291&postcount=2921
(CPU freq management tweaks)
CPU freq. limiter for screen OFF, adjust it via:
Code:
SYSFS=/sys/kernel/cpufreq/cpufreq_limits_on_suspend
echo min=100000 > $SYSFS
echo max=400000 > $SYSFS
echo on > $SYSFS
Too low frequency may cause freezes after wakeup and sound scrathes. If you use Dynamic govermor, it make no sense to use cpufreq limiter, because Dynamic already takes care about CPUfreq usage optimization. For more, read wiki.
Input boost
This feature has been originally written by zwliew.
Not all governors support input boost. Supported governors: ondemand, interactive, conservative, ZenX, lionheart and some others. Dynamic governor has its own boost interface.
Default boost frequency is 400 MHz.
Code:
echo 450000 > /sys/kernel/cpufreq/input_boost_freq # echo '0' to disable
echo 35 /sys/kernel/cpufreq/input_boost_ms
(BackLight Notification)
To configure time intervals of BLN blinking type(bln_ondelay stands for time of blink and bln_offdelay - delay between two blinks):
Code:
echo bln_ondelay=500 > /sys/kernel/bln/blink_mode
echo bln_offdelay=6000 > /sys/kernel/bln/blink_mode
Make sure BLN enabled:
Code:
echo 1 > /sys/class/misc/backlightnotification/enabled
# to enable bln_wakelock.
echo on > /sys/kernel/bln/bln_wakelock
Use /sys/devices/virtual/misc/backlightnotification/blink_mode to changes modes.
Blink modes:
0 = no blinking
1 = blink backlight only
2 = blink backlight + rear cam flash
3 = blink rear cam flash only
(Module autoload)
Now there is a simple way to load modules at boot. Just move needed modules to /system/lib/modules/autoload and reboot device(or execute /etc/init.d/00autoload)
(DDR overclock)
This feature has been developed by me and allows you to improve DDR and GPU performance. Please note, that DDR OC might work unstable and cause filesystem corruption. Though, DDR clock of 975 MHz has been highly tested and should work fairly stable on most devices.
Overclocking DDR over 975 MHz is highly NOT recommended, especially in case if you not sure that you can deal with possible consequences.
How to OC DDR:
1) by using
this script .
2) by using Terminal Emulator(in example below 975 MHz):
Code:
echo 0x5017f > /sys/kernel/liveopp/pllddr_oc_on_suspend
This setting will be applied right after disabling screen.
(Minimum APE/DDR OPP on screen on)
This feature has been developed by me and allows to set minimum APE/DDR OPP states which are used when screen is ON. APE controls many systems such as an image, video, audio system etc. DDR OPP determines performance of DDR. Default values are APE50 and DDR50. Lower states(APE25/DDR25) reduces power consumption, but may cause graphical glitches like screen blinking or filling it by vertical grey lines. If you don't have mentioned effects, it's recommended to use APE25/DDR25:
Code:
echo ddropp=25 > /sys/devices/pri_lcd_ws2401.0/mcde_screenon_opp
echo apeopp=25 > /sys/devices/pri_lcd_ws2401.0/mcde_screenon_opp
* if you don't have folder /sys/devices/pri_lcd_ws2401.0, use /sys/devices/pri_lcd_s6d27a1 instead.
(Screen refresh rate)
This feature has been developed by cocafe and modified by me. Lower lcdclk frequency cause less power usage, but too low values makes system unusable.
Following command allows to change screen refresh rate:
Code:
echo x > /sys/kernel/mcde/lcdclk
use
Code:
cat /sys/kernel/mcde/lcdclk
to see supported lcdclk modes. Default mode is 60 Hz which is recommended in most typical cases. If you've screen tearings, blinking etc. change resresh rate mode to "60+ Hz":
Code:
echo 0 > /sys/kernel/mcde/lcdclk
(ABB charger tweaks)
added tweakable interfaces for termination current. To adjust it type(just an example):
Code:
echo 90 > /sys/kernel/abb-chargalg/termination_curr_1st
echo 70 > /sys/kernel/abb-chargalg/termination_curr_2nd
curr_2nd should be less or same as curr_1st. Lower values prolongs battery lifetime, but also slows battery charging.
Default values are curr_1st == curr_2nd == 150 mA. Please note, too low values maybe aren't usable.
(Dynamic FSync)
This feature has been developed by Faux123 and allows to dynamically manage the synchronous writes performed on file system (FSync).
It uses asynchronous writes when the screen is on, instead of synchronous writes, to have better performance and a slightly lower battery drain, while when the screen is off the synchronous writes are re-enabled to flush all the outstanding writes and prevent possible data loss.
How to enable/disable the Dynamic FSync (default enabled):
1) By downloading and using Trickster MOD
2) By directly editing the file /sys/kernel/dyn_fsync/Dyn_fsync_active and setting 1 to enable the dynamic fsync, 0 to disable it (note that set value will be lost after a reboot/shutdown)
3) By using Terminal Emulator (note that set value will be lost after a reboot/shutdown)
- Open Terminal Emulator
- Run this command to disable the dynamic fsync feature
Code:
su
echo 0 > /sys/kernel/dyn_fsync/Dyn_fsync_active
- Or run this command to re-enable the dynamic fsync feature
Code:
su
echo 1 > /sys/kernel/dyn_fsync/Dyn_fsync_active
Click to expand...
Click to collapse
(Software CRCs)
Disabling software CRCs gives you a slight bump(10-30% is what they say) of MMC performance, at the cost of a possibility of your Ace 2 freezing randomly.
Code:
echo 0 > /sys/module/mmc_core/parameters/use_spi_crc
Click to expand...
Click to collapse
(Dynamic dirty page writebacks)
This feature has been developed by Christopher83 and allows to dynamically manage the dirty page writebacks with two different intervals, one when the screen is on and another when the screen is off.
It is based on a commit of Francisco Franco, but instead of using hard coded values and of disabling at all the dirty page writebacks while the screen is on (possibility of data loss).
By using a higher interval we have better performance and less battery consumption, with a very low risk of data loss.
How to customize the dynamic dirty page writebacks feature (default disabled):
Three new procfs parameters are exposed inside /proc/sys/vm path:
- dynamic_dirty_writeback is the activation status of this feature, set 1 to enable it, set 0 to disable it and use the standard behaviour
- dirty_writeback_active_centisecs is the interval for the dirty page writebacks when the system is active (screen on), the default value is 1500 centisecs (15 seconds)
- dirty_writeback_suspend_centisecs is the interval for the dirty page writebacks when the system is suspended (screen off), the default value is 500 centisecs (5 seconds)
1) By directly editing one of the file written above inside /proc/sys/vm and setting the preferred value (note that set value will be lost after a reboot/shutdown)
2) By using Terminal Emulator (note that set value will be lost after a reboot/shutdown)
- Open Terminal Emulator
- Run this command to disable the dynamic dirty page writebacks feature
Code:
echo 0 > /proc/sys/vm/dynamic_dirty_writeback
- Or run this command to re-enable the dynamic dirty page writebacks feature
Code:
echo 1 > /proc/sys/vm/dynamic_dirty_writeback
- Run this command to set customize the two intervals (30 seconds while the screen is on, 10 seconds when the screen is off)
Code:
echo "3000" > /proc/sys/vm/dirty_writeback_active_centisecs
echo "1000" > /proc/sys/vm/dirty_writeback_suspend_centisecs
(Tweak app)
ChronoKernel settings
Thanks mars_army for this app!
Bug reports:
after experiencing a random reboot, type in terminal:
Code:
su
cat /proc/last_kmsg > /storage/sdcard0/last_kmsg.txt
report it in the thread and attach the last_kmsg.txt
Misc
Storages switch
By default, this kernel comes with internal and external storages switched. You can revert this behavior, by changing the line
Code:
use_swap=1
to
Code:
use_swap=0
in file /ramdisk/fstab_specs.txt and flashing the kernel package. This setting will remain until you format /ramdisk partition.
@ChronoMonochrome
I tested "chrono_kernel_r5.7.1-test-40-g169a68f4f29d-janice.zip" on Lineage OS 11.
Result: I have the same hiccups in the youtube video like before.
I think that you can revert the LCDCLK frequency to the default 60 Hz value, because I didn't notice any significant difference.
And I had an isolated crash while I was navigating in settings.
My usual running apps & services are: Should I answer?, Nova Launcher, Tesla Unread, Google Play Services 11.9.75, Ginger Keyboard, Skype 7.46.0.596 (old version from apkmirror), Quickpic, Terminal Emulator, CCleaner, Google Play Store 9.0.15, Tubemate 3.0.11, My Vodafone, Naked Browser, Titanium Backup, Fx File Explorer, Gmail, Google News & Weather, MX Player.
I hope that these logs can help you.
isaak said:
@ChronoMonochrome
I tested "chrono_kernel_r5.7.1-test-40-g169a68f4f29d-janice.zip".
Result: I have the same hiccups in the youtube video like before.
I think that you can revert the LCDCLK frequency to the default 60 Hz value, because I didn't notice any significant difference.
And I had an isolated crash while I was navigating in settings.
My usual running apps & services are: Should I answer?, Nova Launcher, Tesla Unread, Google Play Services 11.9.75, Ginger Keyboard, Skype 7.46.0.596 (old version from apkmirror), Quickpic, Terminal Emulator, CCleaner, Google Play Store 9.0.15, Tubemate 3.0.11, My Vodafone.
I hope that these logs can help you.
Click to expand...
Click to collapse
Thanks for the report! Unfortunately, the last_kmsg log appears to be taken from MaxiCM kernel, so the crash isn't captured here. In the meantime I'll install some of those apps to test how it goes under increased memory pressure. Was /proc/meminfo log taken before or after reboot? It would be useful to check this sysfs interface when the phone is encountering laggs (if it does), but after reboot this info won't help. About lowmemorykiller changes: were apps running faster / slower? So far Youtube playback is the only issue or phone laggs too?
ChronoMonochrome said:
Thanks for the report! Unfortunately, the last_kmsg log appears to be taken from MaxiCM kernel, so the crash isn't captured here. In the meantime I'll install some of those apps to test how it goes under increased memory pressure. Was /proc/meminfo log taken before or after reboot? It would be useful to check this sysfs interface when the phone is encountering laggs (if it does), but after reboot this info won't help. About lowmemorykiller changes: were apps running faster / slower? So far Youtube playback is the only issue or phone laggs too?
Click to expand...
Click to collapse
/proc/meminfo log was taken before the reboot. Youtube playback is not the only issue. I can just say that the best way to reproduce a crash or a slowdown is switching from an app to another as quick as possible and/or try a cleaning with CCleaner. Ah, in that list I forgot some apps, so I've updated my previous post.
So far I've tested as much as possible on stock 4.1.2 rom and everything is working fine.
-Bluetooth is definitely fixed, working like a charm.
-CRC, FSYNC and other tweaks give me no issue at all and work good.
-Tested a bit of undervolting, firstly cpu, then gpu, and DDR OC, and here too, no problems.
-Really great the supension min and max cpufreq, tested it with some init.d scripts.
Overall stability and responsiveness of the system is impressive, really positive, you really made a big surprise
These instead are the few things I noticed not working, I think the first two are really not a major problem at all and maybe I am messing with something:
1. I have noticed that trying to set governor by init.d script doesn't seem to take effect and at boot completed I find performance setted as governor:
busybox echo dynamic > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor;
Click to expand...
Click to collapse
Running then the script manually set dynamic as governor correctly.
(SOLVED WITH A BUSYBOX CHMOD COMMAND BEFORE EVERY PARAMETER SET)
2. I tryed using exfat support, loaded fuse.ko and exfat.ko modules on boot, then used the same binary from cocafe twrp kernel I was using fine (and here I think there is the issue) with this command:
exfat-fuse /dev/block/mmcblk1p1 /storage/extSdCard;
Click to expand...
Click to collapse
Sdcard isn't recognized and android is asking to format it as usual.
3. I guess should be the number one: Recovery doesn't seem to work, tryed many times, also removing battery first, but I can't enter in recovery. Next time I flash kernel I will do it manually from terminal, or Universal Kernel Flash app
EDIT1:
I found that the path where lcd parameters are located would be:
/sys/kernel/s6e63m0/panel/lcd_clk
Click to expand...
Click to collapse
instead of:
/sys/kernel/mcde/lcdclk
Click to expand...
Click to collapse
EDIT2:
Seems like deepsleep is broken, because in my situation phone doesn't enter in deepsleep mode and having a look at /d/supsend_stats and d/suspend directory confirm my issue.
I found at first strange the absence of /d/cpuidle directory and so the deepest_state configuration file, like something is missing here.
EDIT3:
I think I found another last issue, BLN is not working, but I think could be again something to do with files and folder structure, for example I can't find:
/sys/class/misc/backlightnotification/enabled
Click to expand...
Click to collapse
Again, this is still something not so important tough
EDIT4:
I was experiencing before issues with phone calls, making phone app freezing and signal loss, going to "no service" mode. Had to flash backup kernel for now, tomorrow as I get some time again I will provide logs
Pdevo said:
So far I've tested as much as possible on stock 4.1.2 rom and everything is working fine.
-Bluetooth is definitely fixed, working like a charm.
-CRC, FSYNC and other tweaks give me no issue at all and work good.
-Tested a bit of undervolting, firstly cpu, then gpu, and DDR OC, and here too, no problems.
-Really great the supension min and max cpufreq, tested it with some init.d scripts.
Overall stability and responsiveness of the system is impressive, really positive, you really made a big surprise
Click to expand...
Click to collapse
Thanks for a review!
2. I tryed using exfat support, loaded fuse.ko and exfat.ko modules on boot, then used the same binary from cocafe twrp kernel I was using fine (and here I think there is the issue) with this command:
Sdcard isn't recognized and android is asking to format it as usual.
Click to expand...
Click to collapse
Honestly I didn't test exfat for a long time. These issues might come due to the filesystem driver updates. Anyway I need to test things myself before I'll have clues on how to fix it.
3. I guess should be the number one: Recovery doesn't seem to work, tryed many times, also removing battery first, but I can't enter in recovery. Next time I flash kernel I will do it manually from terminal, or Universal Kernel Flash app
Click to expand...
Click to collapse
Are you sure you have followed the installation guide to flash the kernel? Especially, using TWRP is required to flash a kernel (other recoveries aren't tested and can be a cause for a bugs) I was returning to a stock for a short time to test if bluetooth works and recovery was working for me when I was returning to UltimateROM 6.0.1 afterwards.
Don't use manual flashing or UKF app to flash the kernel! The installation method is quite complicated (compared to installation of other kernels), so a full and proper installation is only possible if you flash it from recovery.
EDIT1:
I found that the path where lcd parameters are located would be:
instead of:
Click to expand...
Click to collapse
I have moved the interface to match the implementation of LCDCLK management on codina.
EDIT2:
Seems like deepsleep is broken, because in my situation phone doesn't enter in deepsleep mode and having a look at /d/supsend_stats and d/suspend directory confirm my issue.
I found at first strange the absence of /d/cpuidle directory and so the deepest_state configuration file, like something is missing here.
Click to expand...
Click to collapse
This is entirely possible due to deepsleep driver changes in a kernel. I never tested if it works on stock, I guess I'll have to return to stock once again.
EDIT3:
I think I found another last issue, BLN is not working, but I think could be again something to do with files and folder structure, for example I can't find:
Again, this is still something not so important tough
Click to expand...
Click to collapse
I was thinking BLN isn't working on this phone at all, so I disabled the kernel support. Is the stock ROM only where BLN works?
Yes sir, I flashed your kernel exactly from twrp, coming from cocore refresh24, I referred to UKF or terminal emulator to say I would use that method now that I can't enter recovery mode, but I never use these ways at all, always from recovery, because I know that kernel come with scripts and other files that without recovery wouldn't be installed
Tomorrow I will do further testing
ChronoMonochrome said:
I was thinking BLN isn't working on this phone at all, so I disabled the kernel support. Is the stock ROM only where BLN works?
Click to expand...
Click to collapse
As far as I know no dev on Janice introduced BLN, but I don't see any reason why it shouldn't be technically possible if it works on Ace II.
Please don't give up on this unless you're sure at 100%.
@cocafe had it on his todo list, but at the end he didn't implement it for unknown reasons. I asked to him but he never explained it.
ChronoMonochrome said:
I was thinking BLN isn't working on this phone at all, so I disabled the kernel support. Is the stock ROM only where BLN works?
Click to expand...
Click to collapse
Until now, BLN never been working or supported on custom and stock roms, as said by @isaak, the reason behing that I think is properly known by developers such as cocafe.
Yesterday I made a little try using the commands you point in the thread, a little go, but in fact is not working. Would be a cool feature, but nothing so important at all for me, at least for now
UPDATE:
I flashed again the kernel, starting from freshly downloaded zip, and I got an infinite bootloop trying to get to recovery, the only way to go back working was flashing stock rom with odin.
I can now safely say there is an issue with recovery using the stock rom.
UPDATE 19:30
I took two logs, one for incoming call and one for outgoing call, reproducing the issue I was referring in previous post.
In the first case, incoming call, notification appear but scrolling to accept call make phone unusable and I could just shutdown it to solve the situation.
In the second case, outgoing call, after I start the call the phone app isn't responding, I see the notification widget but tapping on every possible button, to terminate call or enter in dialog, doesn't work and phone is very unstable until a sort of a timeout is running out and call stop itself.
Hi @ everyone!
Because of th numerous issues found with the current release, I'm starting to work on a fresh kernel sources (3.0.101), almost from scratch. My primary focus for now will be a multitasking, that is the main issue with the current release. Because of yet unknown root cause of the issue it could take a while to reveal it, but I hope to release a new build these days (and after playing with some kernel configuration find out more appropriate one for a multitasking). Stay tuned!
For sure we stay tuned!, thank you so much for the efforts and take all the time you need Chrono
isaak said:
My usual running apps & services are: Should I answer?, Nova Launcher, Tesla Unread, Google Play Services 11.9.75, Ginger Keyboard, Skype 7.46.0.596 (old version from apkmirror), Quickpic, Terminal Emulator, CCleaner, Google Play Store 9.0.15, Tubemate 3.0.11, My Vodafone, Naked Browser, Titanium Backup, Fx File Explorer, Gmail, Google News & Weather, MX Player.
I hope that these logs can help you.
Click to expand...
Click to collapse
I have set up all these apps about 10-12 days ago. I should say, removing CCleaner seemed to help a lot to increase the phone performance. It's doing a lot of background CPU and I/O work, making the phone almost unusable on r5.7.1 and severely affects performance on r4.1 / r4.6.
ChronoMonochrome said:
I have set up all these apps about 10-12 days ago. I should say, removing CCleaner seemed to help a lot to increase the phone performance. It's doing a lot of background CPU and I/O work, making the phone almost unusable on r5.7.1 and severely affects performance on r4.1 / r4.6.
Click to expand...
Click to collapse
The new CCleaner version is on the heavy side, so I had to freeze some background services with My Android Tools app. Anyway I've just uninstalled it definitively.
New build r5.8 is up!
R5.8
Memory management hugely improved (finally LMK works properly)
Fixed powersave interface on JB 4.1.2 stock
Experimental fixes to PowerHAL on 4.4.4
LiveOPP: merged changes from refresh kernel (removed some CPU freq steps)
Dynamic: adjust tunables (same like in refresh kernel)
Possible vibrator fix on 6.0+ (not tested)
ChronoMonochrome said:
R5.8
Memory management hugely improved (finally LMK works properly)
Fixed powersave interface on JB 4.1.2 stock
Experimental fixes to PowerHAL on 4.4.4
LiveOPP: merged changes from refresh kernel (removed some CPU freq steps)
Dynamic: adjust tunables (same like in refresh kernel)
Possible vibrator fix on 6.0+ (not tested)
Click to expand...
Click to collapse
I tried 5.8.5 and I have still issues with LineageOS 11:
1) I've got a screen flicker issue while I was browsing in Naked Browser with the new LCDCLK frequency.
Tried to set echo 1 > /sys/kernel/mcde/lcdclk, but I've noticed that this value is not kept after a reboot.
Very annoying, because I can't restore 60 Hz permanently.
2) There are still issues about some values not kept in the performance UI of Lineage Os.
For example:
- Try to set Zenx as governor, min. 200 max 1000, Noops scheduler. Reboot. Scheduler will be resetted to Deadline.
- There is still a bug with max clock value of Dynamic governor (I can reproduce it with ZenX governor too). I set it to 800 MHz, I go back to the settings screen, then I return to the Performance -> Processor section to check if the 800 MHz value is maintained. But the UI automatically restored the max clock to 1000 MHz without my consent.
For your information, these issues occur only randomly and with particular combinations. So, if you can't reproduce them, the best way is to set these, one at a time:
1) Zenx as governor, min. 200 max 800, Noops scheduler. Reboot.
2) Zenx as governor, min. 200 max 800, Fiops scheduler. Reboot.
2) Zenx as governor, min. 200 max 800, Sioplus scheduler. Reboot.
After the first, the second or the third reboot, some of these values you've set will change spontaneously on their own.
"Set on boot" options are correctly set for both Processor and I/O Scheduler.
And I keep "Enable per-app profiles" option turned off.
3) On the Performance UI, performance profile results automatically set on Balanced after any reboot. But if you cannot fix it, I can live with that, don't worry. It doesn't keep "Power save" or "Performance" profile between reboots.
PS: I would appreciate if you could update the installation steps in this thread with the same steps of the refresh topic:
Flash temporary kernel (if coming from other recoveries than TWRP 3.1.1)
Reboot recovery
Flash kernel zip
isaak said:
I tried 5.8.5 and I have still issues with LineageOS 11:
1) I've got a screen flicker issue while I was browsing in Naked Browser with the new LCDCLK frequency.
Tried to set echo 1 > /sys/kernel/mcde/lcdclk, but I've noticed that this value is not kept after a reboot.
Very annoying, because I can't restore 60 Hz permanently.
Click to expand...
Click to collapse
Sorry, I thought I've reverted this change. Can you confirm that setting old LCDCLK freq fixes issue? As a temporary solution you can use init.d script to set the appropriate LCDCLK freq index.
2) There are still issues about some values not kept in the performance UI of Lineage Os.
For example:
- Try to set Zenx as governor, min. 200 max 1000, Noops scheduler. Reboot. Scheduler will be resetted to Deadline
Click to expand...
Click to collapse
Can confirm now. I have a guess for that, for now the solution as follows:
remove /ramdisk/modules/autoload/sioplus-iosched.ko, reboot. I have to test this a bit more time to be sure 100%, but so far I couldn't reproduce an issue after removing this module (no other CPUfreq governor or I/O scheduler must be loaded as well).
- There is still a bug with max clock value of Dynamic governor (I can reproduce it with ZenX governor too). I set it to 800 MHz, I go back to the settings screen, then I return to the Performance -> Processor section to check if the 800 MHz value is maintained. But the UI automatically restored the max clock to 1000 MHz without my consent.
Click to expand...
Click to collapse
It's not a bug, but rather intended behavior - due to PowerHAL changes implemented, CPUfreq can only be changed via script (see /ramdisk/perf.sh). I've previously asked if anyone would prefer to adjust CPUfreq usual way, In this case I can just remove the corresponding lines from the PowerHal script. This will make PowerHAL settings a bit more useless, but will gave easier control over CPUfreq.
3) On the Performance UI, performance profile results automatically set on Balanced after any reboot. But if you cannot fix it, I can live with that, don't worry. It doesn't keep "Power save" or "Performance" profile between reboots.
Click to expand...
Click to collapse
The script actually works, though you're right, it works buggy and everytime shows the default profile (you can set, e.g. Powersave profile and check min/max CPU freq, to check if it actually works).
PS: I would appreciate if you could update the installation steps in this thread with the same steps of the refresh topic:
Flash temporary kernel (if coming from other recoveries than TWRP 3.1.1)
Reboot recovery
Flash kernel zip
Click to expand...
Click to collapse
Done!
isaak said:
I've got a screen flicker issue while I was browsing in Naked Browser with the new LCDCLK frequency.
Tried to set echo 1 > /sys/kernel/mcde/lcdclk, but I've noticed that this value is not kept after a reboot.
Very annoying, because I can't restore 60 Hz permanently.
ChronoMonochrome said:
Sorry, I thought I've reverted this change. Can you confirm that setting old LCDCLK freq fixes issue? As a temporary solution you can use init.d script to set the appropriate LCDCLK freq index.
Click to expand...
Click to collapse
Click to expand...
Click to collapse
Yes, I can confirm that setting old LCDCLK freq fixed the flicker issue for my screen. I think it would be better to set it as default in the next release.
isaak said:
There are still issues about some values not kept in the performance UI of Lineage Os.
For example:
- Try to set Zenx as governor, min. 200 max 1000, Noops scheduler. Reboot. Scheduler will be resetted to Deadline
etc etc....
ChronoMonochrome said:
Can confirm now. I have a guess for that, for now the solution as follows:
remove /ramdisk/modules/autoload/sioplus-iosched.ko, reboot. I have to test this a bit more time to be sure 100%, but so far I couldn't reproduce an issue after removing this module (no other CPUfreq governor or I/O scheduler must be loaded as well).
Click to expand...
Click to collapse
Click to expand...
Click to collapse
I tried your steps, unfortunately they didn't work for me.
ChronoMonochrome said:
It's not a bug, but rather intended behavior - due to PowerHAL changes implemented, CPUfreq can only be changed via script (see /ramdisk/perf.sh). I've previously asked if anyone would prefer to adjust CPUfreq usual way, In this case I can just remove the corresponding lines from the PowerHal script. This will make PowerHAL settings a bit more useless, but will gave easier control over CPUfreq.
Click to expand...
Click to collapse
Personally I would prefer more control over CPUfreq. Could you list the main advantages to limit CPUfreq changes only via script? Is it a sort of auto-optimization? This point is not clear to me. If you think that any change to this mechanism would affect negatively the battery life, then don't change anything.
isaak said:
On the Performance UI, performance profile results automatically set on Balanced after any reboot. But if you cannot fix it, I can live with that, don't worry. It doesn't keep "Power save" or "Performance" profile between reboots.
ChronoMonochrome said:
The script actually works, though you're right, it works buggy and everytime shows the default profile (you can set, e.g. Powersave profile and check min/max CPU freq, to check if it actually works).
Click to expand...
Click to collapse
Click to expand...
Click to collapse
I tried Powersave and Performance profiles, in both cases the maximum freq varies between 400 MHz and 1000 MHz, rarely reaching 800 MHz. Minimum freq is always 200 MHz and it doesn't change visually like the maximum freq. Balanced profile is always shown visually after a reboot.
isaak said:
Personally I would prefer more control over CPUfreq. Could you list the main advantages to limit CPUfreq changes only via script? Is it a sort of auto-optimization? This point is not clear to me. If you think that any change to this mechanism would affect negatively the battery life, then don't change anything.
Click to expand...
Click to collapse
Because of some CPUfreq scaling tunables were changed (in the case of Dynamic governor), it makes sense to implement a PowerHAL profiles, which would limit / restore the max CPUfreq. But I think I've found a solution - I will make it possible to change CPUfreq for a Balanced profile.
I tried Powersave and Performance profiles, in both cases the maximum freq varies between 400 MHz and 1000 MHz, rarely reaching 800 MHz. Minimum freq is always 200 MHz and it doesn't change visually like the maximum freq. Balanced profile is always shown visually after a reboot.
Click to expand...
Click to collapse
Ok, I found some logical errors in the script, should be fixed in upcoming release.

Categories

Resources