FORUMS
Remove All Ads from XDA

[Kernel][Grouper|Tilapia][F2FS][15Sep2016 Android-7.0.0_r6 test build]DC-Kernel

1,634 posts
Thanks Meter: 5,399
 
By daniel_hk, Recognized Contributor on 8th February 2016, 06:27 AM
Post Reply Email Thread
Although I'd already uploaded the source to github, I was asked a few times to release the kernel of my OmniROM6 build. Frankly, I only contributed a small part of it. Most of the codes are here and there from other devices and/or developers. I just modified a few and patched a few.
This week, I was packaging a kernel for my other devices. Thanks to the AIK (Android image Kitchen) by @osm0sis, it make my life much easier. I think spending a few more minutes for my Nexus 7 is not a bad idea. I don't know if it would work for your existing ROM. I only have three success reports. Fail and success reports, suggestions and comments are welcome.
This might just another one time deal as my TWRP. I'll make this thread simple. Anyway, it's done.
Release Notes:
2016/9/15: Finally a long holiday come. It's about time we migrated to Nougat. Most of the custom ROMs are busy for their first release. In the meantime, I may consolidate the kernel and device trees. After struggling for a few hours, I finally stop the sepolicy from denials for the first time.... The test AOSP-N builds are unloading now. See post#184 for details.
History

2016/8/9: PerformanceControl is update to Drawer view UI now. Enable native D2TW interface for other ROMs (** How to enable it is in the Theory section **)
Click image for larger version

Name:	Screenshot_20160809-204453.png
Views:	2684
Size:	50.3 KB
ID:	3837552
2016/6/7: Android N preview2 zip version was uploaded to experimental pool.
2016/6/5: Android N preview2 testing boot and system image in experimental pool. Read post #135 for detail.
2016/3/30: Add the power HAL with frequency adjustments and set feature support.
2016/3/18: Upload a test kernel to experimental pool.
2016/3/14: Bug fix in PerformanceControl.apk and the final code for kexec patch.
2016/3/13: Add the experimental pool for the testing builds.
2016/2/29: Seems it is not a one time thing now so I added the Change log section. The initial commit of Tegra3 Support is added to the PerformanceControl apk. In addition, I also include the Nexus 7 support in the Tools page. Wiping caches and flashing images are working for Nexus 7 now. A bug in Set on Boot is also fixed.
2016/2/16: Seems most of the fellow ROM builders had included the rotation patch in their kernel. I have no problem spending another few more minutes for the user oriented request. I prepared another zip. The only difference between 0214 and 0216 zip is 0216 included the rotation patch. If anyone have problem with rotation stopped after long deep sleep, you may try the 0216 version.
2016/2/14: This is not an update. There are requests for LP and KK ROMs. I added the fstab for those earlier versions. The script was modified. It will check the /system/build.prop for Android version and copy the corresponding fstab to the ramdisk. cheers!

Theory:
The source is from the stock AOSP kernel (3.1.10) for grouper. The kernel binary is more or less the same for most of the ROMs posted. The major difference would be the ramdisk. With this in mind, I just replace the kernel binary and keep the existing ramdisk. The existing kernel might not have F2FS support so I replace the File System Table (fstab.grouper) too.
Even though this is from my OmniROM6 (MM) ROM, it might also work for LP or earlier. There are two default fstab (MM and LP) inside. For those who want to use their own, you may replace the file /data/AIK-mobile/XX/fstab.grouper inside the zip. Where XX=MM for ROMs from 6.0.0, XX=LP for ROMs before 6.0.0 (LP and KK, JB not tested)
To ROM builders:
Quote:

If you want to enable the native DT2W in Display settings, please include the following lines in:
device/asus/grouper/overlay/frameworks/base/core/res/res/values/config.xml
You may enjoy the DT2W feature now

Code:
    <!-- Whether device supports double tap to wake -->
    <bool name="config_supportDoubleTapWake">true</bool>

Reported ROMs:
Reported Working
MM: Android 6 AOSP on Grouper, CyanogenMod 13 , Pure Nexus, AICP, VRToxin, OctOs
LP: CARBON-LP, Dirty Unicorns 5.1.1, ResurrectionRemix LP
KK: SlimKat 9.1
Reported not Working
MM: Android MarshMallow Pure AOSP

Change log:
Code:
2016/8/9
 - kernel: adjustments voltage tables
 - PerformanceControl: version 2.1.6, Drawer view UI
 - PerformanceControl: Support CM-13.0's native root access
2016/3/30
 - kernel: DT2W fix the power when resume
 - kernel: DT2W adjustment
 - PerformanceControl: Fix a potential crash at first launch
 - PerformanceControl: Enable the CPU Governor settings if supported
 - Power HAL: adjust to the O/C frequencies
 - Power HAL: Add set feature support for AOSP native DT2W settings (planning)
2016/3/14
 - kernel: Add zRAM support
 - kernel: Add kexec-patch for MultiROM
 - PerformanceControl: Fix the crash in Advance > Highend graphics
2016/2/29
 - kernel: Add custom panel backlight control
 - PerformanceControl: (v2.1.5) Add Tegra3 support, GPU, voltage and backlight settings.
 - PerformanceControl: Add Nexus 7 Tools. (wipe caches, flash kernel/recovery, etc.)
2016/2/16
 - kernel: Include the Rotation fix
2016/2/14
 - Add detection of Android version to script
 - Include the fstab for LP and earlier
2016/2/8
 - kernel:initial release
 - PerformanceControl: (v2.1.4) from Exynos4
 - PerformanceControl: DT2W, CPU settings
Features:
Kernel
  1. Build with gcc 4.9
  2. F2FS support
  3. OC for CPU, LP
  4. OC for GPU
  5. Voltage Control (for CPU, GPU etc.)
  6. DT2W support with bound and duration sysfs fine tune (disabled by default)
  7. Retrying for i2c processes.
  8. UID_CPUTIME support with power table from Tegra spec.
  9. Add wakelock timeout for a few drivers (xmm_power, etc.)
 10. Add journal_async_commit flag to ext4 /cache and /data
 11. Included rotation patch (from 20160216)
 12. Panel min. and max. backlight control
 13. zRAM support
 14. kexec patch for MultiROM (from 20160314)
PerformanceControl Apk
 1. CPU: freq. and voltage settings
 2. Tegra3 settings: GPU freq., various voltages, backlight, etc.
 3. Memory: KSM, OOM and VM (zRAM testing) settings
 4. Advanced: Ahead buffer, I/O schedulers, DT2W settings, etc. (when available)
 5. Tools: Wiping, flashing images, optimizations, shell commands at start, etc.
 6. Informations: Battery, Memory, System, storage, etc.
 7. Draw view UI
 8. Compatible with CM-13.0 (Slim6 etc.) native root access.

Download:
 Host: Android File Host mirror: 百度网盘
 Experimental
 Note: I only tested it in TWRP.
     Some features required ROOT access.
     Extra settings can be found in the Included PerformanceControl
     Root would be preserved for systemless SuperSU from @Chainfire.

Know issues:
 1. D2TW sometimes not started at the first suspend after reboot.
 2. May be more....

Sources:
Sources of the kernel and the PerformanceControl apk included is in my github

Credits:
 ** The Android Image kitchen by @osm0sis
 ** M-kernel by @Metallice
 ** All those who donate and/or help the developers. Giving us the resources and reason to carry on.

Donations:


The Following 50 Users Say Thank You to daniel_hk For This Useful Post: [ View ] Gift daniel_hk Ad-Free
 
 
9th February 2016, 07:54 AM |#2  
Portgas D. Ace's Avatar
Recognized Contributor
Flag Bergisches Land
Thanks Meter: 3,015
 
More
Quote:
Originally Posted by daniel_hk

Even though this is from my Marshmallow ROM, it might also work for LP or earlier. The only file required to modified would be the fstab. For those who want to try, you may replace the file /data/AIK-mobile/fstab.grouper inside the zip.

What exactly does one have to modify in the fstab.grouper file to make it compatible with LP? Or is there a pre-defined file that can replace the current one for MM present in the .zip file?
9th February 2016, 03:37 PM |#3  
daniel_hk's Avatar
OP Recognized Contributor
Flag Hong Kong
Thanks Meter: 5,399
 
Donate to Me
More
Quote:
Originally Posted by orville87

What exactly does one have to modify in the fstab.grouper file to make it compatible with LP? Or is there a pre-defined file that can replace the current one for MM present in the .zip file?

The only difference between MM and LP would be the OTG line.
Usually, the one found in cm-12.1 would work for all LP. Unzip this one fstab.grouper.zip

I have changed a few flags. Other developers might have other changes too.
The one inside your LP ROM would be better for your ROM. You may copy it out from root directory after start up.
If there is no F2FS support in your ROM's fstab,
1. Let say the one inside my zip is the base fstab.
2. the one in you LP ROM is target fstab.
3. copy the 4 lines with /data and /cache from the base fstab to the target fstab.
4. replace the base fstab with the target fstab inside my zip.
That's all
note:Those lines are quite long and might extended to a few lines.

Good luck!

Edit: Starting from version 20160214, there are two folders MM and LP which correspondinng to ROMs from or before Android 6.0.0. There is a default fstab inside each. For those who want to replace it with their fstab. It should be put inside the corresponding folder.
The Following 3 Users Say Thank You to daniel_hk For This Useful Post: [ View ] Gift daniel_hk Ad-Free
9th February 2016, 03:47 PM |#4  
Senior Member
Thanks Meter: 35
 
More
Which changes would be necessary to use your kernel with KK/4.4.4 ?
10th February 2016, 04:39 AM |#5  
daniel_hk's Avatar
OP Recognized Contributor
Flag Hong Kong
Thanks Meter: 5,399
 
Donate to Me
More
Quote:
Originally Posted by mklmkl

Which changes would be necessary to use your kernel with KK/4.4.4 ?

Same as the above in post#3.
10th February 2016, 11:34 PM |#6  
adstraylight's Avatar
Senior Member
Thanks Meter: 1,079
 
More
There is a fix for auto rotate implemented in other grouper kernels that appears to be missing from this one, but it's nice to have the clock speeds to play with
11th February 2016, 12:27 AM |#7  
Senior Member
Thanks Meter: 35
 
More
Thanks! I'll test it tomorrow.

---------- Post added at 01:27 AM ---------- Previous post was at 01:04 AM ----------

Booted on KK/4.4.4! Will go on testing!
But where to find the performance apk? Or do I have to compile it from source?
Thanks!
11th February 2016, 01:02 AM |#8  
daniel_hk's Avatar
OP Recognized Contributor
Flag Hong Kong
Thanks Meter: 5,399
 
Donate to Me
More
Quote:
Originally Posted by adstraylight

There is a fix for auto rotate implemented in other grouper kernels that appears to be missing from this one, but it's nice to have the clock speeds to play with

The audio and rotation fix are not in the kernel. I did it in the platform. Ask your ROM's builder for detail.
Quote:
Originally Posted by mklmkl

Thanks! I'll test it tomorrow.

---------- Post added at 01:27 AM ---------- Previous post was at 01:04 AM ----------

Booted on KK/4.4.4! Will go on testing!
But where to find the performance apk? Or do I have to compile it from source?
Thanks!

The apk is in the system. It is in /system/apps/PerformanceControl/PerformanceControl.apk
I forgot if KK's system apps was inside a folder. If not, move it out.

Good luck
The Following User Says Thank You to daniel_hk For This Useful Post: [ View ] Gift daniel_hk Ad-Free
11th February 2016, 01:19 AM |#9  
Senior Member
Thanks Meter: 35
 
More
Found & installed -> works!
GPU is (obviously) for a different HW, correct?
11th February 2016, 01:58 AM |#10  
daniel_hk's Avatar
OP Recognized Contributor
Flag Hong Kong
Thanks Meter: 5,399
 
Donate to Me
More
Quote:
Originally Posted by mklmkl

Found & installed -> works!
GPU is (obviously) for a different HW, correct?

Yeah. The apk was for my other devices. There are apks like trickster mod can modify Tegra GPU. I seldom change it in my tilapia so I didn't add the extra codes. (lazy too )
I included this apk because there is settings for DT2W. The sources are in my github. It would be quite easy for others to port their own.

EDIT:Can you tell me which ROM you are using?
11th February 2016, 07:14 AM |#11  
Senior Member
Thanks Meter: 35
 
More
Unofficial SlimKat 9.1 (see: http://forum.xda-developers.com/show....php?t=3214142)

Many thanks for your effort!
The Following User Says Thank You to mklmkl For This Useful Post: [ View ] Gift mklmkl Ad-Free
Post Reply Subscribe to Thread

Tags
grouper, kernel, nexus 7 (2012), tilapia

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

Advanced Search
Display Modes