As the name suggests, dkp is a hodgepodge of features and tweaks that I wanted to play with. It should get excellent battery life without feeling sluggish. It doesn't come with its own tuner app, so pick your favorite. I go out of my way to support Trickster MOD, but most other apps work well.
Overclocking up to 2.1 GHz, but you'll need to increase your voltages to get there (if you can get there at all)
Underclocking down to 54 MHz, with stability improvements
Undervolting compatible with most apps
Fast charge without unplugging first
Glorious animations for the notification and softkey LEDs
Well-integrated erandom means you don't need CrossBreeder or Seeder (recent AOSP builds use ISAAC instead)
freelunch governor provides a good compromise between battery life and performance
Automatic mpdecision and auto-hotplug are only enabled when needed
Adjustable minimum voltage for stability on finicky processors
exFAT support for 64GB SD cards
Optimized UKSM to free up some extra memory
Code optimizations for size and speed
Compiler optimizations (-O3, LTO, and more) because faster is better
Donors: Thanks, everyone! Your generosity is much appreciated.
drpenguino, 0xScott, vmancini3 (twice! ), Ch4m3l30n, rompnit, Mystique, ryandubbz, techdog
last_kmsg and/or logcat or it didn't happen.
Other kernels have their own threads or forums. Discuss them there.
Image dumps (settings, battery life, whatever) belong inside [HIDE][/HIDE] (that's HIDE, if you're on the mobile app) tags.
Be silly. We're here to have fun.
Reboot to recovery. I recommend that one recovery...you know, the one that flashes zips? I forget what it's called.
Flash dkp. Optionally, rename and flash dkp-vmin-XXX.zip (see below).
Undervolting on dkp is more complex than other kernels. Some processors get unstable at lower voltages, so (like the stock kernel) dkp keeps the processor voltage above 1150 mV by default. I refer to this limit as the minimum voltage. In order to undervolt, you'll need to lower the minimum voltage: if you use Trickster MOD, just disable "Override Minimum Voltage" in the "Specific" page, otherwise rename dkp-vmin-XXX.zip to e.g. dkp-vmin-600.zip (which would apply a 600 mV minimum voltage) and flash it. If this causes instability (crashes, audio/video glitches, etc.), try using dkp-vmin-XXX.zip to apply a higher minimum voltage (somewhere between 950 and 1050 mV seems to work well for most people).
mikedavis120 has put together a how-to video that covers tweaking dkp for optimal battery life. If you're new to dkp, take a look! He also put together a zipped collection of apps that will come in handy while tuning dkp. It also includes a flashable zip, "dkp-debug_v1.zip". After flashing it, running
from a terminal emulator will collect lots of useful debug information that will make it much easier for me to track down the issue you're having. mikedavis120 recommends installing SuperSU (included in the zip) instead of what's included in you ROM.
It's possible to adjust all the settings available in dkp without using apps. Because they show up as files, settings can be adjusted with file managers, terminal emulators, adb and initscripts. Here's the most interesting files inside sysfs:
/sys/devices/system/cpu/cpu<N>/cpufreq/UV_mV_table: voltage table
/sys/devices/system/cpu/cpu<N>/cpufreq/scaling_...: scaling_governor is the governor, scaling_min_freq and scaling_max_freq are the minimum and maximum frequencies, scaling_available_governors and scaling_available_frequencies show the available governors and frequencies
/sys/kernel/dkp/force_fast_charge: fast charge
/sys/kernel/dkp/link_core_settings: when linked (the default), frequency settings and some governors are automatically copied to the other core
/sys/kernel/dkp/vmin: minimum processor voltage in mV
/sys/kernel/mm/uksm/run: activate UKSM
These show up in the governor settings for any governor that doesn't do its own hotplugging. They only take effect when using auto-hotplug, so you'll probably need to disable mpdecision in Trickster.
hotplug_intpulse: when set to 1, automatically turns core 2 on whenever the screen/buttons/whatever is pressed. Default is 0.
hotplug_sampling_periods: number of samples to use for average number of running tasks. Default is 15.
hotplug_sampling_rate: number of 'jiffies' (currently 1 jiffy = 10 ms) between each sample of running tasks. Default is 20 (0.2 sec).
hotplug_enable_one_threshold: the average number of running tasks required to turn core 2 on, multiplied by 100. Default is 125 (1.25 tasks on average).
hotplug_disable_one_threshold: the average number of running tasks required to keep core 2 on, multiplied by 100. Default is 250 (2.5 tasks on average).
freelunch and nanolunch aren't materially based on other governors, so their configuration is quite different than other governors. There's lots of tuners, since I haven't really decided on an ideal tuning. I encourage experimentation! I'll explain a bit of how these governors work before actually listing the tuners.
Generally speaking, there are two modes: in "normal" mode, sampling is done occasionally and frequency is generally increased slowly; in "interactive" mode, sampling is done much more quickly, and frequency increases much more quickly. "Interactive" mode ends after several samples of very low usage. The idea of a "hispeed" frequency is used in lots of governors, and it refers to the frequency that the CPU will jump to when more CPU usage is needed; generally, it's a generous estimate of how much CPU will be needed. Here, the hispeed frequency is adjusted on-the-fly, increasing when more CPU is needed and gradually decreasing when the CPU is idle. In "interactive" mode, the hispeed frequency is kept fairly high so that everything will feel snappy.
Hotplugging is taken care of in the least complicated (and in my opinion, most reasonable) way possible: if core 1 is using lots of CPU, and there are several tasks running (in other words, if it's likely that core 2 will have something to do), core 2 is turned on; if either core isn't doing much except using power, core 2 is turned off.
sampling_rate: the usual
hotplug_up_cycles: number of consecutive heavily-loaded samples before core 2 is turned on
hotplug_down_cycles: number of consecutive lightly-loaded samples before core 2 is turned off
hotplug_up_load: number of running tasks required to bring core 2 online
hotplug_up_usage: number of used CPU cycles (in thousands per second) required to bring core 2 online
hotplug_down_usage: number of used CPU cycles (in thousands per second) required on both cores to keep core 2 online
overestimate_khz: number of CPU cycles to overshoot usage by in "normal" mode
hispeed_thresh: if CPU usage is within this many cycles (in thousands per second) of the maximum frequency, frequency will be increased to the hispeed frequency. Generally, hispeed is pretty low in "normal" mode, and fairly high in "interactive" mode.
hispeed_decrease: when the CPU is sitting idle, the hispeed frequency is decreased by this amount each sample (this isn't ideal, but it works)
interaction_hispeed: the initial hispeed frequency when switching to "interactive" mode
interaction_return_cycles: number of consecutive lightly-loaded samples before returning to "normal" mode
interaction_return_usage: number of used CPU cycles (in thousands per second) required to stay in "interactive" mode
interaction_panic (nanolunch only): when set to 1, allows aggressively jumping past the current hispeed frequency under some circumstances
interaction_sampling_rate/overestimate_khz: equivalent to the "normal" versions of the tuners, these take effect in "interactive" mode
If your signature says something like "Hit the thanks button if I've helped," I automatically assume you're here for "likes" and really care about imaginary internet points.
You're on the wrong site. Don't be that person. Its ridiculous.
dkp is based off clean CM source, so it shouldn't have been merged already.
I've got test builds compiling now, and the 3.4 builds will be up shortly. Flashing the trinity-colors test build and this zip will enable trinity colors. You can toggle it with
echo X >/sys/class/mdnie/mdnie/trinity_colors
where X is 0 to disable or 1 to enable.
Edit: and sorry for taking so long to respond.
Edit 2: 3.4 builds are up. http://d-h.st/7Ae
Maybe I was just seeing things, had just watched jurassic park in 3d.
New "test" build flashed as well as the file to enable it. Thanks for the addition. It's very hard to go back to normal once you've been smurfed depending on your display.
Only issue i'm having ATM is the ability to change the voltage table. My phone doesn't handle undervolting as well and i run a minimum of 950 baseline, if not 975. One of my normal apps wasn't able to set the voltage at all. I'm trying to use performance control which I don't like. It crashes trying to set the voltage on boot but at least I can go in and manually set the values on boot and they stick.
One last question, since this is your kernel, what scheduler do you recommend pairs well to freelunch? What would you use for performance and what would you use for batt?
The Nvidia Shield Tabletis the latest toy from one of the largest desktop graphics … more
28 Aug 2014
By Tomek Kondrat
XDA Developers was founded by developers, for developers. It is now a valuable resource for people who want to make the most of their mobile devices, from customizing the look and feel to adding new functionality. Are you a developer?