Speed up your system with the noop scheduler - G1 Android Development

From Wikipedia:
Code:
The NOOP scheduler is the simplest I/O scheduler for the Linux kernel.
This scheduler was developed by Jens Axboe.
The NOOP scheduler inserts all incoming I/O requests into a simple, unordered
FIFO queue and implements request merging.
The scheduler assumes I/O performance optimization will be handled at some
other layer of the I/O hierarchy; e.g., at the block device; by an intelligent
HBA such as a Serial Attached SCSI (SAS) RAID controller or by an externally
attached controller such as a storage subsystem accessed through a
switched Storage Area Network).
[B]NOOP scheduler is best used with solid state devices such as flash memory
or in general with devices that do not depend on mechanical movement to
access data (meaning typical "hard disk" drive technology consisting of seek
time primarily, plus rotational latency). [/B]Such non-mechanical devices do not
require re-ordering of multiple I/O requests, a technique that groups together
I/O requests that are physically close together on the disk, thereby reducing
average seek time and the variability of I/O service time.
To check which scheduler is used:
Code:
adb shell
~ # cat /sys/block/mmcblk0/queue/scheduler
[noop] cfq
To select a different scheduler:
Code:
adb shell
~ # echo "noop" > /sys/block/mmcblk0/queue/scheduler
To select the noop scheduler for all your block devices you can add
this lines to your userinit.sh script:
Code:
# Set "No-op" scheduler for mtdblocks and mmc
for i in `ls -1 /sys/block/mtdblock*` /sys/block/mmcblk0
do
echo "noop" > $i/queue/scheduler
done
I tested it a little and especially the sdcard seems to work faster.
Enjoy

Ahh, noop is set to default in my kernels, but I wouldn't say that there is BIG difference on g1.

Is it even better then the BFQ Scheduler used by Cyanogen?

farmatito said:
From Wikipedia:
Code:
The NOOP scheduler is the simplest I/O scheduler for the Linux kernel.
This scheduler was developed by Jens Axboe.
The NOOP scheduler inserts all incoming I/O requests into a simple, unordered
FIFO queue and implements request merging.
The scheduler assumes I/O performance optimization will be handled at some
other layer of the I/O hierarchy; e.g., at the block device; by an intelligent
HBA such as a Serial Attached SCSI (SAS) RAID controller or by an externally
attached controller such as a storage subsystem accessed through a
switched Storage Area Network).
[B]NOOP scheduler is best used with solid state devices such as flash memory
or in general with devices that do not depend on mechanical movement to
access data (meaning typical "hard disk" drive technology consisting of seek
time primarily, plus rotational latency). [/B]Such non-mechanical devices do not
require re-ordering of multiple I/O requests, a technique that groups together
I/O requests that are physically close together on the disk, thereby reducing
average seek time and the variability of I/O service time.
To check which scheduler is used:
Code:
adb shell
~ # cat /sys/block/mmcblk0/queue/scheduler
[noop] cfq
To select a different scheduler:
Code:
adb shell
~ # echo "noop" > /sys/block/mmcblk0/queue/scheduler
To select the noop scheduler for all your block devices you can add
this lines to your userinit.sh script:
Code:
# Set "No-op" scheduler for mtdblocks and mmc
for i in `ls -1 /sys/block/mtdblock*` /sys/block/mmcblk0
do
echo "noop" > $i/queue/scheduler
done
I tested it a little and especially the sdcard seems to work faster.
Enjoy
Click to expand...
Click to collapse
Would you mind since you are willing to share this info to post some information on what settings you are finding work best and such?
To post this type of info without it being watered down a bit for ever level of user can and probably will cause issues from people going into settings only half knowing what they are doing. Granted if you don't know what you are doing you shouldn't be, but we all know its going to happen

pentace said:
Would you mind since you are willing to share this info to post some information on what settings you are finding work best and such?
To post this type of info without it being watered down a bit for ever level of user can and probably will cause issues from people going into settings only half knowing what they are doing. Granted if you don't know what you are doing you shouldn't be, but we all know its going to happen
Click to expand...
Click to collapse
I tested it on a Cyanogen Mod 4.0.4 with self compiled kernel 2.6.29.6
from cyanogen's git repository. The available schedulers are noop and cfq.
The default scheduler was cfq and after having read about noop scheduler
i tried it and found no regression in performance but rather some improvement.
I have no benchmarks yet. So you have to test it yourself
to see if it makes a difference on your phone. I cannot imagine
this mod causing issues as it is easily reverted and it was not intended
for all users but rather for the tech savvy to see if they can confirm
some improvement in performance.

JD82 said:
Is it even better then the BFC Scheduler used by Cyanogen?
Click to expand...
Click to collapse
It's I/O scheduler.

akirah said:
It's I/O scheduler.
Click to expand...
Click to collapse
I've made a typo: it is BFQ, not BFC.
From the cyanogenmod's changelog:
* Now using the BFQ I/O scheduler, which seems like a good compromise between CFQ and the old anticipatory scheduler
Click to expand...
Click to collapse
From my G1:
Code:
adb shell
# cat /sys/block/mmcblk0/queue/scheduler
noop [bfq]
Again: Is it even better then the BFQ Scheduler used by Cyanogen?

farmatito said:
From Wikipedia:
Code:
The NOOP scheduler is the simplest I/O scheduler for the Linux kernel.
This scheduler was developed by Jens Axboe.
The NOOP scheduler inserts all incoming I/O requests into a simple, unordered
FIFO queue and implements request merging.
The scheduler assumes I/O performance optimization will be handled at some
other layer of the I/O hierarchy; e.g., at the block device; by an intelligent
HBA such as a Serial Attached SCSI (SAS) RAID controller or by an externally
attached controller such as a storage subsystem accessed through a
switched Storage Area Network).
[B]NOOP scheduler is best used with solid state devices such as flash memory
or in general with devices that do not depend on mechanical movement to
access data (meaning typical "hard disk" drive technology consisting of seek
time primarily, plus rotational latency). [/B]Such non-mechanical devices do not
require re-ordering of multiple I/O requests, a technique that groups together
I/O requests that are physically close together on the disk, thereby reducing
average seek time and the variability of I/O service time.
To check which scheduler is used:
Code:
adb shell
~ # cat /sys/block/mmcblk0/queue/scheduler
[noop] cfq
To select a different scheduler:
Code:
adb shell
~ # echo "noop" > /sys/block/mmcblk0/queue/scheduler
To select the noop scheduler for all your block devices you can add
this lines to your userinit.sh script:
Code:
# Set "No-op" scheduler for mtdblocks and mmc
for i in `ls -1 /sys/block/mtdblock*` /sys/block/mmcblk0
do
echo "noop" > $i/queue/scheduler
done
I tested it a little and especially the sdcard seems to work faster.
Enjoy
Click to expand...
Click to collapse
Excellent tip, thanks!

JD82 said:
I've made a typo: it is BFQ, not BFC.
From the cyanogenmod's changelog:
From my G1:
Code:
adb shell
# cat /sys/block/mmcblk0/queue/scheduler
noop [bfq]
Again: Is it even better then the BFQ Scheduler used by Cyanogen?
Click to expand...
Click to collapse
Yeah well, anticipatory is back now in the new stable build.
Code:
cat /sys/block/mmcblk0/queue/scheduler
noop [anticipatory]

I tested it only vs cfq scheduler, so I can't say if it is better than anticipatory
or cfq scheduler. The rationale behind this change is that flash and mmc don't need a scheduler so there should be a performance gain for the reason that
that we use simpler/less kernel code with littler data structures in memory.
Time and user reports will tell it the change is worth the effort.

I've tried them all and keep going back to the anticipatory iosched. Everything just seems smoother. Maybe the devices like the io reordering that it does.

cyanogen said:
I've tried them all and keep going back to the anticipatory iosched. Everything just seems smoother. Maybe the devices like the io reordering that it does.
Click to expand...
Click to collapse
Thanks, this is the best answer I could hope

cyanogen said:
I've tried them all and keep going back to the anticipatory iosched. Everything just seems smoother. Maybe the devices like the io reordering that it does.
Click to expand...
Click to collapse
Code:
From Wikipedia, the free encyclopedia
Anticipatory scheduling is an algorithm for scheduling hard disk input/output.
It seeks to increase the efficiency of disk utilization by "anticipating"
synchronous read operations.
"Deceptive idleness" is a situation where a process appears to be finished
reading from the disk when it is actually processing data in preparation of the
next read operation. This will cause a normal work-conserving I/O scheduler
to switch to servicing I/O from an unrelated process. This situation is
detrimental to the throughput of synchronous reads, as it degenerates into a
seeking workload. Anticipatory scheduling overcomes deceptive idleness by
pausing for a short time (a few milliseconds) after a read operation in
anticipation of another close-by read requests.
Anticipatory scheduling yields significant improvements in disk utilization for
some workloads. In some situations the Apache web server may achieve up
to 71% more throughput from using anticipatory scheduling.
The Linux anticipatory scheduler may reduce performance on disks using
TCQ, high performance disks, and hardware RAID arrays. An anticipatory
scheduler (AS) was the default Linux kernel scheduler between 2.6.0 and
2.6.18, by which time it was replaced by the CFQ scheduler.
Judging by this description "as" scheduler should be doing no good to mmc or
flash as there are no moving parts as in hard disk. I think we should do some
benchmarking. Ideas?

Some rough benchmarks:
A) Wrinting a 10MB file to sdcard:
1) with anticipatory scheduler
Code:
time dd if=/dev/zero of=/sdcard/test.bin bs=1M count=10
10+0 records in
10+0 records out
real 0m 2.63s
user 0m 0.22s
sys 0m 0.30s
2) with noop scheduler:
Code:
time dd if=/dev/zero of=/sdcard/test.bin bs=1M count=10
10+0 records in
10+0 records out
real 0m 0.64s
user 0m 0.10s
sys 0m 0.33s
B) Reading 10MB file from sdcard:
1) with anticipatory scheduler:
Code:
time cat /sdcard/test.bin
real 0m 6.32s
user 0m 0.93s
sys 0m 0.02s
2) with noop scheduler:
Code:
time cat /sdcard/test.bin
real 0m 6.35s
user 0m 0.93s
sys 0m 0.01s
C) Writing a 10 MB file to flash:
1) with anticipatory scheduler:
Code:
time dd if=/dev/zero of=/data/test.bin bs=1M
10+0 records in
10+0 records out
real 0m 4.04s
user 0m 0.81s
sys 0m 0.04s
2) with noop scheduler:
Code:
time dd if=/dev/zero of=/data/test.bin bs=1M count=10
10+0 records in
10+0 records out
real 0m 4.09s
user 0m 0.81s
sys 0m 0.05s
D) reading a 10MB file from flash:
1) with anticipatory scheduler:
Code:
time cat /data/test.bin
real 0m 6.33s
user 0m 0.90s
sys 0m 0.01s
2) with noop scheduler:
Code:
time cat /data/test.bin
real 0m 6.32s
user 0m 0.88s
sys 0m 0.01s
On the sdcard anticipatory and noop scheduler have similar performance when reading, but noop is a lot faster when writing.
On flash memory they have similar performance in reading and writing.
I prefer noop as the code is simpler with less overhead for the system.
Any ideas about better benchmarking are welcome.

Just wondering if this was a single run test or multiple using averages?

dumfuq said:
Just wondering if this was a single run test or multiple using averages?
Click to expand...
Click to collapse
+1
In Android, where do I place the command to be executed automatically? Is there a rc.local or equivalent?

The test results are indicative values of a few test runs.
To automate the setup commands could be added to userinit.sh

I've made a very simple script to iterate 10 times with the noop and anticipatory scheduler.
Code:
#!/system/bin/sh
IOSCHEDULER="anticipatory"
writesd()
{
cat /sys/block/mmcblk0/queue/scheduler
for i in `seq 1 10`;
do
time dd if=/dev/zero of=/sdcard/test.bin bs=1M count=10
done
rm /sdcard/test.bin
}
cat /sys/block/mmcblk0/queue/scheduler | grep -q $IOSCHEDULER
if [[ $? -ne 0 ]]
then
echo "Please set the correct scheduler by editing the script"
exit 1
fi
echo "noop" > /sys/block/mmcblk0/queue/scheduler
writesd
sleep 2
echo $IOSCHEDULER > /sys/block/mmcblk0/queue/scheduler
writesd
The output on my G1:
Code:
[noop] anticipatory
10+0 records in
10+0 records out
real 0m 2.71s
user 0m 0.00s
sys 0m 0.52s
10+0 records in
10+0 records out
real 0m 1.43s
user 0m 0.01s
sys 0m 0.49s
10+0 records in
10+0 records out
real 0m 1.74s
user 0m 0.00s
sys 0m 0.47s
10+0 records in
10+0 records out
real 0m 1.55s
user 0m 0.01s
sys 0m 0.48s
10+0 records in
10+0 records out
real 0m 1.21s
user 0m 0.00s
sys 0m 0.57s
10+0 records in
10+0 records out
real 0m 1.09s
user 0m 0.00s
sys 0m 0.43s
10+0 records in
10+0 records out
real 0m 1.95s
user 0m 0.00s
sys 0m 0.43s
10+0 records in
10+0 records out
real 0m 1.89s
user 0m 0.00s
sys 0m 0.45s
10+0 records in
10+0 records out
real 0m 1.53s
user 0m 0.00s
sys 0m 0.43s
10+0 records in
10+0 records out
real 0m 1.21s
user 0m 0.00s
sys 0m 0.54s
Code:
noop [anticipatory]
10+0 records in
10+0 records out
real 0m 1.38s
user 0m 0.00s
sys 0m 0.46s
10+0 records in
10+0 records out
real 0m 1.22s
user 0m 0.00s
sys 0m 0.45s
10+0 records in
10+0 records out
real 0m 1.94s
user 0m 0.00s
sys 0m 0.48s
10+0 records in
10+0 records out
real 0m 1.60s
user 0m 0.00s
sys 0m 0.48s
10+0 records in
10+0 records out
real 0m 1.82s
user 0m 0.00s
sys 0m 0.47s
10+0 records in
10+0 records out
real 0m 1.21s
user 0m 0.00s
sys 0m 0.59s
10+0 records in
10+0 records out
real 0m 1.42s
user 0m 0.00s
sys 0m 0.56s
10+0 records in
10+0 records out
real 0m 1.88s
user 0m 0.00s
sys 0m 0.42s
10+0 records in
10+0 records out
real 0m 2.05s
user 0m 0.00s
sys 0m 0.49s
10+0 records in
10+0 records out
real 0m 1.50s
user 0m 0.00s
sys 0m 0.48s
I don't see any big difference. The values fluctuate a lot.

You also have to consider the many readers/writers situation. I think the AS should be better here (CFQ even more so, but CFQ has more overhead).

cyanogen said:
You also have to consider the many readers/writers situation. I think the AS should be better here (CFQ even more so, but CFQ has more overhead).
Click to expand...
Click to collapse
Of course, I just wanted to check if the noop is realy always better for the SD, as could perhaps infer from the post of farmatito
PS
Your ROM is amazing! Thanks!

Related

Cyanogen 4.1.6 - Compcache Disabled - Still taking up RAM - How to free?

Hello Everyone,
First, I did search. That is how I figured out how to disable compcache and enable the swap. It's working great, however since I am no longer using compcache, I would like to make available the RAM that it is using. Here are my free commands:
BEFORE:
# free
free
total used free shared buffers
Mem: 97928 96356 1572 0 8164
Swap: 24476 15516 8960
Total: 122404 111872 10532
AFTER:
# free
free
total used free shared buffers
Mem: 97928 96416 1512 0 300
Swap: 31768 3092 28676
Total: 129696 99508 30188
Notice that the Physical Memory is still the same number, despite compcache being disabled (well, atleast swapoff'd) Here is my userinit and you can see that it's just enabling the swap.
#!/system/bin/sh
##adb push userinit.sh /system/sd/
uname_r=`uname -r`
moddir=`find /system/modules -type d -name $uname_r`
#insmod=/system/bin/insmod
#$insmod $moddir/compcache/xvmalloc.ko;
#$insmod $moddir/compcache/ramzswap.ko disksize_kb=32768;
#$insmod $moddir/compcache/ramzswap.ko backing_swap=/dev/block/mmcblk0p3;
#mknod /dev/ramzswap0 b 253 0;
echo 20 > /proc/sys/vm/swappiness;
# Experimental settings
#echo 1 > /proc/sys/vm/page-cluster; # default: 3 Changes Page clustering from 8 to 2.
#echo 5 > /proc/sys/vm/laptop_mode; # default: 0 Helps keep SSD from getting worn.
#echo 5000 > /proc/sys/vm/dirty_expire_centisecs; # default: 3000
#echo 800 > /proc/sys/vm/dirty_writeback_centisecs; # default: 500
#echo 10 > /proc/sys/vm/dirty_background_ratio; # default: 5
#echo 16 > /proc/sys/vm/dirty_ratio; # default: 10
#
#swapon /dev/ramzswap0;
swapon /dev/block/mmcblk0p3;
#Over Clock CPU when in use, puts at lower freq when idol. # if you don't want it.
#echo 128000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq;
#echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq;
QUESTION: Is there any way to re-allocate the compcache section of my physical RAM to be used again? There is that 24476b that I cannot use, as I'm using a swap.
Thanks for your time.
andjohn said:
Hello Everyone,
First, I did search. That is how I figured out how to disable compcache and enable the swap. It's working great, however since I am no longer using compcache, I would like to make available the RAM that it is using. Here are my free commands:
BEFORE:
# free
free
total used free shared buffers
Mem: 97928 96356 1572 0 8164
Swap: 24476 15516 8960
Total: 122404 111872 10532
AFTER:
# free
free
total used free shared buffers
Mem: 97928 96416 1512 0 300
Swap: 31768 3092 28676
Total: 129696 99508 30188
Notice that the Physical Memory is still the same number, despite compcache being disabled (well, atleast swapoff'd) Here is my userinit and you can see that it's just enabling the swap.
#!/system/bin/sh
##adb push userinit.sh /system/sd/
uname_r=`uname -r`
moddir=`find /system/modules -type d -name $uname_r`
#insmod=/system/bin/insmod
#$insmod $moddir/compcache/xvmalloc.ko;
#$insmod $moddir/compcache/ramzswap.ko disksize_kb=32768;
#$insmod $moddir/compcache/ramzswap.ko backing_swap=/dev/block/mmcblk0p3;
#mknod /dev/ramzswap0 b 253 0;
echo 20 > /proc/sys/vm/swappiness;
# Experimental settings
#echo 1 > /proc/sys/vm/page-cluster; # default: 3 Changes Page clustering from 8 to 2.
#echo 5 > /proc/sys/vm/laptop_mode; # default: 0 Helps keep SSD from getting worn.
#echo 5000 > /proc/sys/vm/dirty_expire_centisecs; # default: 3000
#echo 800 > /proc/sys/vm/dirty_writeback_centisecs; # default: 500
#echo 10 > /proc/sys/vm/dirty_background_ratio; # default: 5
#echo 16 > /proc/sys/vm/dirty_ratio; # default: 10
#
#swapon /dev/ramzswap0;
swapon /dev/block/mmcblk0p3;
#Over Clock CPU when in use, puts at lower freq when idol. # if you don't want it.
#echo 128000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq;
#echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq;
QUESTION: Is there any way to re-allocate the compcache section of my physical RAM to be used again? There is that 24476b that I cannot use, as I'm using a swap.
Thanks for your time.
Click to expand...
Click to collapse
hahaha, compcache doesn't take up your physical RAM.
ccyrowski said:
hahaha, compcache doesn't take up your physical RAM.
Click to expand...
Click to collapse
Ok, so where is it taking from? I understood that compcache is a Compression Swap that runs in RAM. Is that incorrect?
This does not belong in this area plz post questions like this in the Q&A area.
Prod1702 said:
This does not belong in this area plz post questions like this in the Q&A area.
Click to expand...
Click to collapse
Sorry, Mods please close. Reposting in QA

[RFC] enable CONFIG_UACCESS_WITH_MEMCPY

I've tested enabling CONFIG_UACCESS_WITH_MEMCPY in a 2.6.33.4 kernel for CM-5.0.8.
Code:
Use kernel mem{cpy,set}() for {copy_to,clear}_user() (EXPERIMENTAL)
CONFIG_UACCESS_WITH_MEMCPY:
Implement faster copy_to_user and clear_user methods for CPU
cores where a 8-word STM instruction give significantly higher
memory write throughput than a sequence of individual 32bit stores.
A possible side effect is a slight increase in scheduling latency
between threads sharing the same address space if they invoke
such copy operations with large buffers.
However, if the CPU data cache is using a write-allocate mode,
this option is unlikely to provide any performance gain.
Empirically there seems to be an improvement not in snappiness but when
heavier i/o is involved. The only test i could think of so far is:
Code:
WITH CONFIG_UACCESS_WITH_MEMCPY
/ # hdparm -tT /dev/block/mmcblk0p2
/dev/block/mmcblk0p2:
Timing buffer-cache reads: hdparm: HDIO_DRIVE_CMD: Inappropriate ioctl for device
78 MB in 0.51 seconds = 154505 kB/s
Timing buffered disk reads: 42 MB in 3.03 seconds = 14171 kB/s
hdparm: HDIO_DRIVE_CMD: Inappropriate ioctl for device
Code:
WITHOUT CONFIG_UACCESS_WITH_MEMCPY
/ # hdparm -tT /dev/block/mmcblk0p2
/dev/block/mmcblk0p2:
Timing buffer-cache reads: hdparm: HDIO_DRIVE_CMD: Inappropriate ioctl for device
24 MB in 0.56 seconds = 43828 kB/s
Timing buffered disk reads: 15 MB in 3.11 seconds = 4938 kB/s
hdparm: HDIO_DRIVE_CMD: Inappropriate ioctl for device
Attached you will find a boot.img and modules.sqf or modules.tar.gz for CM-5.0.8 if you want to test it.
For a fast test you can use fastboot to boot the kernel:
Code:
sudo fastboot boot new_boot.img
For more extensive tests you maybe need to copy the modules to your device
(the .sqf or tar.gz depending on your setup DeathSPL/AnySPL) and eventually flash the boot image.
DON'T DO IT IF YOU DON'T KNOW EXACTLY HOWTO!!!
Attached also my kernel config.
Critics and hints on whether this could be useful are welcome.
Enjoy.

[90screenstate_scaling] Battery saving script modified for more configurability

I modified the original rookeemod-oxygen script, so that you can supply limits in array form, eg:
LIMITS=( [10]=384000 [30]=691200 [50]=806400 [75]=998400)
It is attached to this post
First time i used bash, so if it isnt correct, please correct me.
I tested it and it works
Credits go to original creators, see copyright notice.
Code:
#!/system/bin/sh
#
# screenstate_scaling - switch CPU frequency governor on screen state change
# originally by [email protected] (FloHimself)
# mod teppic74 / xda - 12/10/2010
# Changelog:
# * Test for battery charging/full - if so, use alternative settings.
# * Allow for alternative frequencies when battery is below 30, 20 and 10%
# Modified by twicejr / xda - 15/01/2011 - made alternative frequencies work with an array, for more dynamic configurability.
# Modifications Copyright 2010
# Copying and distribution of this file, with or without modification,
# are permitted in any medium without royalty provided the copyright
# notice and this notice are preserved.
# ( note: options for freqs: 245000 384000 422400 460800 499200 537600 576000 614400 652800 691200 729600 768000 806400 844800 883200 921600 960000 998400 1036800 1075200 1113600 )
AWAKE_GOVERNOR="interactive"
AWAKE_GOVERNOR_FREQENCY_MAX="1113600"
AWAKE_GOVERNOR_FREQENCY_MIN="245000"
AWAKE_SAMPLING_RATE="40000"
AWAKE_CHARGING_GOVERNOR="interactive"
AWAKE_GOVERNOR_CHARGING_MAX="1113600"
AWAKE_GOVERNOR_CHARGING_MIN="499200"
SLEEP_GOVERNOR="interactive"
# irrelevant max for powersave
SLEEP_GOVERNOR_FREQENCY_MAX="245000"
SLEEP_GOVERNOR_FREQENCY_MIN="245000"
#LIMITS=( [10]=384000 [20]=460800 [30]=614400 [40]=729600 [50]=768000 [60]=806400 [70]=883200 [80]=998400 )
LIMITS=( [10]=384000 [30]=691200 [50]=806400 [75]=998400 )
SETCPU="com.mhuang.overclocking"
(while [ 1 ]
do
LIMIT_REACHED="0"
AWAKE=`cat /sys/power/wait_for_fb_wake`
BSTAT=`cat /sys/class/power_supply/battery/status`
if [ "$BSTAT" = "Charging" ] || [ "$BSTAT" = "Full" ] && [ ! "`pidof $SETCPU`" ]; then
echo $AWAKE_GOVERNOR_CHARGING_MIN > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo $AWAKE_GOVERNOR_CHARGING_MAX > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo $AWAKE_CHARGING_GOVERNOR > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
log -p i -t screenstate_scaling "*** awake ***: $BSTAT - switching CPU frequency governor to -> $AWAKE_CHARGING_GOVERNOR"
elif [ $AWAKE = "awake" ] && [ ! "`pidof $SETCPU`" ]; then
echo $AWAKE_GOVERNOR_FREQENCY_MIN > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo $AWAKE_GOVERNOR > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
BATT=`cat /sys/class/power_supply/battery/capacity`
for PERCENTAGE in ${!LIMITS[@]} ;
do
if [ $BATT -lt $PERCENTAGE ]; then
echo ${LIMITS[$PERCENTAGE]} > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
LIMIT_REACHED="1"
break
fi
done
if [ $LIMIT_REACHED = "0"]
echo $AWAKE_GOVERNOR_FREQENCY_MAX > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
fi
if [ $AWAKE_GOVERNOR = "ondemand" ]; then
echo $AWAKE_SAMPLING_RATE > /sys/devices/system/cpu/cpufreq/ondemand/sampling_rate
fi
log -p i -t screenstate_scaling "*** awake ***: switching CPU frequency governor to -> $AWAKE_GOVERNOR"
AWAKE=
fi
SLEEPING=`cat /sys/power/wait_for_fb_sleep`
if [ $SLEEPING = "sleeping" ] && [ ! "`pidof $SETCPU`" ]; then
echo $SLEEP_GOVERNOR_FREQENCY_MIN > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo $SLEEP_GOVERNOR_FREQENCY_MAX > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo $SLEEP_GOVERNOR > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
log -p i -t screenstate_scaling "*** sleeping ***: switching CPU frequency governor to -> $SLEEP_GOVERNOR"
SLEEPING=
fi
done &)
i dont want to sound silly, but isnt it "easier" to simply use SetCPU?
waebi said:
i dont want to sound silly, but isnt it "easier" to simply use SetCPU?
Click to expand...
Click to collapse
Yes it is, but i think that in oxygen clean rom is more important
I find it better than having yet another app boot up at start.
Wont the handset be sluggish to wake from 245MHZ and powersave governor?!
Jagdish84 said:
Wont the handset be sluggish to wake from 245MHZ and powersave governor?!
Click to expand...
Click to collapse
I dunno, I set it to interactive: SLEEP_GOVERNOR="interactive"
.
I just think that interactive in combination with scaling down is just as "power-saving" as ondemand in the end, and it feels faster
twicejr said:
I dunno, I set it to interactive: SLEEP_GOVERNOR="interactive"
.
I just think that interactive in combination with scaling down is just as "power-saving" as ondemand in the end, and it feels faster
Click to expand...
Click to collapse
I agree, i got mixed up didnt notice you were using interactive
i would give it a shot but i aint using oxygen rom and ssts aint lying in init.d...
nice script nontheless

[Kernel]Skyrocket[2.6.35.14](010)OC~1.73GHz/GPU OC/OTG/UV/SLQB/BLN[Mar-09]

NOTICE: This is COMPATIBLE with ALL Samsung Rooted Stock and Custom ROMs
For frequency control use fauxclock from Google Play
Just a statement regarding kernel source: The Kernel Source is of course covered under GPL version 2. Free software does NOT mean no work or time was spent working on it. I have donated a large sum of my free time to hack this kernel. If you use my modified kernel source in parts or in its entirety, I kindly ask you mention its origins and to send me a github pull request or PM whenever you find bugs or think you can help improve my kernel hack further. This way the entire community will truly benefit from the spirit of open source. Thank you!​
Hi XDA members and fellow Samsung users:
This is my sixteenth kernel hack. I want to thank my Team Kang tea mates Roman, Whitehawks and CMenard, and several others I cannot recall for inspiring me to venture into this unfamiliar territory for me.
What is a Kernel? The Kernel is the Foundation in which everything else builds upon in any software system.
[Car Analogy]: Kernel is like the Engine, Electrical system and the Transmission to a car. The Library, Framework and the Apps [AKA ROM] are the body frame and the rest of the Car.
​
THIS KERNEL is BASED ON Samsung Source Code. So it is COMPATIBLE ONLY WITH Samsung Gingerbread Builds.
Please DO NOT use any task killers, they DO NOT improve performance nor battery life. They INTERFERE with your phone's stability (more crashes) and App compatibilities (Forced Close).
CleanCache (via ZCache backend)
ZCACHE is a new technology I introduced to Qualcomm Kernel. ZCACHE is a compressed cache similar to ZRAM but the similarity ends there. ZCache is meant to provide as many "cleancache" pages (non-dirty or untouched "virgin" memory) to apps that request for new memory. CleanCache is very easy to allocate and no additional penalty are required to hand them out, so having more CleanCache pages will improve performance. Under heavy memory pressure, often times the kernel will NOT have enough CleanCache pages, so the kernel has to do EXTRA work to reclaim dirty cache pages and clean them for the new apps that's requesting for them. The described process creates a performance hit for the kernel and the app, so the idea is to use compression to create more CleanCache pages available for use. Of course there's a penalty to pay for using compression, but the trade-off between compression penalty and the penalty for reclaiming dirty cache pages and allocating them after cleaning is smaller for compression, so in the end, CleanCache should add more performance.
ZRAM (aka CompCache aka RAMZSwap)
ZRAM is an updated version formally known as CompCache and RAMZSwap. It was originally designed for 2.6.38.xx kernels, I have backported to our 2.6.35.xx kernel. ZRAM allows real-time compression of memory objects in RAM thus reducing memory pressure for the Linux kernel and can keep more apps in memory longer (more apps in RAM == better performance, less fetching from slower MMC or SDCard). Compression, however, is not Free. Some CPU cycles are required to do the compress/decompression, so there's a slight penalty for it. The original CompCache / RAMZSwap required a user space binary to control its behavior which adds additional penalty to performance, but the new version ZRAM eliminated the need for a separate dedicated daemon, thus reducing the overhead and increased performance from the old CompCache by 20%. Therefore, with the newer implementation of ZRAM interface, the performance penalty is almost negligible.
Joe's RCU (Optimized for Small SMP systems - NOT YET ADDED)
Joe Korty has created an RCU for small SMP systems (> 32 cores). His approach is to isolate all the Garbage Collection (GC, a slow time consuming but necessary processing) to a single core, thus allowing other cores to ONLY work on real required processing. This will allow the additional cores to complete their assigned tasks as fast as possible (not bogged down by GC) then immediately go back to a suspended state (saving battery).
Fast No Hz RCU (Optimized for SMP operations)
Fast NoHz is an optimized version of the traditional Tree RCU. Many new kernels are using the Tickless NoHz design. This RCU is tailored and designed to work with the new NoHz kernel system.
SmartAssV2 Governor (Balanced - NOT COMPATIBLE WITH QUALCOMM 8x60)
This governor has a built-in "profile" similar to SetCPU, so screen off will use lower clock rate thus conserve more battery, but it also has a fast wake up feature so that user interaction will not see the lag when switching from Sleep to Wake state.... (So SetCPU Profiles are sorta redundant when using this governor, you can still use SetCPU to OC to higher than default Clock frequency).
Interactive Governor (Performance - NOT COMPATIBLE WITH QUALCOMM 8x60)
This governor is designed to put more priority to User Interface (UI aka Apps) tasks, therefore appears more responsive then the traditional OnDemand governor. So if you want the smoothest UI interaction, this governor is for you...
Brain F*ck Scheduler - (BFS - NOT COMPATIBLE WITH QUALCOMM 8x60)
This scheduler is designed to be simple and speedy tailor specifically for user interface type systems such as desktop/smart phone devices where user interaction is MORE important than serving 1 million web requests (CFS, the default scheduler) at the same time (think of nimble desktop workstations vs large corporate servers).
SLQB - (SLAB allocator with Queue)
This memory allocator is designed for small number of CPUs system (such as desktop or smart phone devices). This allocator is design to be simple and it is optimized for using order-0 pages as much as possible (order-0 pages are the simplest therefore quickest type of memory in a Linux system to allocate). Not all kernels are using SLQB including CM7 main line...
Fair Budget Queue (BFQ I/O scheduler)
This I/O scheduler is an improvement on top of Completely Fair Queue (CFQ). CFQ is fair in terms of time but not in terms of throughput / bandwidth, so BFQ make sure that both time and throughput / bandwidth are balanced across all requests.
Installation Instructions:
Here's a step by step instruction to install this kernel:
[ CFS ] (Mainline Edition - should work with ALL phones!)
The File ==> Skyrocket kernel 010m (1.73 GHz, L2 speed up to 1.56 GHz) <==
[ CFS ] (Ultimate Edition - should work with most phones but NOT GUARANTEED!)
The File ==> Skyrocket kernel 010u (1.73 GHz, L2 speed up to 1.56 GHz, GPU 3D @ 320 MHz, GPU 2D @ 220 MHz, CleanCache Enabled) <==
1. download the above file (via phone directly or to a PC)
2. copy the downloaded zip file to /sdcard/download/
3. Open ROM Manager and select "Reboot into Recovery" and select "OK"
4. Once in recovery, select "wipe cache partition", select "Yes", then select "advanced", then select "Wipe Dalvik Cache", then select "Yes" again. Once finished, click the back button to go back to the main recovery menu. On that menu, select "Install Zip From SDCad", then select "Choose zip from SDCard", then go to /sdcard/download and select the downloaded zip file and let it run its script.
5. Once the script is done, select "reboot system now"
Note: After FLASHING, the first reboot may take longer than usual, please be patient... After the first reboot, it may lag during initial load (let everything finish loading). Once everything is loaded and phone is ready for use, reboot the phone a 2nd time and the lag will be gone and everything should be silky smooth... [/b]
[ Advanced Users: ]
[ Optional: ]
[ For Kernel Devlopers ONLY: ]
The File ==> My Global VDD_TABLE for under volt patch <==
Optional Under voltage:
Code:
[ to over volt ALL frequencies by 25000 uv (microvolts) ]
echo "+25000" > /sys/devices/system/cpu/cpufreq/vdd_table/vdd_levels
[ to under volt ALL frequencies by 25000 uv (microvolts) ]
echo "-25000" > /sys/devices/system/cpu/cpufreq/vdd_table/vdd_levels
[ to set a specific frequency (ie 1.18 GHz)
with a specific voltage (ie 1.0875 volts) ]
echo "1188000 1087500" > /sys/devices/system/cpu/cpufreq/vdd_table/vdd_levels
CPU Frequency Voltage Table Example
Code:
192000: 812500
310500: 812500
384000: 812500
432000: 812500
486000: 837500
540000: 850000
594000: 862500
648000: 875000
702000: 900000
756000: 925000
810000: 937500
864000: 962500
918000: 962500
972000: 962500
1026000: 975000
1080000: 987500
1134000: 1000000
1188000: 1012500
1242000: 1025000
1296000: 1050000
1350000: 1075000
1404000: 1100000
1458000: 1112500
1512000: 1125000
1566000: 1150000
Optional: Stock Clock Frequencies for Dual CPUs
Code:
su
echo 192000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo 1188000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 1 > /sys/devices/system/cpu/cpu1/cpufreq/online
echo 192000 > /sys/devices/system/cpu/cpu1/cpufreq/scaling_min_freq
echo 1188000 > /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
NEWS BULLETIN:
Version 010 is OUT for skyrocket variant!
Please don't hesitate to talk among yourselves and help each other out... The XDA community is what inspired me to hack kernels for everyone since everyone here is nice and helpful to each other... Keep helping each other.... Famous proverb: It's better to give than to receive...
BUGS:
Not All CHIPS ARE CREATED EQUAL
TO DO:
version 1.x.x -- Haven't thought about it yet...
History:
See Post below...
Standard Disclaimer: Not responsible for bricking your phone, voiding your warranty, or any other pain or suffering you may feel as result of using this kernel!!!
My github Complying with GPL and XDA rulez
Follow me on
:
If you find this Kernel useful, feel free to hit the [Thanks] button below
Version History
Version 001 (Deprecated)
internal
Version 002 (Deprecated)
internal
Version 003 (Deprecated)
Overclocking: reduced max to 1.728 GHz due to PLL limitations
Overclock: Initial overclock patch
Added Global CPU Voltage table used for adjusting voltage table
Added Scaling_Available_Frequencies back to cpufreq sysfs interface
mm: retry page fault when blocking on disk transfer
PM / Sleep: Drop pm_op() and pm_noirq_op()
PM / Sleep: Unify diagnostic messages from device suspend/resume
sched/rt: code cleanup, remove a redundant function call
ARM: Add optimised swahb32() byteswap helper for v6 and above
hugetlb: Replace BUG() with BUILD_BUG() for dummy definitions.
kernel.h: Add BUILD_BUG() macro.
nfs: writeback pages wait queue
block: limit default readahead size for small devices
PM / Suspend: Fix bug in suspend statistics update
make default readahead size a kernel parameter
tty: disable kernel CIQ tty driver
mm/vmalloc.c: eliminate extra loop in pcpu_get_vm_areas error path
PM / Sleep: Remove pm_runtime_suspended() from __pm_generic_call()
lockdep: print lock name for lockdep_init_error
init/main.c: execute lockdep_init as early as possible
kernel:sched: LOAD_FREQ (4*HZ+61) avoids loadavg Moire
sched: don't call task_group() many times in set_task_rq()
dm-cache: block level disk cache target for device mapper
partition_sched_domains: Do not destroy old sched domain on cpu_up
sched: Do not block when waiting to free old root domain
rcu-tree: Check for extended quiescent state at start of gp
printk: Don't allow cpu to get console lock during hotplugging
cpu-hotplug: Add the function 'cpu_hotplug_inprogress'
msm: platsmp: Remove extraneous boot_secondary delay
CPU hotplug, PM: Remove unused symbol 'suspend_cpu_hotplug'
kernel: Set the command name of the idle tasks in SMP kernels v3
net: Reorder incoming packets in PPPoLAC and PPPoPNS.
PM: wakelocks: Display wakelocks preventing suspend by default
PM: wakelocks: Don't report wake up wakelock if suspend aborted
arm: Implement ticket spin-locks
Decompressors: Get rid of set_error_fn() macro
ARM: 6428/1: add cpu_idle_wait() to support CPUidle on SMP systems.
msm: Kconfig: Enable inline lock functions
crypto: crc32c should use library implementation
crc32: Bolt on crc32c
crc32-add-slicing-by-8.diff
crc32-add-real-8-bit.diff
lib/sha1: use the git implementation of SHA-1
ARM: support XZ compressed kernels
Squashfs: Add XZ compression configuration option
Squashfs: add XZ compression support
decompressors: add boot-time XZ support
decompressors: add XZ decompressor module
CFS Auto Group V2 - Changes since last:
Added NEON and other Snapdragon optimizations
compilation: fix many Samsung sloppy coding warnings (part 1)
patch: Add BFQ I/O scheduler by Paolo Valente
patch: add SLQB memory allocator by Nick Piggin
kernel patch: 2.6.35.13 -> 2.6.35.14
make: fix Kconfig errors by Samsung
kernel patch: 2.6.35.12 -> 2.6.35.13
kernel patch: 2.6.35.11 -> 2.6.35.12
Initial Commit for T-Mo Hercules!
Version 004 (deprecated)
fail!
Version 005 (deprecated)
re-baseline using Romanbb's initial commit to resolve compilation issues and problems.
all patches from version 003 still apply!
Version 006 (deprecated)
board/device: Add GPU turbo boost for 2D as well
watchdog: increase pet time to ten seconds
board/devices: enable GPU turbo mode @ 320 Mhz
OTG: Fix fast plug out/in wall charger charging issue
gadget: f_mtp: Fix problems transferring files from device to host
gadget: f_mtp: Make sure request is dequeued if transfer is canceled
gadget: f_mtp: Zero length packet fixes
gadget: f_mtp: Support for file transfer length greater than 4 gigabytes
gadget: f_mtp: Return zero result for successful file transfer.
gadget: f_mtp: MTP driver cleanup:
msm_otg: Increment PM usage counter for suspend failure cases
defconfig: 8x60: Enable USB accessory function
gadget: android: Restore default composition upon accessory disable
gadget: f_accessory: Set bNumEndpoints to correct value of 2
gadget: f_accessory: Add string for accessory's unique serial number
gadget: f_accessory: Clear disconnected flag when driver file is opened
gadget: f_accessory: Clear previous strings on ACCESSORY_GET_PROTOCOL
gadget: f_accessory: Clear accessory strings when USB is disconnected
gadget: f_accessory: Misc improvements and cleanup:
gadget: f_accessory: New gadget driver for android USB accesories
gadget: android: Support switching vendor ID when configuration changes
audio: qdsp6v2: Modify the wait timer for apr registration
audio: qdsp6v2: Reduce the pcm write timeout value
audio: qdsp6v2: Fix crash with erroneous aac playback
audio: qdsp6v2: Send session ID in RTAC APR packet
audio: qdsp6v2: Disable idle wakelocks for pcm driver
audio: qdsp6v2: Fix for enabling dolby aac decoder.
audio: qdsp6v2: Unification changes for AAC Multichannel decoder
audio: qdsp6v2: Add Decoder Unification changes.
audio: qdsp6v2: Enabling Dolby pulse aac codec.
audio: qdsp6v2: Add fmt type adif in aac driver.
audio: qdsp6v2: Add support for aac dual mono playback
audio: qdsp6v2: Address multiple seek issues in AAC 5.1
audio: qdsp6v2: Add support for multichannel AAC.
audio: qdsp6v2: Add support for output port flush
audio: qdsp6v2: correction in allocation of number of dma_channels.
camera: configure the mipi csi based on lanecount
camera: Postprocessing framework changes
camera: Fix recording state machine bug
camera: Remove additional check in msm_queue_drain
rpc: While powering down flush all the rpcrouter workqueues
rpc: Reader thread to allocate memory without holding a spinlock
rpc: Reorganize the usage of spinlocks in RPC Router reader thread
smd_pkt: Extend read operation to receive data larger than SMD FIFO
gsmd: Save interrupt state when using spinlocks
audio: qdsp6v2: Close smd ports upon failure to open.
msm_fb/hdmi: fixed merge error
HDMI: EDID > 2 blocks, params not set.
msm_fb: Check for ACP and ACFG register before reset core.
HDMI: CEC: Hardware FSM reset.
msm_fb: Remove Audio Packet Control Register setup
HDMI: Driver support for CEC feature
HDMI: Driver support for CEC feature
HDMI: Remove audio packet setup for ACP, ISRC
rtc-msm: Fix uptime corruption due to slow clock overflow.
msm_serial_hs: Fix issue related to sleeping in invalid context
msm_serial_hs_lite: Set UART Clock rate to zero, when it is disable
tsens: Add suspend/resume for TSENS
kgsl: New low power level
kgsl: Count a percentage of _io time
kgsl: Clocks should be set to the active level during NAP
kgsl: Add a periodic check to turn the TZ algorithm on
kgsl: Update pwrlevel_change
input/keyboard: add BLN support
Version 007 (deprecated)
video/msm/mdp: update mdp driver from ATT SkyRocket Source
msm_fb: Removing HDCP timedout error.
msm_fb: Fixing Aspect Ratio
thermal: msm_tsens: Fix clearing interrupt bit on resume
msm: sdio: Replace banned/deprecated strcmp with strncmp
mmc: msm_sdcc: use prog_done for all commands having R1B response type
msm: vidc: Fix handling EOS with bitstream error.
staging: zcache: remove zcache_direct_reclaim_lock
staging: zcache: reduce tmem bucket lock contention
staging: zcache: fix crash on cpu remove
staging: zcache: fix cleancache crash
Staging: zcache: signedness bug in tmem_get()
staging: zcache: fix crash on high memory swap
staging: zcache: fix typos
staging: zcache: fix possible sleep under lock
zcache: Fix build error when sysfs is not defined
zcache: Use div_u64 for 64-bit division
staging: zcache: include module.h for MODULE_LICENSE
staging: zcache: module is GPL
staging: fix zcache building
staging: zcache: support multiple clients, prep for KVM and RAMster
staging: zcache: fix memory leak
staging: Allow sharing xvmalloc for zram and zcache
zram: Set initial disksize to some default value
zram: Simplify zram disk resizing interface
zram: Make gobal variables use unique names
zram: Kernel config option for number of devices
zram: Fix sparse warnings
zram: driver update to latest stable release on 2011-07-18
kernel:mm: Backported vzalloc to support ZRAM
Staging: zram: simplify zram_make_request
Staging: zram: make zram_read return a bio error if the device is not
initialized
Staging: zram: round up the disk size provided by user
Staging: zram: make ZRAM depends on SYSFS
zram: various improvements and cleanups
zram: Rename ramzswap to zram in documentation
zram: Rename ramzswap to zram in code
zram: Rename ramzswap files to zram
zram: Support generic I/O requests
staging:zcache: Enable zcache by default
drivers/staging: zcache: dynamic page cache/swap compression
Version 008 (Deprecated)
Update baseline source code with Skyrocket specific bits from ATT SkyRocket Source Release
Version 009 (Short Term Release)
[ CFS ] (Mainline Edition - should work with ALL phones!)
The File ==> Skyrocket kernel 009m (1.73 GHz, L2 speed up to 1.56 GHz) <==
[ CFS ] (Ultimate Edition - should work with most phones but NOT GUARANTEED!)
The File ==> Skyrocket kernel 009u_r2 (1.73 GHz, L2 speed up to 1.56 GHz, GPU 3D @ 320 MHz, GPU 2D @ 220 MHz) <==
mmc: core: Prevent too long response times for suspend
msm_fb: [HDMI_COMPLIANCE] Update audio ARCs for 480p
msm: audio: qdsp6v2: Fix memory leak in aac encoder
mm-camera: configure the mipi csi based on lanecount
RCU: JRCU 2.6.35.13, consolidated
Reverted battery draining patches
Version 010 (Current)
Fixed USB Host Notification for Skyrocket (not supported)
Remove Android USB Gadget Accessory for Skyrocket (not supported)
msm: vidc: Remove endianness change for 1080p firmware. …
vidc: 1080p: Increase context memory size of the H.264 encoder. …
zcache: avoid AB-BA deadlock condition …
msm_fb: HDMI-CEC: Line latch patch …
msm: camera: Free buffers from frame queue at open …
msm: vidc: insert break in switch-case statement …
msm: camera: Update csi interrupt trigger conditon …
msm: vidc: Remove endianness change for 1080p firmware. …
vidc: 1080p: Increase context memory size of the H.264 encoder. …
msm: qdsp6v2: Invalid memory access of timpani regset array …
sched: disable GENTLTE_FAIR_SLEEPERS for better performance on Android
revert back to FasNoHz RCU
Skyrocket Source Update: Add debug switch to board PM
Skyrocket Source Update: misc board driver updates
Skyrocket Source Update: regulator driver update
Skyrocket Source Update: misc minor driver clean ups
Skyrocket Source Update: Make CIQ a standalone option so it can be di…
Skyrocket Source Update: Update Headset Jack detection driver
Skyrocket Source Update: Update CHARM Modem Interface driver
Skyrocket Source Update: Update battery driver
Skyrocket Source Update: Update GPIO driver
Skyrocket Source Update: update misc USB drivers
Skyrocket Source Update: Update Timpani Profiles for Skyrocket and He…
Skyrocket Source Update: Update Touch Screen Driver
Skyrocket Source Update: Update Power Supply Driver to fix DDR issues
Skyrocket Source Update: Update Camera Media driver
Skyrocket Source Update: Add Samsung BT WL keyboard support
Skyrocket Source Update: Update BRCM WiFi driver
Skyrocket Source Update: Update Misc HDMI and Video drivers
Skyrocket Source Update: Update LowMemoryKiller OOM_Adj settings
Skyrocket Source Update: Add Smart Dimming
Skyrocket Source Update: Add suspend_sys_sync to kernel power management
[ Add-Ons ]
Gideonx's scripts for OC / UV.
http://forum.xda-developers.com/showpost.php?p=20946429&postcount=574
Make sure you hit [ thanks ] button for him
Yes finally going official! People go ahead and give it try its great kernel. Nothing to worry about. battery life is great too.
Thank you Faux!!
Is GideonX's script compatible with the SkyRocket as well?
Some benchmarks I ran using this kernel from the T989 Herc.
Treatcon said:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
This image has been resized, click here to see the fullsize original
This image has been resized, click here to see the fullsize original
Loving this kernel, doing a little stress testing for under volting. Not bad benchmarks! UV to -100000 across the board with GideonX script and managed to keep the same benchmark scores, +/- 10 or so.
Click to expand...
Click to collapse
Treatcon said:
Thank you Faux!!
Is GideonX's script compatible with the SkyRocket as well?
Some benchmarks I ran using this kernel from the T989 Herc.
Click to expand...
Click to collapse
Yes, Gideonx's script is compatible with all of my SGS2 variants.
Thanks again for the help!!!!! And for all the haters now feel the love
Monster cm7
What's ur oc/uc?
tacotino said:
Thanks again for the help!!!!! And for all the haters now feel the love
Monster cm7
Click to expand...
Click to collapse
Great to have you on board. You did great things back when I had the mt4g. Always very involved.
Sent from my SAMSUNG-SGH-I727 using Tapatalk
appdroid said:
What's ur oc/uc?
Click to expand...
Click to collapse
I don't have it UV/ I leave it all alone.. just have some settings.. like
Screen off run Max at 384 min 384
20< 1000mhz
That's it nothing crazy
Monster cm7
thanks for all work and the new betas faux, appreciate the time bruh.
So far this Kernel is the best one i have seen on battery with OC'ing.
Awesome, thanks for developing this. Will check out the otg tonight, a feature I was longing to have on an OC Kernel.
How's the battery life with this Kernel? Does anyone see any problems installing this with the Super Stock 2.3.6 ROM?
I am not seeing the smartASSv2 governor. Anyone else seeing it?
Battery life is great its been 15hours 16% left. I m heavy user flashed new stuff, benchmarks and all stuff during these 15hrs.
dvandam said:
How's the battery life with this Kernel? Does anyone see any problems installing this with the Super Stock 2.3.6 ROM?
Click to expand...
Click to collapse
SalTNutz said:
I am not seeing the smartASSv2 governor. Anyone else seeing it?
Click to expand...
Click to collapse
Im pretty sure it does not have this option........
SalTNutz said:
I am not seeing the smartASSv2 governor. Anyone else seeing it?
Click to expand...
Click to collapse
Looks like powersave isn't there either...
He listed it in his post on the first page.
---------- Post added at 04:43 PM ---------- Previous post was at 04:42 PM ----------
the2rrell said:
Im pretty sure it does not have this option........
Click to expand...
Click to collapse
From his post
SmartAssV2 Governor (Balanced)
This governor has a built-in "profile" similar to SetCPU, so screen off will use lower clock rate thus conserve more battery, but it also has a fast wake up feature so that user interaction will not see the lag when switching from Sleep to Wake state.... (So SetCPU Profiles are sorta redundant when using this governor, you can still use SetCPU to OC to higher than default Clock frequency).
appdroid said:
Battery life is great its been 15hours 16% left. I m heavy user flashed new stuff, benchmarks and all stuff during these 15hrs.
Click to expand...
Click to collapse
Does undervolting help with battery life?
it will help but no need. Kernel does best job without tweaking.
dvandam said:
Does undervolting help with battery life?
Click to expand...
Click to collapse

[Q] Linux 'cpulimit' equivalent

Hello,
New here at XDA, I've done a lot of reading here and found the site extremely useful in the past, so I thought I'd join up. Thanks for all the help you have provided!
Anyway, I am wondering if anybody knows of an Android equivalent to 'cpulimit' for Linux.
I am looking for a way to limit maximum CPU usage for a single process.
Thank you.
Bryan
Well, I have come to the conclusion there is no CPU limiter for Android, unless cpulimit could be compiled for it, which I have not tried.
However, this solution seems to work. If anybody is interested, I figured I'd update my thread.
Use the renice cmd.
Negative number raises scheduling priority, positive lowers it. From -20 to 20, 0 being the base priority.
I found that a value of even 5 limits the CPU usage of a process greatly when another processes is demanding a lot of CPU ad the same time, the one with base priority will receive much more attention.
Using Opera Mini as example:
# ps | grep opera
ps | grep opera
app_94 30814 93 114260 16956 ffffffff afd0c53c S com.opera.mini.android
Found PID of 30814
# ps -p 30814
ps -p 30814
USER PID PPID VSIZE RSS PRIO NICE RTPRI SCHED WCHAN PC NAME
app_94 30814 93 114260 16956 20 0 0 0 ffffffff afd0c53c S com.opera.mini.android
Now we see NICE value is 0 - base
# renice -1 30814
renice -1 30814
renice process to -1, increase priority slightly
# ps -p 30814
ps -p 30814
USER PID PPID VSIZE RSS PRIO NICE RTPRI SCHED WCHAN PC
NAME
app_94 30814 93 114260 16956 19 -1 0 0 ffffffff afd0c53c S com.opera.mini.android
This shows new NICE value worked, and is now -1.
It can also change priority for processes started by a particular user or group.
There is kind of an extra step in there.
ps -p | grep opera
Could use this to see pid and nice value all at once.
Sent from my Samsung

Categories

Resources