[MOD] Disable perflock for stock kernel (2.03.405.3) - Legend Android Development

Here I put together perflock_disable update package for Legend stock kernel 2.6.29-5f084974. It is ment to disable perflock on every boot. This package consists of perflock_disable module (now licensed under GPL) from SetCPU app and boot script that loads this module.
Background:
Stock Legend's kernel has performance lock turned on. This means that (unless you recompiled your own kernel) CPU frequency scaling is somehow limited. Default limits are set from 480 to 600 MHz while screen is on and to 246 MHz while screen is off. Furthermore ondemand CPU scaling governor is limited from 246 to 600 MHz. This means you can not underclock you Legend with SetCPU unless you use perflock disable option which you have to set manually after every reboot. And here this "update" kicks in.
Requirements:
rooted Legend of course
kernel 2.6.29-5f084974
busybox
run-parts integrated in init.rc script (/etc/init.d)
Big thanks goes to coolbho3000 who now offers this module under GPL so we can use it outside his cool app.

Good post Blayo, wish it had come along earlier.
I hope more kernels will be coming along.

Sorry... how to install this ?
from ROM Manager ?

Learners Lisence said:
Good post Blayo, wish it had come along earlier.
I hope more kernels will be coming along.
Click to expand...
Click to collapse
Well this is for stock kernel. If you have your own kernel, you could have disabled perflok while you were compiling it and you wouldn't needed this module...
Vuska said:
Sorry... how to install this ?
from ROM Manager ?
Click to expand...
Click to collapse
Install it as any other update.zip via recovery mode. But you need run-parts in your init.rc, otherwise the module won't load.
I also compiled cpufreq governor modules (conservative and powersave) for stock kernel if anyone is interested...

But you need run-parts in your init.rc, otherwise the module won't load.
Click to expand...
Click to collapse
How to do this ?

This is beyond the scope of this tread. You can try Chef Central but to be honest, if you don't know what this is or how it is done, then this (Android Development) is perhaps not the right forum for you.

BlaY0 said:
Well this is for stock kernel. If you have your own kernel, you could have disabled perflok while you were compiling it and you wouldn't needed this module...
Click to expand...
Click to collapse
Yes, Blayo. I flashed the 806 kernel by dumfuq a week back. Im quite happy with it so far but would like to experiment with more Legend compatible kernels.
I read around a bit and then decided that underclocking and battery save could be achieved by a overclock kernel designed for 'performance' ....kinda like 'having the cake and eating it too"
Nevertheless, I appreciate the ideas associated with your present and possible future shares.
Thanks

Learners Lisence said:
I read around a bit and then decided that underclocking and battery save could be achieved by a overclock kernel designed for 'performance' ....kinda like 'having the cake and eating it too"
Click to expand...
Click to collapse
Yes of course. Those custom kernels don't have enabled perflock so you can set speed by using SetCPU without loading perflock_disable module.
Well, if I'm frank I have never been fond of overclocking. My goal is just to extend the battery life of these "hungry" devices as much as possible without affecting user experience.
Right now I'm testing conservative governor and have some problems, because SetCPU can't handle switching between governors as it should.
Cheers,

BlaY0 said:
This is beyond the scope of this tread. You can try Chef Central but to be honest, if you don't know what this is or how it is done, then this (Android Development) is perhaps not the right forum for you.
Click to expand...
Click to collapse
I'll try to search about chef central and i am very new in linux OS.
but thank you...
I will learn because i have legend and i like it

Good for you
Chef Central is a subforum her on xda-developers...

Thanks, nice work, i'm send you p.m. with a consulting.

what is the "run-parts integrated in init.rc script (/etc/init.d)" ?
and how about other kernel versions ?

mr.antooan said:
what is the "run-parts integrated in init.rc script (/etc/init.d)" ?
Click to expand...
Click to collapse
A way of running shell scripts at boot time in sequential order...
mr.antooan said:
and how about other kernel versions ?
Click to expand...
Click to collapse
What other kernel versions? Almost any custom kernel does not use perflock hence no need for perflock disable module...

Just to let you know guys... SetCPU 2.0.3 now supports perflock disable set on boot, so there is actually no need for this script any more...

Related

vorkKernel-OC/UV Kernel for CM[20111105]

Hi. The following kernel is presented to you by
vorkKernel Team:
- kiljacken
- Benee​
Click to expand...
Click to collapse
This kernel is for Cyanogenmod and Miui. *Could* be incompatible with latest kangs or nightlies (after a kernel update from CM team). No support for stock or mcr...
It's incompatible with MIUI and CM Builds before #177
New vorkKernel Twitter Bot: Here
First I want to make clear that all credit goes to aremcee/arcee/rmcc (man so many nicks ). He did an awesome job with the kernel.
I just tweaked it a little bit to my needs.
Features:
uv/oc support. OC up to 1,5GHz (With E-Peen version)
AVP/System/RAM/GPU OC with E-Peen version
1,2 Ghz for batt safe version.
Special tweaked (working!) Performance and Powersave Govenors which don't lock the freq to one level (they choose between 3-4 Freq steps)
It's even possible to set max/min clock via setcpu or CMSettings!
Voodoo sound. Thanks supercurio! So awesome
Default IO-Sched is Deadline with a special flash storage tweak
Slub allocator
tweaked CFS cpu sched (Low latency)
compiled with a tweaked toolchain (base linaro gcc - optimized for tegra2)
VFP optimizations (vfpv3-d16) and overall compiler optimizations
flags! (more below in the flag section)
A App for easy downloading and configuring. Credits to kiljacken!
Click to expand...
Click to collapse
The standard part:
I'm not responsible for melted phones or something like that...
The camera is unstable with E-Peen mode (due to AVP OC). After a reboot it needs to stabilize a few minutes (so you break it with every reboot again). Same for Bluetooth. Please don't report a problem regarding this. It's known and can't be fixed.​
Click to expand...
Click to collapse
And the source code here.
Download (Market)
Credits to kiljacken for this awesome app! You need OI File Manager for the app (Comes with CM)!
(and if you refuse to use the app - or the app is refusing to work with you: here)
Only change something, if you want to enable OC - No need to touch anything else (like govenors, schedulers)​
What are flags and how can I use them?
I recommend to use the App kiljacken made, because it's super easy for you guys. If you not want to use the app *sadpanda* then you can click this link. This is the file the app is fetching to generate the UI.
The layout is following:
Available for following device/Element style (more below)/the flag you need to add/Flag name in App/Description for general Flag/Choice name in app/actual value you need to add after flag name
If the last two points are added you first enter the flag name and than the value. For example: density230
You connect the flags with a: -
Example: -camera-ring ...
The script is configured to detect flags after vorkKernel-VERSIONNUMBER. So you can add some flags after this.
Element style
c = Checkbox
l = List you can choose things from
e = you can enter your own value​
Click to expand...
Click to collapse
Error Reporting Guide
Start with rebooting, if that doesn't help, reflash CM and then the kernel, and check again. If you're using the updater app (make sure you have the latest version), use the error report function (and describe what you're problem is). If you're not using the app, then post what flags you are using, along with what your problem is.​
Click to expand...
Click to collapse
Additionally I just want to point out that I'm not doing this as a fulltime job, so don't expect daily updates or something like that. I will try to fix a problem as fast as possible but in some cases it can take a while.
If you want to support me you can sign up on dropbox via my referral link or just push this nice thanks button .. If you want to donate you can donate to aremcee/arcee/rmcc something. I'm learning C and linux and vorkKernel is my learning project and it is a hobby for me. Anyway if you still want to support a poor student, I have a link in my signature
Thanks to:
arcee + the whole CM Team
morfic for all the avp oc tweaks and other stuff
thalamus (for saving me going crazy with the toolchain )
Erasmux
All guys that made pull request and contributed in any possible way
Donators to our project (app or kiljacken's donate link)
the android community
and a very big thanks to b3ndech0 for his buildbox.
Thanks, this is very much appreciated
This kernel is amazing! Nice work with the filename flags. It's brilliant! This way we don't have to have the same setup, but can enjoy both CM7 and the kernel.
sibbor said:
I'll try this kernel later. Will wait for CM7 getting more optimized for our devices first. 2000 Quadrant scores out of the box just don't cut it - I don't want to overclock to 1.4 GHz just to reach speeds of MCR FR14 ;-)
Planning on including any changes from kholk?
Click to expand...
Click to collapse
More things will be in it soon. And Quadrant doesn't matter. CM feels better in normal use (except a few problems but it is a really good starting point).
Benee said:
More things will be in it soon. And Quadrant doesn't matter. CM feels better in normal use (except a few problems but it is a really good starting point).
Click to expand...
Click to collapse
Yes I know it doesn't really matter. Although, generally speaking, higher scores means the software is more optimized to the hardware; framework, kernel and/or drivers.
CM7 should be able to smash the performance out of the LG stock ROM without problem...
Thanks for you kernel additions! Subscribed to this thread now so I can follow your progress.
is this kernel for a stock rom?
thanks
sibbor said:
Yes I know it doesn't really matter. Although, generally speaking, higher scores means the software is more optimized to the hardware; framework, kernel and/or drivers.
CM7 should be able to smash the performance out of the LG stock ROM without problem...
Thanks for you kernel additions! Subscribed to this thread now so I can follow your progress.
Click to expand...
Click to collapse
Nah. You can boost quadrant to oblivion via data2ext for example on desire/nexus but it didn't helped in real life performance. The sql sync disable doesn't help with real usage, but boost quadrant etc. So many things which doesn't improve real usage, boost quadrant. Like deleting your /system (pro move...).
But yeah in some parts you are right and optimizing drivers boost it too + help real use performance, so I will do this too.
vekkio said:
is this kernel for a stock rom?
thanks
Click to expand...
Click to collapse
Really? Just read the title: vorkKernel-OC/UV Kernel for CM. For Cyanogenmod. Not stock...
seems the IO from quadrant score still low, is it same sqlite hack with paul that one?
emprize said:
seems the IO from quadrant score still low, is it same sqlite hack with paul that one?
Click to expand...
Click to collapse
yup. patched cm, then compiled this and added it to update.zip.
vekkio said:
is this kernel for a stock rom?
thanks
Click to expand...
Click to collapse
Haaahaa yeah u flash away hahahahha
EDIT:- No only joking
DONT PEOPLE READ
ok, flash this kernal and using cm7 oc to 1.4, quadrant get 31xx
edit : fail to exec smartbench
Benee any chance you could add the OC support to the CM settings?
Sent from my LG O2X CM7 Nightly
svceon said:
Benee any chance you could add the OC support to the CM settings?
Sent from my LG O2X CM7 Nightly
Click to expand...
Click to collapse
Yep but this would break pimp my cpu support and I think pimp my cpu is the better deal. A easy user interface with undervolting support. Awesome! .. so no I won't add it to cm settings
Awesome OC in CM7 makes it even better
I know I'm going to get flamed for this but how do you o/c once you have flashed the kernel? when i open setCPU its already at the max 1g when i go to the CM settings there's no frequencies to select in the cpu management option
is it different on the tegra chips as opposed to qualacom?
sibbor said:
Planning on including any changes from kholk?
Click to expand...
Click to collapse
Ok if I understand the changelog from kholk correct, most of the changes are already included (don't know exactly because he didn't copied the commit names and sums the function up). One commit isn't in it because it introduced the graphic glitches. vfp3-d16 support and compiler optimization will be added with next update. Then most things are in it.
spences10 said:
I know I'm going to get flamed for this but how do you o/c once you have flashed the kernel? when i open setCPU its already at the max 1g when i go to the CM settings there's no frequencies to select in the cpu management option
is it different on the tegra chips as opposed to qualacom?
Click to expand...
Click to collapse
Is stated in the OP:
So I compiled it with uv/oc support via pimp my cpu.
Click to expand...
Click to collapse
Pimp My CPU can be downloaded from here: http://forum.xda-developers.com/showthread.php?t=1018411
spences10 said:
I know I'm going to get flamed for this but how do you o/c once you have flashed the kernel? when i open setCPU its already at the max 1g when i go to the CM settings there's no frequencies to select in the cpu management option
is it different on the tegra chips as opposed to qualacom?
Click to expand...
Click to collapse
Nah no flaming . You need pimp my cpu for it. Cpasjute did some kernel hacks to enable oc and add a uv function. That means you can undervolt without compiling the kernel again. Unfortunatly it isn't compatible with setcpu..
The kernel seems ok; I tried OC till 1200 with 50-100 UV (depending on OC).
What's very good with CM7 (and this kernel) is battery life, 30-40% more compared with Modaco ROM (till FR14).
Anybody have tried higher frequencies (1300-1400)?
Thanks a lot.
lukemo said:
The kernel seems ok; I tried OC till 1200 with 50-100 UV (depending on OC).
What's very good with CM7 (and this kernel) is battery life, 30-40% more compared with Modaco ROM (till FR14).
Anybody have tried higher frequencies (1300-1400)?
Thanks a lot.
Click to expand...
Click to collapse
I have been using this all day running 1300Mhz @ 1200mV - normal use with wifi on - 84% battery left after ap. 12 hours

[Kernel][03 Nov]Redux Kernel 0.8[Sense3.6 & 4]

This is based on l0st.prophet's kernel with added support for Nik's projectX and Virtuous Infinity Sense 4 Roms.
Features:
It's still very much in development and Sense4 versions are not in universal flash as they includes rmdisk changes,
firmware and an init.d script that Rom devs need to add to their releases first.
Test it, try it, rip it apart, fix it, break it, delete it. Pretty much do whatever you like with it.
Tell me what you think and report any issues with as much information as possible.
Includes 15 governors:
Brazilianwax
Conservative
Intellidemand
Interactive
InteractiveX
Lagfree
Lazy
Lionheart
Lulzactive
Ondemand (Default)
OndemandX
Performance
SavagedZen
Scary
SmartassV2
And all the usual goodies.
6 Schedulers:
bfq
cfq
deadline
noop
sio (Default)
vr
Overclocking, undervolting, sweep2wake, 2wcr.
Click to expand...
Click to collapse
Click to expand...
Click to collapse
Download:
Redux_0.8_Sense3.6
Redux_0.8_Sense4
Redux_0.8_Sabsa
Click to expand...
Click to collapse
Install Instructions:
S-off Users:
Those updating from previous versions of my kernel only need to flash the corresponding zip file.
Sense 3.6 (Miui) users only need to flash their desired kernel version (wipe cache and dalvik is also recommended)
[highlight]Sense 4 users who wish to change from another kernel must first install a previous version then the latest.[/highlight]
e.g.
You want to install the latest version of Redux Kernel on Sabsa Prime, replacing stock/another kernel:
Flash Redux_0.8_Sabsa.zip first, then latest Redux Kernel version, wipe cache/dalvik and reboot.
You want to install the latest version of Redux Kernel on Nik's ProjectX, replacing stock/another kernel:
Flash Redux_0.3_ProjectX.zip first, then latest Redux Kernel version, wipe cache/dalvik and reboot.
You want to install the latest version of Redux Kernel on Virtuous Infinity, replacing stock/another kernel:
Flash Redux_0.3_Virt_Infinity.zip first, then latest Redux Kernel version, wipe cache/dalvik and reboot.
S-on users:
See this thread.
Click to expand...
Click to collapse
Changelog:
Code:
[b]0.8[/b]
[list][*]Patched to 3.0.50
[*]Updated boot.img for Sabsa Prime*
[*]Re-enabled lower frequencies**
[*]Disabled cleancache and gentle fair sleepers
[*]Various fixes to touchscreen and s2w
[*]bcmdhd(Sense4 wifi) driver from OneV source***
[*]Tweaked bcmdhd to allow low wifi signals to be seen
[*]further decreased vfs_cache_pressure to 10
[*]Tweaked SIO and Deadline scedulers
[*]tun.ko now built in
[*]Various other tweaks
[/list]
[b]0.7[/b]
[list][*]Patched kernel to 3.0.46
[*]2WCR can now also use WAV encoding
[*]Tweaked CPU frequency selection
[*]Tweaked WiFi voltage
[*]Reverted CPU voltages to stock[/list]
[b]0.6[/b]
[list][*]Tuned governors
[*]Disabled swappiness
[*]Reverted 2WCR to stock
[*]Reduced sysctl_vfs_cache_pressure
[*]Optimized filesystem
[*]Reduced vm_dirty_ratio
[/list]
[b]0.5[/b]
[list][*]Reverted frequency table to stock for undervolting
[*]Slight increase to GPU RAM allocation
[*]Activated on-chip floating point unit
[*]Enabled Stochastic Fair Blue network scheduler
[*]Enabled Autogroup scheduling feature
[*]Changed default IO Scheduler to SIO[/list]
[b]0.4.1[/b]
[list][*]Fixed issue apps not installing[/list]
[b]0.4[/b]
[list]
[*]Enabled Cleancache support
[*]Enabled Tiny Preempt RCU
[*]Reduced WiFi and SD slot voltage
[*]Disabled some debugging options
[*]Added support for CPU Unaligned Access
[*]Tweaked frequency and voltage table
[*]Conservative back to default
[/list]
[B]0.3[/B]
[list]
[*]Added functioning kernel support for 2WCR (AMR Codec)
[*]Increased VM_MAX_READAHEAD to 4096kB
[*]Updated jhash to v3
[/list]
[B]0.2:[/B]
[list]
[*]Adjusted frequencies and voltages (see second post)
[*]Added SLQB slab memory allocator
[*]Added Brazilianwax OndemandX and InteractiveX governors
[*]Disabled Powersave governor (useless)
[*]Patched kernel to 3.0.43
[/list]
[B]0.1beta:[/B]
[LIST]
[*]Enabled powersave governor
[*]Wifi tethering fix
[*]CIFS, TUN, NTFS changed to seperate loadable modules
[/LIST]
*The Sabsa Prime Installer might work for other Roms (ProjectX) but at this point are untested. If you find it's working, let me know!!
**Lower frequencies are experimental and may cause issues (CPU sticking on min frequency) on some governors (interactive based) Do not lower frequency beyond the default if you do not know what you are doing.
***The new wifi drivers are a work in progress and you may notice issues on starting up wifi tethering. Current know workaround is to switch off security temporarily, switch tethering on and off and re-enable security. If someone finds a better workaround let me know. The tradeoff is a much more stable and faster connection from my testing. If this inconveniences you too much, just move to a previous version.
My github
Credits:
l0st.prophet for his amazing work on his kernel for our device so far
amidabuddha for help getting this working for our device
m0narx WiFi tethering fix
showp1984 updated broadcom source
MikeC84
oliverclaude
Code:
[B][U]Frequency and Voltage table[/U][/B]
To be updated at a later date
The minimum possible voltage has been dropped to 500mV and the minimum frequency has been dropped to 61MHz for testing purposes. They could cause unpredictable issues with your phone, so if you're not sure what you are doing, it's best to at least leave the voltages alone and only reduce the frequency to 245MHz, possibly 184. If youre comfortable testing these settings feel free to do so and report your findings. I'm using IncrediControl to adjust frequency, governor, scheduler and voltages. https://play.google.com/store/apps/details?id=com.incredicontrol
Beautiful sadly I don't have my phone yet.. but WiFi tethering fix sounds great please someone try on the project x and report
Sent from my HTC One X using Tapatalk 2
nikhil007mmus said:
Beautiful sadly I don't have my phone yet.. but WiFi tethering fix sounds great please someone try on the project x and report
Sent from my HTC One X using Tapatalk 2
Click to expand...
Click to collapse
downloading and will try
good news coming day by day
i think october will be the month of INC S
Will try tonight....arghh why im working on saturday...
Nik...its good to see the word 'reincarnation'
nikhil007mmus said:
Beautiful sadly I don't have my phone yet.. but WiFi tethering fix sounds great please someone try on the project x and report
Sent from my HTC One X using Tapatalk 2
Click to expand...
Click to collapse
Testing bro ..!! Edit : WiFi Hotspot/Thertering is working like a charm
Good to see you did it!
Now ask someone to give you Virtuous boot img and pack it the same way
Sent from my HTC Desire S
amidabuddha said:
Good to see you did it!
Now ask someone to give you Virtuous boot img and pack it the same way
Sent from my HTC Desire S
Click to expand...
Click to collapse
Lol, sounds too much like work. I gave up on doing it all through init.d scripts when I couldn't find a way to start services. I don't think it's possible unfortunately. Thanks for your help btw.
Nonverbose said:
Lol, sounds too much like work. I gave up on doing it all through init.d scripts when I couldn't find a way to start services. I don't think it's possible unfortunately. Thanks for your help btw.
Click to expand...
Click to collapse
Of course it is possible If you check my thread you will see that I support all ICS Sense (3.6/4A/4) and even MIUI goth 4 flashable zips where the only difference is in the ramdisk and you know what exactly it is
Sent from my HTC Desire S
Tests
Sent from my HTC Incredible S using xda app-developers app
amidabuddha said:
Of course it is possible If you check my thread you will see that I support all ICS Sense (3.6/4A/4) and even MIUI goth 4 flashable zips where the only difference is in the ramdisk and you know what exactly it is
Sent from my HTC Desire S
Click to expand...
Click to collapse
Congrats on your 1000th thanks. What I mean by It's not possible, is starting the ramdisk init services using init.d scripts. So creating a zImage universal flash at this stage is off the table and each sense 4 Rom needs it's own seperately created boot.img to implementthe fixes. But you're right about it being possible to have the kernel running on all the sense based roms of course. I have already studied your downloads
I have got a lot of work to do before "my" kernel has the same/similar amount of features that yours does.
2wc not work for me. Nik x
Sent from my HTC Incredible S using xda app-developers app
Lasantha said:
Tests
Sent from my HTC Incredible S using xda app-developers app
Click to expand...
Click to collapse
Are you new to benchmarking?
Nice work nonverbose Seems like more people are stepping up lately, which is nice too see
One question, does this include a 122MHz step? I like it for some reason, and l0st.prophet's didn't have it
Thanks mate
Sweet, thanks
If you can, it'd be great to see a fix for reboots when switching cell tower during a phone call
And I'd also like to see the inclusion of BadAss governor
markj338 said:
Nice work nonverbose Seems like more people are stepping up lately, which is nice too see
One question, does this include a 122MHz step? I like it for some reason, and l0st.prophet's didn't have it
Thanks mate
Click to expand...
Click to collapse
I'm actually testing a 61MHz step right now and also added more frequencies and underclocked stock voltages slightly. Looking very promising. Also planning to drop minimum voltages.
eRadicant said:
Sweet, thanks
If you can, it'd be great to see a fix for reboots when switching cell tower during a phone call
And I'd also like to see the inclusion of BadAss governor
Click to expand...
Click to collapse
I'll try to reproduce the error, but if you could provide a logcat it could be helpful. I can't promise too much but will try research the issue. I'm planning to add more governors soon so stay tuned
Nonverbose said:
I'm actually testing a 61MHz step right now and also added more frequencies and underclocked stock voltages slightly. Looking very promising. Also planning to drop minimum voltages.
Click to expand...
Click to collapse
Sounds good Never heard of such a low step for our device, hope it goes well because I am interested
Nonverbose said:
I'm actually testing a 61MHz step right now and also added more frequencies and underclocked stock voltages slightly. Looking very promising. Also planning to drop minimum voltages.
I'll try to reproduce the error, but if you could provide a logcat it could be helpful. I can't promise too much but will try research the issue. I'm planning to add more governors soon so stay tuned
Click to expand...
Click to collapse
Awesome (ran out of thanks for the day sorry lol)
It happens to me pretty much every time on the train with all sense4 roms
So it's difficult for me to provide a logcat
markj338 said:
Sounds good Never heard of such a low step for our device, hope it goes well because I am interested
Click to expand...
Click to collapse
eRadicant said:
Awesome (ran out of thanks for the day sorry lol)
It happens to me pretty much every time on the train with all sense4 roms
So it's difficult for me to provide a logcat
Click to expand...
Click to collapse
You can have a test drive if you like. Just the lower step, more steps and 500mV possible min voltage. No more governors yet.
I'll test tomorrow, its 1am here thanks
Sent from my Nexus 7

Is anyone making custom kernel now ?

We're waiting from a year.I want oc supported kernel.Will it be happen ?
Sorry for English
kilicaslan17 said:
We're waiting from a year.I want oc supported kernel.Will it be happen ?
Sorry for English
Click to expand...
Click to collapse
no, because our device is not OC capable..... some developers said, its too dangerous with our CPU.
aluk4rd said:
no, because our device is not OC capable..... some developers said, its too dangerous with our CPU.
Click to expand...
Click to collapse
Yes but mali400 gpu can be overclock so much.
kilicaslan17 said:
Yes but mali400 gpu can be overclock so much.
Click to expand...
Click to collapse
you seem very knowledgeable on the topic perhaps you should try getting into making an OC kernel
there is a thread that one of the guys started working on an OC kernel
have a search through it and see what you can do
efaustino84 said:
you seem very knowledgeable on the topic perhaps you should try getting into making an OC kernel
there is a thread that one of the guys started working on an OC kernel
have a search through it and see what you can do
Click to expand...
Click to collapse
i've changed the values in the frequency table (the highest frequency i tried to compile was CPU @ 1.1GHz and GPU @ 350mhz or 400Mhz i can remember it was around +50MHz then the stock frequency , go slow, too high values can be very dangerous) on the kernel sources but i had some truble compiling the kernel and even if i compiled the kernel the network drivers wouldnt work...(see the instructions on how to compile and how to fix the drivers in the kernel sources From SAMSUNG).
anyway i discontinued my work due to a certain "comment" i didnt like and i have no intention of start developing a public release.
Good Luck
PTGamer said:
i've changed the values in the frequency table (the highest frequency i tried to compile was CPU @ 1.1GHz and GPU @ 350mhz or 400Mhz i can remember it was around +50MHz then the stock frequency , go slow, too high values can be very dangerous) on the kernel sources but i had some truble compiling the kernel and even if i compiled the kernel the network drivers wouldnt work...(see the instructions on how to compile and how to fix the drivers in the kernel sources From SAMSUNG).
anyway i discontinued my work due to a certain "comment" i didnt like and i have no intention of start developing a public release.
Good Luck
Click to expand...
Click to collapse
Sad to see you stop developing but really just ignore them, just because someone says you suck or whatever and you stop doing it, its really not worth it

[GT-i9195][cm11] - [ROM](Feb.2016)&[kernel](ECOACTIVE & ECOPLUG)(OC/UV)(20151210)

[GT-i9195][cm11] - [ROM](Feb.2016)&[kernel](ECOACTIVE & ECOPLUG)(OC/UV)(20151210)
This is a GT-I9195 CM11 kernel highly optimized to best possible performance and energy efficiency.
It may work on Slim (confirmed), AICP (confirmed) and Carbon Rom (confirmed) as well.
It will not work on any Samsung Stock based ROM.
- built from latest avalable CM sources
- CPU OC: 1998 Mhz (light: 1782 MHz) (default and max.)
- reworked freq- tables (unique 108 MHz-steps) for fast scaling
- CPU UV: -50mv (light: -25mv) (default, adjustable)
- GPU OC: freq steps changed to 192-400-608 MHz (light: 192-400-554 MHz)
- L2 OC/UV for extra performance (stock setting is a bottleneck, especially with OC)
- improved bus scaling
- RAM UV
- adjusted msm_thermal to prevent too much thermal throttling under heavy load
- added new "ECOACTIVE" governor and set as default
- added new "ECOPLUG" hotplug driver and set as default
- added FIOPS IO Scheduler and set as default
- added some more commonly used IO schedulers
- added fast random (and enabled via init.d)
- built with official gcc 4.8 with -O3 flags
"ECOACTIVE" is the ultimate governor for lag free performance and good battery life at the same time. It's based on interactive governor. It has a special input gain including the menu, home and back buttons. Separate input gain, fullspeed and eco/screen off phases minimize the use of high frequencys whithout slowing down the device noticably. The upscaling is more agressive during the input phase (default 1s). In the following fullspeed phase (default 10s, set to 0 for unlimited) full performance is allowed. The third phase is configured for battery saving usage while reading, watching videos, music listening or when the screen is off. This ensures maximum responsiveness and best gamig experience along with best possible battery life when reading, listening to music etc.
"ECOPLUG" is an alternative hotplug driver based on AutoSMP. It works much snappier on our device than the stock msm-mpdecision. On default setting second core is down when screen is off.
Everything is fully "pretweaked".
Flash from recovery, enyoy... no need to adjust anything via init.d or app.
Dont flash this kernel if you don't know how to fix problems after flashing !
Make a backup before flashing this kernel !
The hardware parameters are adapted near to the limits of my phone. This means this kernel will not work if your devices hardware cannot handle the OC/UV.
If you are lucky you run the fastest kernel available for your phone
If your phone doesn't run with the "lombartz kernel" you may try the "lombartz light kernel" with less agressive OC/UV.
My latest pure CM11 ROM build (Feb. 2016):
https://drive.google.com/open?id=0B-1RyGtdRvCwWEVfc0ZhTTRzdXc
If you use Xposed framework you need to flash XposedFix after ROM.
regards,
lombartz
...updated.
this kernel is amazing but i have a problem when i connect the smartphone at bluetooth radio. In this case my smartphone freeze and always reboot.
sorry for my english
Hi, thanks for yor feedback Have you already checked if you have the same problem with the last official CM11 kernel from 20150105 ?
regards,
lombartz
edit: tested with my laptop as bluetooth- speaker with no problems. My actual Version is heavily tweaked at the Moment but nothing changed with audio or bluetooth.
Anyone else with bluetooth- playback issues out there ?
edit: found a possible reason for the problem. hope it's fixed in new version (see OP)
Thank you for this. Any chance to include f2fs into the kernel?
bongster said:
Thank you for this. Any chance to include f2fs into the kernel?
Click to expand...
Click to collapse
It's already included, I tested it just now with my actual Version via USB OTG a d could read and write. It should also work with the 20150212 Version.
regards,
lombartz
lombartz said:
It's already included, I tested it just now with my actual Version via USB OTG a d could read and write. It should also work with the 20150212 Version.
regards,
lombartz
Click to expand...
Click to collapse
Strange. My data and cache partition are f2fs and with the f4ktion cm11 kernel all is working well, but after installation of your kernel I'm stuck at the boot logo.
bongster said:
Strange. My data and cache partition are f2fs and with the f4ktion cm11 kernel all is working well, but after installation of your kernel I'm stuck at the boot logo.
Click to expand...
Click to collapse
Here is a Version without OC/UV or other tweaks but with all CM Updates. Its about 20% slower than the tweaked Version but more actual than the V20150212.
If this one boots your phone doesn't like my OC/UV settings...
lombartz said:
Here is a Version without OC/UV or other tweaks but with all CM Updates. Its about 20% slower than the tweaked Version but more actual than the V20150212.
If this one boots your phone doesn't like my OC/UV settings...
Click to expand...
Click to collapse
Thank you very much! I will test it and report back! If I understand it right, f2fs support is also in stock cm11 kernel?
I never tried it...
bongster said:
Thank you very much! I will test it and report back! If I understand it right, f2fs support is also in stock cm11 kernel?
I never tried it...
Click to expand...
Click to collapse
Yes.
lombartz said:
Yes.
Click to expand...
Click to collapse
No luck. I also tried flashing the latest cm11 nightly with no luck.
If I remember right I've tried the stock kernel some time ago only formatting the cache partition and this didn't work either.
20150212 working nice with latest Carbon 4.4.4
can you please add option to underclock min CPU to 162/270 MHz?
spixy said:
20150212 working nice with latest Carbon 4.4.4
can you please add option to underclock min CPU to 162/270 MHz?
Click to expand...
Click to collapse
This is a technically useless placebo feature and doesn' t save any energy.
The HFPLL has to be used to get the lower frequencys and this will eat the saved energy.
br,
lombartz
bongster said:
No luck. I also tried flashing the latest cm11 nightly with no luck.
If I remember right I've tried the stock kernel some time ago only formatting the cache partition and this didn't work either.
Click to expand...
Click to collapse
Hmm, the reason is the fstab.qcom, /cache and /data is expexted to be ext4.
Can be changed but I dont know how to allow both fs at the moment.
lombartz said:
This is a technically useless placebo feature and doesn' t save any energy.
The HFPLL has to be used to get the lower frequencys and this will eat the saved energy.
br,
lombartz
Click to expand...
Click to collapse
hi, I dont know what HFPLL is (some high frequency PLL), but I trust you
but still, is more battery efficient to hold wakelock with 162MHz than with 384, no? (see my previous post)
But on theother hand, 50mW diference between 162 and 384 MHz isnt realy so large...
spixy said:
hi, I dont know what HFPLL is (some high frequency PLL), but I trust you
but still, is more battery efficient to hold wakelock with 162MHz than with 384, no? (see my previous post)
But on theother hand, 50mW diference between 162 and 384 MHz isnt realy so large...
Click to expand...
Click to collapse
I suppose you mean 50 mV ? The lower UV limit is reached at about 384 MHz anyway.
Youre right with hfpll. Only at 384 MHz the CPU runs with pll8.
If you undervolt @ 384 manually as much as possible you will find that you cannot go noticeably lower if you clock down further.
At the Moment I am testing other tweaks that should be more effective an give some extra performance.
bongster said:
No luck. I also tried flashing the latest cm11 nightly with no luck.
If I remember right I've tried the stock kernel some time ago only formatting the cache partition and this didn't work either.
Click to expand...
Click to collapse
If you like to you can test this. But please make a full backup before because i did not test it myself. I don't want to reformat my phone for f2fs at the moment.
If it boots you are a tester for all the new changes ...
This Version will not run with ext4 /cache and /data partitions.
lombartz said:
If you like to you can test this. But please make a full backup before because i did not test it myself. I don't want to reformat my phone for f2fs at the moment.
If it boots you are a tester for all the new changes ...
This Version will not run with ext4 /cache and /data partitions.
Click to expand...
Click to collapse
Thank you very much!
After app optimisation the phone reboots and after the reboot it hangs at the Samsung logo. Only recovering the old boot image helps. Don't know if the oc is the reason.
Update:
I've tried oc with f4ction kernel and had also a reboot. I guess my CPU is not the best.
bongster said:
Thank you very much!
After app optimisation the phone reboots and after the reboot it hangs at the Samsung logo. Only recovering the old boot image helps. Don't know if the oc is the reason.
Update:
I've tried oc with f4ction kernel and had also a reboot. I guess my CPU is not the best.
Click to expand...
Click to collapse
I am sorry. Should not publish something I did not test myself...
What OC Values did you use with f4ction ?
lombartz said:
I am sorry. Should not publish something I did not test myself...
What OC Values did you use with f4ction ?
Click to expand...
Click to collapse
No problem. I'm aware of the issues that can happen.
Normally I use f4ction as it is with 50uv. For the test I oc'ed to 1998mhz.

[Kernel] Battery saver kernel

Update
Here is an easier solution that doesn't require flashing.
Please use this for any new ROMs from now on.
Old solution ONLY FOR 5.10.8 and 5.10.16
This is a stock miui kernel from 5.10.8, with modified ramdisk to limit CPU frequency.
This is a test I made for myself to see how much it helps in battery time to limit the CPU. I'm sharing this, because others might be interested in it.
You need to have MIUI 5.10.8 or 5.10.16. Older versions are not fully compatible. (Vibration not working)
So, finally we have custom kernels?
No, the proper kernel source is not available yet, the kernel image is still untouched.
Will there be new versions?
Probably, as there are other possible ramdisk tweaks that can achieve better battery life.
How much this can help?
I didn't have the time for a long test yet, I hope there are some users here who are willing to compare the results with the factory kernel.
But I can make some points:
This won't help much with standby time, as the frequency there is already much more limited.
This will help the most in situations where the CPU is the biggest drainer, like games.
Is this going to slow down my phone?
Theoretically, it will be slower. However in real life usage, I can't tell the difference.
Why wouldn't you just use an app like SetCPU?
None of those apps I tried have worked.
Can this be done without flashing a new kernel?
Yes, you only have to update the frequency in KHz in /proc/cpufreq/cpufreq_limited_max_freq_by_user.
For example (with root privileges):
Code:
echo '1500000' > /proc/cpufreq/cpufreq_limited_max_freq_by_user
However, this will reset after a reboot.
The attached file can be flashed under recoveries. TWRP tested.
Or you can extract the boot.img, and flash it in fastboot.
xm_kernel.zip will limit the CPU at 1.5GHz.
xm_kernel_1200 will do 1.2GHz.
Version 2 will do the trick Ched666 suggested, thus reducing the time spent at maxfreq.
Version 3 will not disable the touch boost, instead it will replace perfservscntbl.txt with boost to 1183MHz and 2 cores.
Reserved
Looking forward results and tests.
Flashed on 5.9.24
Work perfect. Only one problem... Vibro is gone Both Incall and feedback
Bakumatsu said:
Flashed on 5.9.24
Work perfect. Only one problem... Vibro is gone Both Incall and feedback
Click to expand...
Click to collapse
Thanks for the heads-up. You probably need 5.10.8 for that to work.
I know. I just a flashagolic
ill be testing this later..nice work buddy
Test on miui 5.10.8, it works!
And later manually change value to 1200000, works without lag. But after reboot maxfreq reset to 1500000.
Can you make the same kernel, but with maxfreq 1200000?
Xmister said:
No, the proper kernel source is not available yet, the kernel image is still untouched.
Click to expand...
Click to collapse
isn't this the kernel source code: https://github.com/BalcanGSM/MediaTek-HelioX10-Kernel
avenant said:
isn't this the kernel source code: https://github.com/BalcanGSM/MediaTek-HelioX10-Kernel
Click to expand...
Click to collapse
That is just a basic MediaTek source, it's missing drivers and configuration for our device.
I think it is more easy to control the value by implement init.d on our device.
Xmister said:
What is this?
This is a stock miui kernel from 5.10.8, with modified ramdisk to limit CPU frequency at 1.5GHz.
This is a test I made for myself to see how much it helps in battery time to limit the CPU. I'm sharing this, because others might be interested in it.
You need to have MIUI 5.10.8. Older versions are not fully compatible. (Vibration not working)
So, finally we have custom kernels?
No, the proper kernel source is not available yet, the kernel image is still untouched.
Will there be new versions?
Probably, as there are other possible ramdisk tweaks that can achieve better battery life.
How much this can help?
I didn't have the time for a long test yet, I hope there are some users here who are willing to compare the results with the factory kernel.
But I can make some points:
This won't help much with standby time, as the frequency there is already much more limited.
This will help the most in situations where the CPU is the biggest drainer, like games.
Is this going to slow down my phone?
Theoretically, it will be slower. However in real life usage, I can't tell the difference.
Why wouldn't you just use an app like SetCPU?
None of those apps I tried have worked.
Can this be done without flashing a new kernel?
Yes, you only have to update the frequency in KHz in /proc/cpufreq/cpufreq_limited_max_freq_by_user.
For example (with root privileges):
Code:
echo '1500000' > /proc/cpufreq/cpufreq_limited_max_freq_by_user
However, this will reset after a reboot.
The attached file can be flashed under recoveries. TWRP tested.
Or you can extract the boot.img, and flash it in fastboot.
Click to expand...
Click to collapse
it show to be on maximum speed on cpu spy...why?
Jo-san said:
it show to be on maximum speed on cpu spy...why?
Click to expand...
Click to collapse
Maybe the flash wasn't successful,or you flashed over something.
This is mine, the 29 sec is during boot, until it activates.
Ched666 said:
Test on miui 5.10.8, it works!
And later manually change value to 1200000, works without lag. But after reboot maxfreq reset to 1500000.
Can you make the same kernel, but with maxfreq 1200000?
Click to expand...
Click to collapse
OP updated with 1.2GHz kernel
Xmister you really do a great job. I renember I used your kernel when my phone was still HTC one x and then I changed to use iPhone 5s ,6, and dropped few weeks ago. And then I am back to android envirnoment and still flashing your modded kernel. Many thanks for your contribution.
And BTW, I think the 1200 kHz really help in get away from the battery draining problems.
4pda users found interesting thing... When touch a screen, frequency increases to maximum.
But if write 0 to the /proc/cpufreq/cpufreq_limited_by_hevc and set read only permissions, this bug disappears. And no maximum freq when touch a screen.
I tried it, and phone is much less heat, and works at a reduced freqs.
ADD: make mod to xm_kernel 1,5 GHz with this tweak
Ched666 said:
4pda users found interesting thing... When touch a screen, frequency increases to maximum.
But if write 0 to the /proc/cpufreq/cpufreq_limited_by_hevc and set read only permissions, this bug disappears. And no maximum freq when touch a screen.
I tried it, and phone is much less heat, and works at a reduced freqs.
Click to expand...
Click to collapse
This seems working too.
OP updated with V2 kernels that do this automatically.
Xmister said:
This seems working too.
OP updated with V2 kernels that do this automatically.
Click to expand...
Click to collapse
Also made modification ))
No need to touch cpufreq_limited_by_hevc.
If you want to control the touch_boost, try this way.
Find the file in system/etc/perfservscntbl.txt
CMD_SET_CPU_CORE, SCN_APP_TOUCH is to control how many cores when touch boost.
CMD_SET_CPU_FREQ, SCN_APP_TOUCH is to set the value when touch boost.
Save after modify and reboot your device.
By @Ched6666 's way is totally disable touch_boost
v2 is compatible with 5.10.16 release?

Categories

Resources