Tuesday, March 29, 2016

Skinny Pro Custom Boot Images

What is Skinny Pro?
It is not a custom Kernel - it is a custom boot.img containing modified initialization scripts for the stock kernel.
It turns the Redmi Note 2 from a dull phone into a brilliant phone.
I will maintain 2 versions - 1 for MIUI and one for generic AOSP based ROMs. Both versions currently use MIUI 7.2.20 as the base.
I do not advise flashing of preloader or uboot images from custom ROMs as this can lead to soft bricking your phone. There is nothing to be gained if you are coming from MIUI 7.1.1 or later.

Design Brief:
No embedding of "tweaks" in the boot.img
No Placebos
To overcome the limitations of Stock MIUI being:
  • Poor battery life
  • Poor performance
  • Chronic invasion of privacy

Boot.img mods:
Disable starting of non-present devices and services
Disable starting of (some) invasive (spying) services
Remove all fingerprint sensor infrastructure not intended for this phone
Reconfigured SDCard suppport to remove legacy symlinks and rationalize representation.
Built in init.d support
Supports correct zram swap creation (disable conflicting MIUI "mcd" service and infrastructure)

What you get:
Marginally faster boot
Less background activity at idle
Less RAM usage
Less spying activity
Better battery life
Better Performance
Ability to set tweaks of your choice via init.d (careful not to add conflicting tweaks!!!)

How to install?
You must have at least MIUI 7.1.1 installed previously.
The boot.img can be used on an existing installation or as part of a new installation.
It will eliminate any customized tweaks that are embedded in previous boot images.
  • Install as "Image" from TWRP
  • Flash via SP Tools if you are familiar with it or......
  • Flash via Fastboot.
  • No wipes required before or afterwards.

Warning: Whatever was on the internal (emulated) sdcard will be dumped into a folder named "0" on /storage/sdcard0
Move the files back to /storage/sdcard0 to recover.

What else should be done after this?
1. Open /etc/perfservscntbl.txt in a text editor and edit as follows:

CMD_SET_CPU_FREQ, SCN_APP_TOUCH, 403000
CMD_SET_CPU_CORE, SCN_APP_TOUCH, 1


2. Create an init.d script exactly as follows:
For 2GHz variants:

#!/system/bin/sh

### Tweak Interactive CPU Governor
echo 806000 > /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq
echo 85 > /sys/devices/system/cpu/cpufreq/interactive/go_hispeed_load
echo 90 403000:80 806000:85 1326000:90 1625000:95 1950000:99 > /sys/devices/system/cpu/cpufreq/interactive/target_loads
echo 30000 > /sys/devices/system/cpu/cpufreq/interactive/timer_rate ######## change this value between 30000 and 40000 to get idle freq returning to 403MHz
echo 20000 > /sys/devices/system/cpu/cpufreq/interactive/min_sample_time
echo 20000 > /sys/devices/system/cpu/cpufreq/interactive/above_hispeed_delay
echo 20000 > /sys/devices/system/cpu/cpufreq/interactive/timer_slack

### Enable zram swap - enable these lines if needing extra ram capacity
#echo 536870912 > /sys/block/zram0/disksize ### 536870912 = 512MB 1073741824=1GB
#/system/bin/tiny_mkswap /dev/block/zram0
#/system/bin/tiny_swapon /dev/block/zram0

### Tweak Entropy to avoid regular depletion of available pool
echo 512 > /proc/sys/kernel/random/read_wakeup_threshold
echo 1024 > /proc/sys/kernel/random/write_wakeup_threshold


For 2.2GHz variants change this one line to:
echo 90 403000:80 806000:85 1326000:90 1664000:95 2158000:99 > /sys/devices/system/cpu/cpufreq/interactive/target_loads

3.Remove these redundant files if they exist:
/vendor/lib
libfingerprint_tac.so
libfpcalgorithm.so

/vendor/lib64
libcom_fingerprints_productiontestmanager.so
libcom_fingerprints_sensor.so
libfingerprint_tac.so

/system/lib
libcaFingerPrintShared.so
libcom_fingerprints_service.so
libfphal.so
libfpservice.so

/system/lib64
libcaFingerPrintShared.so
libcom_fingerprints_service.so
libfphal.so
libfpservice.so

Skinny Pro MIUI version:
http://ift.tt/1Oiohfv

Skinny Pro Generic AOSP version:
http://ift.tt/1Oiohfv

Enjoy:)


from xda-developers http://ift.tt/1UTGgw1
via IFTTT

No comments:

Post a Comment