FORUMS
Remove All Ads from XDA

[KERNEL][AOSP] Incredikernel (Chad+Tiny) - 11/30/2013

9,321 posts
Thanks Meter: 5,073
 
By tiny4579, Inactive Recognized Developer on 22nd March 2012, 12:30 AM
Post Reply Email Thread
Current Release: 12/20/2012(JB)/10/03/2012(GB+ICS)
Important, Please read: There are now two kernel versions starting with 8/10/2012 release, one for GB+limited ICS(no HWA) support and another for the ICS branch with HWA. Changes will be loggged separately for each kernel type. If you see no changelogs specifically for that type, then there's no release made. For example, 8/10/12 for GB is a continuation of the 3/21 release with none of the post-3/21 kernel ICS changes made.
Update 9/21/12: As of 9/21/12, jellybean is officially supported with the JB specific kernels.


First of all, I started this thread to make commenting and tracking easier for the incredikernel releases following Chad's latest release (8/15/2011).

I also wanted to make a distinction between Chad's initial kernels and the ones I've updated since that release and this is one way to do it. Initially I didn't want to do that but now I regretted not splitting sooner.

If you want the changelog for anything prior to my first kernel please refer to:

Chad's Incredikernel thread

Changelog:

11/30/2013 JB 4.3
  • Android 4.3 support
  • synced with updates from Android 4.3 Evervolv kernel

04/25/2013 ICS Sense+JB 4.2
  • dynamic fsync control
  • WiFi driver updates
  • Interactive governor updates - see Tinykernel
  • Entropy Tweaks
  • Netfilter updates
  • New sysfs location for fast charge for broader app compatibility - still compatible with latest incredicontrol
  • FUSE filesystem support

12/20/2012 JB 4.2 ONLY
  • add back governors that were removed in 12/15

12/15/2012 JB 4.2 ONLY
  • enabled UHID support
  • updated msm_fb for 4.2

12/11/2012 JB ONLY
  • cpufreq: enable overclocking of 1.15Ghz and 1.19Ghz
  • numerous interactive and ondemand governor tweaks
  • cpufreq: send uevent when governor changes
  • ondemand: boost pulse for JB's powerHAL

10/11/2012 JB ONLY
  • defconfig: several config changes to fix data usage not working

10/06/2012 JB ONLY
  • defconfig: enable conservative governor by request

10/03/2012 ICS+JB+GB
  • defconfig: remove rarely used governors and set max frequency to preventing booting higher than 998mhz
  • lower default hispeed_freq to 614Mhz
  • cpufreq: interactive: always limit initial speed bump to hispeed_freq

09/21/2012 ICS+JB+GB
  • ALL: New Interactive governor
  • ALL: Built with GCC 4.6 toolchain from Google
  • GB: interactive governor tweaked for battery
  • ICS+JB: interactive governor tweaked for butter
  • JB: genlock patched for JB support
  • JB: new wifi driver for compatibility with JB ROMs

08/11/2012 ICS+GB
  • KSM wasn't enabled as it should have been in the last build - fixed that - also nothing needs to be done to enable it on GB as it's on by default

08/10/2012 ICS ONLY
  • fixed data usage features for ICS
  • added mamarley's fastcharge USB patch to enable fastcharge without needing to unplug the charger
  • enabled KSM (Kernel Samepage Merging) - still need to enable in CM settings

08/10/2012 ICS+GB
  • added mamarley's fastcharge USB patch to enable fastcharge without needing to unplug the charger

07/07/2012 ICS ONLY
  • Merged in multiple driver updates to support HWA (chad0989)
  • Updated adreno kernel drivers to latest
  • added xtqta_guid - for ICS' data usage feature, also seems to have resolved stability issues
  • Added lazy CPU governor
  • Added back intellidemand

03/21/2012 ICS+GB
  • Added lazy CPU governor

02/26/2012 ICS+GB
  • Smartassv2 default governor for sure - doesn't override ramdisk settings though
  • new governor lagfree - balance between ondemand and interactive
  • new I/O scheduler SIO
  • tweaked deadline for better performance
  • removed CFQ/BFQ schedulers and smartass, conservative, and interactive govenors (still have interactiveX and smartassv2)

01/03/2012 ICS+GB
  • Tweak intellidemand and interactiveX governors for battery life
  • Add ZRAM and swap support and add script to toggle ZRAM - see bottom of OP for more info
  • SmartassV2 default governor again

12/26/2011 ICS+GB
  • Added faux123's intellidemand governor (thanks faux123!)
  • Added imoseyon's interactiveX governor (thanks imoseyon!)
  • Works on GB and ICS currently
  • interactiveX may not play nicely with ICS so intellidemand is default
  • Conservative is disabled, let me know if you need it back

12/08/2011 (Chad) ICS+GB
  • Added ICS support (limited)

11/27/2011 GB
  • Use ondemand, performance, and conservative governors from the Android Linux 3.0 kernel
  • Set minimum voltage back to 800 as the voltages will not go below 800 anyway. Anything lower is placebo effect. This is a hardware limitation.

11/14/2011 GB
  • Update OJ driver
  • BT fix for newer CM nightlies
  • WIFI module updates
  • Update and re-add BFQ scheduler as well as disable deadline
  • Ondemand is back
  • Fixes/Tweaks to ondemand and interactive

10/08/2011 GB
  • Adjusted smartassV2 parameters for 1GHz processor (originally for 500Mhz device)

10/01/2011 GB
  • Set smartassv2 to default governor

09/30/2011 GB
  • Added SmartassV2 governor

Current CPU governors as of the latest release:
  • SmartassV2
  • Ondemand
  • Interactive
  • Lagfree
  • Lazy

Technical doc on CPU governors (most of the ones in this kernel anyway)
https://raw.github.com/tiny4579/andr.../governors.txt

Update: 11/30/13 - removed link to incredikernel.com as the site has no content - fully on goo.im now

http://goo.im/devs/tiny4579/inc/kernels

Kernel Source

https://github.com/tiny4579/android_kernel_common

Here are a couple notes if you want to build this kernel from source:

Jellybean kernel branch is android-2.6.38-incredikernel-jb.
ICS kernel branch is android-2.6.38-incredikernel-ics.
Gingerbread kernel branch is android-2.6.38-incredikernel.
The config for the kernel is in arch/arm/configs/incrediblec-incredikernel_defconfig. If you want to switch branches I recommend doing a make incrediblec-incredikernel_defconfig after checking out that branch.
I use the GCC 4.4.3 toolchain for this kernel due to GCC 4.6 causing build issues.
The Following 30 Users Say Thank You to tiny4579 For This Useful Post: [ View ] Gift tiny4579 Ad-Free
 
 
22nd March 2012, 12:30 AM |#2  
OP Inactive Recognized Developer
Thanks Meter: 5,073
 
More
Frequently Asked Questions

Some key differences between smartass and smartassv2 so users can decide which they prefer and learn a bit more about the differences:

Smartass
1. Screen off profile built in maxed at 384mhz.
2. Wakeup frequency is 998mhz.
3. Min screen on is 245mhz.
4. Improved by Chad to run better on our devices.
5. Purely load based, no ideal value.

Smartassv2
1. This is the same exact governor in Erasmux's Nexus One kernel (github.com/erasmux/n1-kernel)
2. Ideal wake frequency is 768 (also default that can be changed).
3. Screen on min is actually 128mhz).
4. No screen off profile.
5. Ideal sleep frequency 245mhz.
6. Improved upon from erasmux's version, not Chad's.

Basically the smartassv2 ideal wake frequency allows the phone to favor a certain speed to attempt to save battery life. It can still go above ideal wake and below ideal sleep so there's no caps on max and min while awake or sleep.

Some tips/info on various governors:

Smartass/smartassv2/interactive:
Use 128 min so the governor can scale as it needs to. Max speed I'd recommend at least 768Mhz.

Ondemand:
Try 128 min and if it lags use 245 min. Max speed I'd recommend at least 768Mhz.

Performance:
Only recommended for benchmarks but speed will always run at max.

InteractiveX:
Same as interactive except it has an auto screen off set to the min. Ideal with 245 min in setcpu but try 128 for battery life but it you have wake lag then set to 245.

Intellidemand:
Based on ondemand with a built in screen off. Any speed settings should be fine.

Interactive:
Some new features with this one. Starting with 9/21/12 release I am using the interactive kernel from Google which features a new kernel option called input_boost.

It is off by default but can be enabled by writing a 1 to /sys/devices/system/cpu/cpufreq/interactive/input_boost. Also there is another parameter for interactive called hispeed_freq in the same location. The hispeed_freq is where the governor jumps to first. Hispeed_freq by default in 10/3/12 is 614400 to help save battery. In the older interactive governor there was a maxspeed freq which meant the governor was a bit jumpier to the max speed. This should be a good blend of performance and battery.

Lagfree:
Based on ondemand but with a softer CPU scaling which should help with battery life. It also seems to be very responsive (starting with 2/26)

Lazy:
Based on ondemand as well (Ezekeel is the developer of this governor). I cannot explain this too well but its apparent behavior seems to be to switch between low and high frequencies pretty evenly.
A note from Ezekeel on this governor:
"Thus I took the ondemand governor and implemented an additional parameter 'min_timeinstate' defining a minimum time the CPU will stay in a certain frequency state before it will be allowed to switch frequencies again. This way one can have a fine grained polling by setting the sampling_rate to a low value without running into problems with these fast frequency changes.

I did some extensive testing with a sampling_rate of 10000, min_timeinstate of 40000 and up_threshold of 90 and FLAC, mp3 and video playback all seem to work flawlessly. So it seems the root of the problem was indeed that the CPU does not handle fast frequency changes well.

I tested several apps and games and so far I have not found anything that this governor cannot handle. Thus I dare to say that it seems to be the superior choice over ondemand."


ZRAM, what is it and how to I add it? (starting officially with 12/31/11)
If you are familiar with swap space in linux or virtual memory in Windows it is a similar concept. Except instead of using the hard drive as swap space it compresses swap space in RAM for faster access times than conventional swap. This will also wear out our storage memory less than typical swapping.

Enable ZRAM is simple thanks to a script built by imoseyon which is provided in the kernel zip file. To enable, use adb shell or download a terminal app and run zram enable. This will persist across reboots (if init.d is setup in your ROM) so if you don't want it anymore run zram disable and it will remove the bootscript and deactivate it.

You need to have root privileges to enable/disable zram. Run the su command in terminal emulator to request root.
The Following 5 Users Say Thank You to tiny4579 For This Useful Post: [ View ] Gift tiny4579 Ad-Free
22nd March 2012, 01:39 AM |#3  
Senior Member
Thanks Meter: 38
 
More
I was wondering when lazy was gonna make it's way to aosp...

Sent from my ADR6300 using xda premium
22nd March 2012, 01:42 AM |#4  
OP Inactive Recognized Developer
Thanks Meter: 5,073
 
More
Quote:
Originally Posted by OMG_VTEC

I was wondering when lazy was gonna make it's way to aosp...

Sent from my ADR6300 using xda premium

The name of the new governor says it all....













You just answered your own question. I took my own sweet time releasing it. It was built like 2 weeks ago. I was being lazy.
22nd March 2012, 01:44 AM |#5  
jlokos's Avatar
Senior Member
Flag Willamette Valley
Thanks Meter: 615
 
More
Quote:
Originally Posted by tiny4579

Scripts/Mods if I think of something...

Tiny, this new thread is great, as is the work you and Chad have done on these kernels. Keep up the great work. Thank you.
22nd March 2012, 01:47 AM |#6  
OP Inactive Recognized Developer
Thanks Meter: 5,073
 
More
Quote:
Originally Posted by jlokos

Tiny, this new thread is great, as is the work you and Chad have done on these kernels. Keep up the great work. Thank you.

Yeah, the old way was sloppy. Tired of it. I think this thread is cleaner than the sense one and it took me less time to write it.
The Following 2 Users Say Thank You to tiny4579 For This Useful Post: [ View ] Gift tiny4579 Ad-Free
22nd March 2012, 01:58 AM |#7  
Senior Member
Thanks Meter: 2,075
 
More
To help out users (and document the probable future deviation), how about adding a tag to each kernel stating whether it works with froyo (which I believe is none), GB, ICS, or a multiple (which is only the last couple or so, I think).

Great work, by the way.
22nd March 2012, 03:12 AM |#8  
OP Inactive Recognized Developer
Thanks Meter: 5,073
 
More
Quote:
Originally Posted by PonsAsinorem

To help out users (and document the probable future deviation), how about adding a tag to each kernel stating whether it works with froyo (which I believe is none), GB, ICS, or a multiple (which is only the last couple or so, I think).

Great work, by the way.

Done. 10char
The Following User Says Thank You to tiny4579 For This Useful Post: [ View ] Gift tiny4579 Ad-Free
22nd March 2012, 04:02 AM |#9  
Senior Member
Flag New Jerz
Thanks Meter: 106
 
More
Nice.....great work to you and Chad. Thanks.

Sent from my ADR6300 using Tapatalk
22nd March 2012, 04:02 AM |#10  
chocolate8175's Avatar
Senior Member
Flag Cleveland, Ohio
Thanks Meter: 49
 
More
Thanks for the thread tiny, I was wondering what the benefits of the lazy governor were
23rd March 2012, 12:13 AM |#11  
Member
Thanks Meter: 7
 
More
Smile
I'm running my CPU at 128/806 Mhz with Lazy and it's been nice and smooth all day. Battery life has been as good or better than SA2 for me.

It also seemed to drop my ping time and increase the throughput in SpeedTest. I was getting really discouraged with ICS and >400ms ping times but I'm attributing the Lazy governor with right around 100ms ping and smoother data rates. When I switch back to the SA2 governor that I've been running for months data gets choppy again. The system itself seems smooth enough with SA2 but data has been very choppy.

Thank you to all you great developers for all your time, effort, and hard work. We really do appreciate it.
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes