Android OS Forum banner
1 - 20 of 103 Posts

·
Premium Member
Joined
·
212 Posts
Mod Type:: ROM

Difficulty:: Easy

Mod Base:: CyanogenMod

Mod Status:: Kang

Apply In:: CWM Recovery

Optional:: Custom Settings

Requires Root:: Yes

Optional:: Overclocked

Android Version:: 4.0.3 (ICS)

Source::
##DISCLAIMER##
Though this is tested and I am using this, and nothing evil happened until now, it might slap you so hard in your face that not even google is able to find you anymore.
No kidding: !Experimental! This does not fix one bug of CM9 nor does it attempt to do so. So don't b*t*h me about that. This is meant as a test for KSM, to see if any problems arise and how much use (performance gain / more free ram) this gives on Android. (theoretically it should be very useful)

For everyone who wants to give it a try:

Bricked-CM9Kang v4
based on AOSP CM9 #Kangified


What does it give you:
Everything from CM9 + Touchscreen fixes (Dees_Troy27) + KSM (Kernel Samepage Merging) + fixed init.d script autoexecution on bootup (turl) + etc...

Bricked-Kernel with KSM support, Default clocks @ 1566/192 ondemand
- OC up to 1914Mhz, Voltage Control via sysfs (SystemTuner, etc), etc, etc.... Look here.

Install:
Do you want a fresh install? Wipe data/factory reset & just flash from recovery.
Already on cm9 and don't want to loose your data? Just flash over your current install without wiping (don't forget to reinstall gapps afterwards).

Download:

v4
ROM + Kernel:
mediafire.com: Click Me
http mirror: Click me
SHA1: 14db526c93962359995ea260c80d2811ba32eaae

Gapps: Click Me
SHA1: 1d277d2d7e802eb13975757df46c09afbaafcd2c

Gappsfixer: Click Me
This removes bad <shared-user> elements from packages.xml and lets android regenerate them. This fixes a problem with gapps signatures. (Just flash it after gapps, there can nothing go wrong)
SHA1: 5b66a2e160922626d67b30b459b5323deb8f549d

#cyanogenmod-touchpad Readme and Gapps:
http://ergh.org/cmtp/

Mirror (Folder by jassycliq):
mediafire.com, adfree: Click Me

What is KSM - Kernel Samepage Merging?
From Wikipedia, the free encyclopedia

Kernel SamePage Merging (KSM) (also: Kernel Shared Memory, Memory Merging) lets system share identical memory pages amongst different processes or virtualized guests. This is done by scanning through the memory finding duplicate pages. The duplicate pair is then merged into a single page, and mapped into both original locations. The page is also marked as "copy-on-write", so the kernel will automatically separate them again should one process modify its data.[sup][1][/sup]
KSM was originally intended to run more virtual machines on one host by sharing memory between processes as well as virtual machines. Upon implementation, it was also found to be useful for non-virtualized environments where memory is at a premium [sup][2][/sup][sup][3][/sup]. An experimental implementation of KSM by Red Hat found that 52 virtual instances of Windows XP with 1GB of memory, could run on a host computer that had only 16GB of RAM [sup][4][/sup].
KSM first appeared in the version 2.6.32 Linux operating system kernel [sup][2][/sup]. To be effective, the operating system kernel must find similar memory pages held by different processes. As well it needs to decide whether the pages are going to update infrequently enough that SamePage Merging would be an efficient use of processor resources [sup][3][/sup]. When first proposed, there were concerns that this feature could be exploit as a security vulnerability (this concern has since been addressed). Another concern is that although memory usage is reduced, CPU usage is increased, thus negating potential increases in performance [sup][1][/sup].

References
more to KSM: http://bitcube.co.uk...merging-and-kvm

How to see the Magic happening?
Code:
<br />
cat /sys/kernel/mm/ksm/full_scans<br />
cat /sys/kernel/mm/ksm/pages_shared<br />
cat /sys/kernel/mm/ksm/pages_sharing<br />
cat /sys/kernel/mm/ksm/pages_to_scan<br />
cat /sys/kernel/mm/ksm/pages_unshared<br />
cat /sys/kernel/mm/ksm/pages_volatile<br />
cat /sys/kernel/mm/ksm/run<br />
cat /sys/kernel/mm/ksm/sleep_millisecs<br />
or just:
Code:
<br />
cat /sys/kernel/mm/ksm/*<br />
to get all at once.
Check your RAM stats with:
Code:
<br />
free<br />
Source for KSM implementation:

Android source modifications: Click Me
Kernel source modifications: Click Me
(ofc KSM must be enabled in your kernel config)

Source for Bricked:
Click Me

Thanks to everyone who ever contributed anything (even only a whitespace) to any of the used software.
 

·
Premium Member
Joined
·
212 Posts
Changelog:

*** v4 ***
ROM:
synced with CM9 repo @ 05:04 PST 31/01/12
KSM code cleanup. Testing new configuration
Tweaking KSM, lowering CPU usage
Fixing restore of gapps after install (my fault, c&p was being a b*tch)
Allow reboot to recovery (http://review.cyanog...m/#change,12311)
Allow power options menu (http://review.cyanog...m/#change,12315)
Added CombinedBar Auto Hide (http://review.cyanog...m/#change,12281)
SurfaceFlinger: Set the buffer size in the GraphicBufferAlloc (http://review.cyanog...m/#change,12263)
Preference to disable bootanimation for faster boot (http://review.cyanog...m/#change,12169)

Kernel:
ksm update from bricked-pyra source
Lowered min voltage once again (now: 700mV)
Updated KGSL driver with bricked-pyramid:
msm: kgsl: 8Stages 3D scaling, highest @ 300Mhz (fraction 33)
msm: kgsl: 6stages 2D scaling, highest @ 266,7Mhz, 33,35% Overclocked (fraction 100)
msm: kgsl: GPU off while screen off!
msm: kgsl: improved KGSL suspend
msm: kgsl: Use the correct virtual address for pmem regions
msm: kgsl: Delay 30ms to make sure GPU is ready during resume time
msm: kgsl: Update pwrlevel_change
msm: kgsl: Add sysfs attribute to turn GPU DCVS off/on
msm: kgsl: Early Suspend drivers
msm: kgsl: Turbo Mode
msm: kgsl: Don't check for idle while suspended
msm: kgsl: Make kgsl_idle_check check if a nap is allowed
msm: kgsl: fix parameter checking in adreno_ringbuffer_issueibcmds
msm: kgsl: Abort kgsl_pwrctrl_wake() when in KGSL_STATE_INIT
msm: kgsl: create singlethread wq instead of per-cpu wq
msm: kgsl: Fixing earlysuspend/lateresume for multiple devices.
msm: kgsl: run kgsl_idle_check after resuming a device
msm: kgsl: fix coding derp for init pwrctrl

*** v3 ***
repo synced with CM9 (18:00 CET, 27/01/12)
touchscreen fixups by Dees_Troy, ts: lower touch threshold to help with light touches
touchscreen optimization by Dees_Troy, remove unneeded code and optimize filter
disable_dock_switch, fixes touchstone freezes, thanks to nomadman
hq bootanimation, by Kevin1981 from #cyanogenmod-touchpad on freenode
new quicksettings options, optimized for tablets, http://review.cyanogenmod.com/12162
External Bluetooth GPS support, http://review.cyanog...m/#change,12095
...and many more stuff from the sync, take a look under settings


*** v2 - installfix ***
*fix setting Bricked as default kernel.
*delete uImage.CyanogenMod

*** Initial Release - v2 ***
Based on cm9 a0.5
Touchscreen fix by Dees_Troy27
init.d script on boot execution fix by Turl
KSM support kernel & rom side
 

·
Android Apprentice
Joined
·
103 Posts
I almost took your reserved spot, lol. Looks like your mirrors are still propagating. I'll download when Multiupload loads up the file.

Sent from my cm_tenderloin using RootzWiki
 

·
Android Apprentice
Joined
·
103 Posts
Flashed, working great. Just one thing I noticed:

If you flash this over CM9 (stock) without wiping, the zip does not change the default kernel back to the Bricked Kernel. You'll notice this because your wifi won't work. To set Bricked to default again, do this:

Code:
<br />
adb shell<br />
mount -o remount,rw /boot<br />
echo "CM_Bricked-Kernel" > /boot/moboot.default<br />
exit<br />
Then reboot your Touchpad. Fixed!

Credit: Took the commands from show-p1984's original Bricked Kernel thread.
 
  • Like
Reactions: show-p1984

·
Premium Member
Joined
·
212 Posts
Discussion Starter · #7 ·
Flashed, working great. Just one thing I noticed:

If you flash this over CM9 (stock) without wiping, the zip does not change the default kernel back to the Bricked Kernel. You'll notice this because your wifi won't work. To set Bricked to default again, do this:

Code:
<br />
adb shell<br />
mount -o remount,rw /boot<br />
echo "CM_Bricked-Kernel" > /boot/moboot.default<br />
exit<br />
Then reboot your Touchpad. Fixed!

Credit: Took the commands from show-p1984's original Bricked Kernel thread.
It should do that. cO
BTW: You can notice it even sooner: What moboot has selected first is the default kernel

Lemme check
 

·
Android Apprentice
Joined
·
103 Posts
It should do that. cO
BTW: You can notice it even sooner: What moboot has selected first is the default kernel
Lemme check
Well yeah, but I wasn't looking at the screen on first boot, lol.

Sent from my cm_tenderloin using RootzWiki
 

·
Premium Member
Joined
·
212 Posts
Well yeah, but I wasn't looking at the screen on first boot, lol.

Sent from my cm_tenderloin using RootzWiki
You are right though.. I somehow forgot to include the folder with the script in the final zip...
*uploading now*
 

·
Android Apprentice
Joined
·
158 Posts
All good so far. Actually seems very snappy and responsive. I'm definitely impressed.

Just for future reference, an acmeuninstall and the a reinstall of original CM9A0.5 would give me back the stock kernel if necessary, correct? That or a nandroid could both work?
 

·
Registered
Joined
·
271 Posts
All good so far. Actually seems very snappy and responsive. I'm definitely impressed.

Just for future reference, an acmeuninstall and the a reinstall of original CM9A0.5 would give me back the stock kernel if necessary, correct? That or a nandroid could both work?
CWM .zip packages usually contain the ROM and the kernel. You just flash that in CWR to revert to the CM kernel, or nandroid to an older build, or push the kernel through ADB. I don't know much about the acme installer since I don't like it
 

·
Android Apprentice
Joined
·
158 Posts
CWM .zip packages usually contain the ROM and the kernel. You just flash that in CWR to revert to the CM kernel, or nandroid to an older build, or push the kernel through ADB. I don't know much about the acme installer since I don't like it
Thank you.

P.S. I guess its the touchscreen fixes listed in the OP, but since updating to this, my keyboard seems incredibly accurate at high speeds. Either that, or its a placebo effect and I'm crazy...
 

·
Registered
Joined
·
101 Posts
also coming from previous signed_GAPPS-IML74K-010112 gapps, my exchange settings were completely wiped and any account associated to Email.apk was removed. Email.apk no longer worked. Google Mail account settings was not touched. So removed Email.apk and Exchange.apk from /system/app. Then unzipped the ROM and push Email.apk and Exchange.apk to /system/app.
 
1 - 20 of 103 Posts
This is an older thread, you may not receive a response, and could be reviving an old thread. Please consider creating a new thread.
Top