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

Search This thread

daniel_hk

Inactive Recognized Contributor
Nov 12, 2012
1,634
5,344
Hong Kong
Realme X2
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 **)
Screenshot_20160809-204453.png
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: :confused:
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:
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
:D
Code:
    <!-- Whether device supports double tap to wake -->
    <bool name="config_supportDoubleTapWake">true</bool>
Reported ROMs:
Reported Working :victory:
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:
[COLOR="Blue"]2016/8/9[/COLOR]
 - kernel: adjustments voltage tables
 - PerformanceControl: version 2.1.6, Drawer view UI
 - PerformanceControl: Support CM-13.0's native root access
[COLOR="Blue"]2016/3/30[/COLOR]
 - 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)
[COLOR="Blue"]2016/3/14[/COLOR]
 - kernel: Add zRAM support
 - kernel: Add kexec-patch for MultiROM
 - PerformanceControl: Fix the crash in Advance > Highend graphics
[COLOR="Blue"]2016/2/29[/COLOR]
 - 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.)
[COLOR="Blue"]2016/2/16[/COLOR]
 - kernel: Include the Rotation fix
[COLOR="Blue"]2016/2/14[/COLOR]
 - Add detection of Android version to script
 - Include the fstab for LP and earlier
[COLOR="Blue"]2016/2/8[/COLOR]
 - kernel:initial release
 - PerformanceControl: (v2.1.4) from Exynos4
 - PerformanceControl: DT2W, CPU settings
Features: :cowboy:
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: :highfive:
 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: :cool:
Sources of the kernel and the PerformanceControl apk included is in my github

Credits: :good:
 ** 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: :angel:
 
Last edited:

Portgas D. Ace

Inactive Recognized Contributor
Jun 12, 2014
4,354
3,161
Bergisches Land
Nexus 7
Google Pixel 6
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?
 
  • Like
Reactions: lucargo

daniel_hk

Inactive Recognized Contributor
Nov 12, 2012
1,634
5,344
Hong Kong
Realme X2
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 View attachment 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.
 
Last edited:

adstraylight

Senior Member
May 17, 2010
1,654
1,098
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 :good:
 

mklmkl

Senior Member
Mar 7, 2014
124
34
Huawei Nexus 6P
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!
 

daniel_hk

Inactive Recognized Contributor
Nov 12, 2012
1,634
5,344
Hong Kong
Realme X2
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 :good:
The audio and rotation fix are not in the kernel. I did it in the platform. Ask your ROM's builder for detail.
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
 
Last edited:
  • Like
Reactions: perf3cts

daniel_hk

Inactive Recognized Contributor
Nov 12, 2012
1,634
5,344
Hong Kong
Realme X2
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 :D)
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?
 
Last edited:

daniel_hk

Inactive Recognized Contributor
Nov 12, 2012
1,634
5,344
Hong Kong
Realme X2
@daniel_hk regarding screen rotation, I suppose you missed this commit. It's about handling the timer values in MM. I first handled this issue in frameworks/base, too, but the kernel patch is more easy to maintain.
I saw it in manta's commit too.

Since I'm maintaining a few devices, I want to make it common. I did it in the platform. Same source would work for the three kernel sources I'm working on.
 
Last edited:
  • Like
Reactions: AndDiSa

Sage

Senior Member
Dec 12, 2005
1,775
427
AU
Xiaomi Mi 11
Hell yes! Finally a OC kernel for the Nexus 7 on MM! I have been trying to make one for hours though couldnt work it out! Can i beg for a commit to be added so us Tiapila users can use it too?

https://github.com/jfmcbrayer/grouper-kernel/commit/3f0c118b4ebc45045049e7e01c6deae5bdddb243

This commit stops the 3G wakelock that cripples the battery life on all Tiapila devices on version 5.0 and above. Battery life is like 20 hours even with no screentime.

Pretty please! :) This commit is already included on both CM13 and Pure Nexus Kernels for Grouper though those Kernels don't have OC! :) :)

Thanks very much.
 

daniel_hk

Inactive Recognized Contributor
Nov 12, 2012
1,634
5,344
Hong Kong
Realme X2
Hell yes! Finally a OC kernel for the Nexus 7 on MM! I have been trying to make one for hours though couldnt work it out! Can i beg for a commit to be added so us Tiapila users can use it too?

https://github.com/jfmcbrayer/grouper-kernel/commit/3f0c118b4ebc45045049e7e01c6deae5bdddb243

This commit stops the 3G wakelock that cripples the battery life on all Tiapila devices on version 5.0 and above. Battery life is like 20 hours even with no screentime.

Pretty please! :) This commit is already included on both CM13 and Pure Nexus Kernels for Grouper though those Kernels don't have OC! :) :)

Thanks very much.
Why beg for the things already there? If you read my rather short thread. It was already there. Grouper and Tilapia share the same kernel. I already implemented it in the early stage of my Omni6 months ago...
 
  • Like
Reactions: atlharp

Top Liked Posts

  • There are no posts matching your filters.
  • 51
    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 **)
    Screenshot_20160809-204453.png
    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: :confused:
    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:
    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
    :D
    Code:
        <!-- Whether device supports double tap to wake -->
        <bool name="config_supportDoubleTapWake">true</bool>
    Reported ROMs:
    Reported Working :victory:
    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:
    [COLOR="Blue"]2016/8/9[/COLOR]
     - kernel: adjustments voltage tables
     - PerformanceControl: version 2.1.6, Drawer view UI
     - PerformanceControl: Support CM-13.0's native root access
    [COLOR="Blue"]2016/3/30[/COLOR]
     - 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)
    [COLOR="Blue"]2016/3/14[/COLOR]
     - kernel: Add zRAM support
     - kernel: Add kexec-patch for MultiROM
     - PerformanceControl: Fix the crash in Advance > Highend graphics
    [COLOR="Blue"]2016/2/29[/COLOR]
     - 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.)
    [COLOR="Blue"]2016/2/16[/COLOR]
     - kernel: Include the Rotation fix
    [COLOR="Blue"]2016/2/14[/COLOR]
     - Add detection of Android version to script
     - Include the fstab for LP and earlier
    [COLOR="Blue"]2016/2/8[/COLOR]
     - kernel:initial release
     - PerformanceControl: (v2.1.4) from Exynos4
     - PerformanceControl: DT2W, CPU settings
    Features: :cowboy:
    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: :highfive:
     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: :cool:
    Sources of the kernel and the PerformanceControl apk included is in my github

    Credits: :good:
     ** 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: :angel:
    8
    New DC-kernel (20160809) is out now, Cheers! :D
    Performance Control is upgrade to 2.1.6 with Drawer view UI.
    Native DT2W interface (MM's new featrue) is open to other ROMs now.
    7
    @daniel_hk I am using shantur's version of this kernel and just replaced your boot.img in your latest zip. I am also using power event manager so i can use my n7 as a dashboard computer in my car. I am running into an issue where upon fist install of the kernel, I use trickster mod and notice all 4 cores are being used. After a reboot, I only notice 1 core is available and my performance is slow. Any ideas on things I can check?

    The setting in Trickster mod is not really a setting. It only shows the current state at the point you set it. If you swipe the screen quickly a few times, you might change it to 2-4. Even if you set it to 4, It would change itself afterwards. ;)

    OK, it's about time we tried Nougat again.
    The long holiday allow me to try the latest Android-7.0.0_r6. I finally fixed all the sepolicy conflicts. Hoping the kernel and device trees are ready the the up coming ROMs... :D
    I squeeze the final system size to 3xxM which allow installing the pico and nano (might be micro) Gapps.
    The working test builds for Gouper and Tilapia are here : https://www.androidfilehost.com/?w=files&flid=112750
    PerformanceControl is included but it requires Root (with the latest SuperSU) to work.
    If you have installed Gapps, you need to manually assign the permissions (Location and storage are essential) to Google Play Service.
    In: Settings > Apps > (show system apps in menu) > Select "Google Play Service" > permissions
    OpenGapps and BaNK's Gapps for 7 are tested.
    Cheers! :D
    6
    Android N Preview2 Test images

    The Android N preview2 boot and system images were uploaded to experimental pool. :highfive:
    As this is a test for the kernel. Only the essential hardware drivers (Display, Touch screen, wifi, etc.) are fixed. Try at your own risk and BACKUP first!
    Preparing the system, downloading and fixing a few things already spent a lot of time. This is for testing the kernel so I didn't spend time to repack to OTA. PerformanceControl app is patched and tested.
    To flash:
    boot into bootloader (fastboot)
    Code:
    Type:
    fastboot flash boot n-preview2-boot.img
    fastboot flash system n-preview2-system.img
    Boot into recovery to do a factory reset before or after flash is highly recommended.
    After flashing, you may boot into recovery to install SuperSU and Gapps.
    SuperSU 2.74 has been tested. (You need to re-flash SuperSU if boot.img is changed)
    OpenGapps pico was also tested but required adding the permissions manually to stop the crashes. Enable PHONE permission via settings OR adb
    Code:
    Type:
    adb shell
    su
    pm grant com.google.android.setupwizard android.permission.READ_PHONE_STATE

    Note: Apps like Package Access helper, browers2 etc. also required granting permissions manually

    To install apps via adb:
    Code:
    Type:
    adb install Firefox4.6.apk

    What's not working:
    1. 3G mobile data (required stlport library which is not compatible with N, need to rebuild from source)
    2. Bluetooth (Not yet handled)
    3. GPS (need to fix the blob)
    4. probably more....

    Have fun! :D
    6
    Latest DC-kernel 20160330 is out. :D
    This build has the power HAL included. The O/C frequencies are handled in the power HAL now.
    Kernel: A few fixes and adjustments are included
    PerformanceControl.: CPU governor settings is enabled
    Note: Governor settings may freeze your device. Don't check set on boot if you are not 100% sure!