Active Topics

 


Poll: Delet the values from the speedpatch?
Poll Options
Delet the values from the speedpatch?

Reply
Thread Tools
Posts: 856 | Thanked: 1,681 times | Joined on Apr 2010 @ Aleppo ,Syria
#1
HELLO Everybody
This Guide Has 5 Parts :
1: Speed Patch : To speed up N900
2: Battery Patch : To Have A long battery life
3: Battery Patch Non KP : For non kernel-power users
4: FAQS : Frequently asked questions about batterypatch
5: Tweaks : To make you enjoy N900


Part 1: Speed Patch


INFO

A lot of you must have heard about the 200 lines to speed up linux while blackhat announced 4 lines to do that and it is called miracle patch
anyway neither of the available tutorials on internel are working on N900

BUT For Fortunately i was able to apply it to Maemo 5 on N900!!!!!

You will notice a lot of improvements in hildon-desktop
and basically every thing will be improved

CURRENT VERSION : 4.0

What Does It Do
The CFS (completely fair scheduler) in our phone's kernel manages the allocation of resources (cpu/mem) between tasks.
It was designed to cope with server-class machines such as web servers and databases, giving all tasks equal access to resources.
This means if a server is really busy, then all tasks on the machine slow down equally.
Desktop/mobile class machines shouldn't work the same way as servers though.
They have a human user who expects the machine to respond and give feedback within a certain time.
If a machine is slow to respond, the user loses some sense of control over the machine.
This patch addresses the problem by taking note of what the user is doing right now, and using that information to accelerate the current task, and decelerate other tasks on the system.
The user won't notice the background stuff going slower, they will just see their app working fast. The patch does this by creating multiple classes of task
-------------------------------------------
/dev/cgroup/cpu/tasks
/dev/cgroup/cpu/desktop/tasks
/dev/cgroup/cpu/applications/tasks
/dev/cgroup/cpu/applications/standby/tasks
/dev/cgroup/cpu/applications/launcher/tasks
-------------------------------------------
If you look at the contents of these files, you'll see the process IDs of all the tasks in each class. CPU and memory are shared out to these classes using the files "cpu.shares", and "memory_limit_in_bytes".
When lots of tasks are demanding CPU/memory at once, the resources are handed out to tasks depending on their share.
This is why your phone feels nicer when you have this patch - the kernel automatically classifies tasks and devotes more of cpu/mem to the "application" and "desktop" class tasks, and much less to other classes like "standby".


Installing Speed Patch

Code:
sudo gainroot
apt-get install speedpatch
Then Reboot twice

Uninstalling Speed Patch
To remove the patch:

Code:
sudo gainroot
apt-get purge speedpatch
Then Reboot

------------------------------------------------------


Part2 : BATTERY PATCH

INFO

This Tweak Improves The Battery Life of Our N900
For Standby And Continues Time Of Usage

CURRENT VERSION IS: 8.2
Compatible with all KP versions

When device is locked : or system is inactive or the brightness is off (except when having a call)

1-) vfs_cache_pressure goes to 10 : it's proven that doing this saves a lot of battery on standby
2-) change to underclock profile : vdd1 vdd2 enabled, (but with KPv48=> only vdd1 enabled) powersave_bias=20
3-) renice 1 some processes
4-) improve the response when receiving a call by changing MINFREQ to 600 but it returns to 250 after answering the call .. so no OC while talking with N900
5-) pausing some processes that sucks battery in idle mode (TESTING)

When the device is unlocked or the brightness is on

1-) vfs_cache_pressure goes back to 100
2-) overclock profile is loaded : vdd1 vdd2 enabled, conservative mode and powersave_bias=20
3-) renice 0 the previous processes
4-) Continue of the paused processes (TESTING)

Extra Feature

Someone may say "i don't want my N900 to use underclock profile and pause some processes when i lock the screen because i'm downloading a large application to install it"

Solution is :
Open the keyboard, lock the screen and leave the keyboard opened
in that case batterypatch is temporary disabled
so locking the screen will activate it's features


Dependencies

dbus-scripts, kernel-power-flasher | kernel-power-bootimg, kernelpower-settings

Installing Battery Patch
Code:
sudo gainroot
apt-get install batterypatch

Uninstalling Battery Patch

Code:
sudo gainroot
apt-get purge batterypatch
------------------------------------

Part3 : BATTERY PATCH Non kernel-power users

INFO

This version is for people who doesn't use kernel-power
This Tweak Improves The Battery Life of Our N900
ONLY ON STANDBY
UNLIKE THE Battery Patch Full version

CURRENT VERSION IS: 6.0

When device is locked : or system is inactive

1-) vfs_cache_pressure goes to 10 : it's proven that doing this saves a lot of battery on standby
2-) renice 1 some processes

When the device is unlocked or the brightness is on

1-) vfs_cache_pressure goes back to 100
2-) renice 0 to the previous processes
Dependencies

dbus-scripts

Installing Battery Patch Non kernel-power users
Code:
sudo gainroot
apt-get install batterypatch-non-kp

Uninstalling Battery Patch Non kernel-power users

Code:
sudo gainroot
apt-get purge batterypatch-non-kp
----------------------------------------------------------------------

There are also 2 extra packages in devel:
1-batterypatch for unstable devices : for those who have really unstable N900s (current version is : 3.0)
2-batterypatch testing : just like the normal batterypatch but includes new unstable tweaks (current version is : 7.1)



----------------------------------------------------------------------


CHECKING

1. To check if Speedpatch was installed Correctly:

Open an xterm window
if no errors appeared that means speedpatch is applied

or
Code:
cd /dev/cgroup/cpu/user/
ls
You Should see some files
-------------------
2.To check if Battery Patch was applied :

Code:
sudo gainroot
echo 1000 >> /proc/sys/vm/vfs_cache_pressure
Then lock the phone and unlock it
Then
Code:
cat /proc/sys/vm/vfs_cache_pressure
you should see 100
If so then the patch is applied

PART4 : FAQS

1-)
Q-) I cannot change max frequency with qcpu or any other gui cpu freq changer!!!!

A-) To change the max cpu frequency you need to edit the max freq at :
/opt/batterypatch/profiles/overclock-new #(if using kernel-power 49 or newer) with any text editor
or
/opt/batterypatch/profiles/overclock-old #(if using kernel-power 48 or older) with any text editor

ex : Leaf Pad
Code:
sudo gainroot
apt-get install leafpad
leafpad /opt/batterypatch/profiles/overclock-new
and then change the maxfreq to anything you want down than save and quit
IMPORTANT !!! IF YOU HAVE AN UNSTABLE N900
IT'S RECOMMENDED TO DISABLE VDD1 ... CHANGE IT TO 0
IF YOU WANT TO OVERCLOCK MORE THAN 805
AS BATTERYPATCH MAXFREQ IS 805

Then reboot to take effect
(YOU CAN TEMPORARLY CHANGE THE SPEED BY EDITING THE OVERCLOCK FILE IN /usr/share/kernel-power-settings
BUT IT WON'T BE SAVED UNTILL YOU EDIT THE ONE IN /opt/batterypatch/profiles

2-)
Q-) My N900 shows low battery and when i lock the phone and leave it idle ..the battery bar will rise up again

A-)N900 will recalculate the remaining battery charge according to the way using it
.. if you are using N900 in a heavy way then battery bar will show less than leaving N900 on idle mode

3-)
Q-) My N900 shows temperature UNKNOWN in qcpu !!
A-) This is a kernel problem .... rebooting will solve it

----------------------------------------------------------------------



PART5 : TWEAKS

1-) You may try hardware accelerator wich will make hildon-desktop smoother
BUT it is known to be unstable so if it caused any hildon-dekstop crashs or reboots simply disable it

To enable it :
use any text editor to edit /etc/powervr.d/hildon-desktop.ini and change WSEGL_UseHWSync=0 to WSEGL_UseHWSync=1
so :

Code:
sudo gainroot
leafpad /etc/powervr.d/hildon-desktop.ini
and change

Code:
WSEGL_UseHWSync=0
To

Code:
WSEGL_UseHWSync=1
Believe me hildon will be much smoother but as i said before if any reboots occurred then disable it by changing


Code:
WSEGL_UseHWSync=1
To

Code:
WSEGL_UseHWSync=0

IMPORTANT: if you was very unlucky with HWsync you may have to reflash Your N900
because it may cause a reboot loop
otherwise it is stable to use on 80% of N900s
------------------------------------------------------


2-) And you may also want swappolube and it's proposed values
to install it

Code:
sudo gainroot
apt-get install swappolube
once installed launch it then press on PROPOSED button then APPLY then STORE

------------------------------------------------------


3-) And you may also want tracker-cfg and lowmemory mode (will make tracker use less CPU and Memory wich will improve the speed a bit)
install it :

Code:
sudo gainroot
apt-get install tracker-cfg
once installed launch it and choose lowmemorymode
Then save and exit

------------------------------------------------------


4-) And ApMeFo app wich organizes folders your menu(try to reduce the shortcuts by putting them in folders) this will improve transitions

to install:

Code:
sudo gainroot
apt-get install apmefo
------------------------------------------------------


5-) And installing CSSU with it's nice modified hildon-*
for installing it

http://wiki.maemo.org/Community_SSU

------------------------------------------------------

6-)Also kernel-power is recommended

to install it :

Code:
sudo gainroot
apt-get install kernel-power-flasher
----------------------------------------------------------------------

7-)A great app called "Task-Swapper"
which allows To Easily Switch Between Opened Windows Without Passing Through Dashboard (Ctrl+Right or Ctrl+Left)

to install it:
Code:
sudo gainroot
apt-get install task-swapper
------------------------------------------------------
IF YOU DID ALL THE INSTRUCTIONS CORRECTLY

You should have a really fast and smooth N900

BTW The Tweaks Are All optional But For the best result Apply Them All


Enjoy

------------------------------------------

Last edited by karam; 2012-10-06 at 16:24.
 

The Following 352 Users Say Thank You to karam For This Useful Post:
101aj, 222, 4n77r4xX, accountvip, ahmadamaj, AlekMX, alex-12gods, algiz, AlMehdi, amin007110, AnasSyria, Andre Franc, Andy1210, antezz, anyonebutthis, Aonsaithya, apollovy, ArchiMark, arora.rohan, Arrancamos, ashwin, Atarii, awett, azad1top, Azure, bakuur, Bartus, bccwvfwcw, bequezox, BertvanDorp, bingomion, bipinbn, bitrocky, Blackthorne, bman, bobbydoedoe, borghal, botski, Brian_7, Bøbo, Cae$ar, carbonjha, casper27, CepiPerez, ceroberts75, Changegames, cheve, chill, clasificado, Clausi, cnadarajah, Cobra, corduroysack, Crogge, ctl, cube48, Custard! SandS, cutehunk04, D@vIcHoJD, dadoabdallah, dansus, DaReaper, Darkslayer, Dark_Angel85, dattadude, deegore, demludi, Deserve, dgls82, dipack95, djdas, don_falcone, dotnixau, dov, Dragoss91, drangina, dtparikh, Dvd25, dzano, ed00, eddieselamp, edoiks, ed_boner, eefo, elie-7, eMiL, enne30, Erazor, ersanpermana, etuoyo, excelar8, exee, ezameht, ezmendriz, F2thaK, Fabry, fahadj2003, faktorqm, fasza2, fatcobrah, feurigel, figaro, flatser, flocke000, frickler, frostbyte, funkmunk, fusi, fw190, gabby131, Garcel, gionni88, Golian, gordonshowers, guyr, hardkorek, heartbreakdoctor, hermes040, hgroove, HtheB, humble, immi.shk, itschue, ivyking, J4ZZ, jberezhnoy, jedi, jhepburn, jlnh, Joe Cool, joelus, John McClane, JorgeFX, Joseph9560, jpala16, jperez2009, JSTAR, Juanma9, jurgel, justmicky, kcfischer, Ken-Young, Kenny.Vo, kent_autistic, kevloral, KingKobraone, kmare, knuthf, kolos, l32606, lame, law5on, Leachim, Leon Obscuro MX, lfcobra, lidow, lingling92, LordVan, lostinmirkwood, lost_bro, lsolano, lvlonkey, MAAANOOO, MaDless, magic_doc, Magik, Maj3stic, majesty, mamad CJ, Manatus, manojkumaru, MatMat, maurososo, maximilian1st, mehulrajput, memorian, Mentalist Traceur, MetalSer, microe, mike_shenoda, mikki-kun, Minhaz, mirciox, Mitrigol, mlb, mmarks, modeless, moepda, Mohammad, Moody, mornage, mosiomm, Mr. Incredible, Mr.bot, MrBigCow, mrbiggzz79, Mr_Ryde, mscion, Mummelnase, mveplus, MyNokiaN900, n70shan, n900_novice, nafajafam, nashith, Natan_xy, neboja, Nevertime, nexus101, nicholes, niko3d, niqbal, NokiaRocks, NokTokDaddy, nology, noorallah, oved_etzot, panjgoori, PdxDoug, peter2p, peterleinchen, pfontana77, phamgia, phap, phapsubongtoi, phil4444, PhopsonNY, Pillum, poeddiee, prankster, princefakhan, pusak gaoq, Pyro1099, Radishface, ravent-n900, rawutt, Reflektorfalke, renowong, rgodinez, rizbert, robcmk, rochmanew, rogierrr, romiiio, rslick, Russe89, ryusilva, sajjadsajjad, sake, sakya, sanchdaniel, santiago, Saron, sbock, Schturman, scribbles, Seker_94, Sekou718, shallimus, shanttu, shardul, shawwawa, shazosbourne, Shivu025, sifo, Silvarum, sirpaul, SirSocke, Skaven2k2, slai, slender, smartypants, smegheadz, sneer_69, som3a, Soppa, soultmich, Sourav.dubey, SPARTAN563, Spotfist, SSLMM, ste-phan, stef, stevomanu, StocChr, stone17, Stonik, stooobs, strange1712, Straycat, studiosusmed, Sudisk, superpj101, Surreptitious, T4UR14N, tan, tarek, te37v, techie, techno2001, tecs, TeHeR, tetris11_, The Winter, thebtman, TheBurek, Tiran, titou1234, tlex26, TNL, tokag, Tolyan82, topet2k12001, torpedo48, trisha02, trlopes1974, trompkins, Tstone, udaychaitanya16, ukaef, uros, vaporeso, vdx29, victorevo, videohese, visN900, VladNistor, VulcanRidr, Wasmachinemann-NL, WeASeL..., whayong, willi6868, wow23, x-lette, xaccrocheur, xkkkx, xsmabbs, yanness, zdanee, Zekahz, Zentenario, zincholic, zlatokosi, ZogG, _invisible_
Posts: 135 | Thanked: 75 times | Joined on Apr 2011 @ Buenos Aires, Argentina
#2
I'll give it a try.
 
Posts: 225 | Thanked: 105 times | Joined on May 2010
#3
for the record: you need bash for this
 
Posts: 225 | Thanked: 105 times | Joined on May 2010
#4
it says
/home/user/.bashrc no such file or directory
/etc/rc.local no such file or directory

 
Posts: 856 | Thanked: 1,681 times | Joined on Apr 2010 @ Aleppo ,Syria
#5
Originally Posted by Pillum View Post
it says
/home/user/.bashrc no such file or directory
/etc/rc.local no such file or directory

After you run the script?
do you have bash installed ?

And i'm not quite sure about that but maybe sudser and rootsh1.8 are needed

Last edited by karam; 2011-05-21 at 20:10.
 

The Following User Says Thank You to karam For This Useful Post:
elie-7's Avatar
Posts: 968 | Thanked: 663 times | Joined on Jun 2010 @ Australia (Melbourne/vic) / Lebanon (Zgharta/north)
#6
can we please have this patched up with swappolube ??????
__________________
rolling down the street, smoking ENDO, sipping on gin and juice
laid back, with my mind on my money and my money on my mind .
 

The Following User Says Thank You to elie-7 For This Useful Post:
Posts: 856 | Thanked: 1,681 times | Joined on Apr 2010 @ Aleppo ,Syria
#7
Originally Posted by elie-7 View Post
can we please have this patched up with swappolube ??????
swappolube does a completely diffrent things

you can refer to
http://wiki.maemo.org/Swappolube
to understand what swappolube does

Last edited by karam; 2011-05-24 at 06:58.
 

The Following 2 Users Say Thank You to karam For This Useful Post:
Posts: 856 | Thanked: 1,681 times | Joined on Apr 2010 @ Aleppo ,Syria
#8
Originally Posted by tokag View Post
attached is a version i have modified to work with ash rather than bash for those who don't have bash installed. same installation instruction apply. enjoy.

PS
sorry for the .zip file. i don't have a .tar archive creator handy.
Thanks it might be a handy but still bash is more recommened IMO
 
Posts: 5,335 | Thanked: 8,187 times | Joined on Mar 2007 @ Pennsylvania, USA
#9
 
Posts: 1,680 | Thanked: 3,685 times | Joined on Jan 2011
#10
Originally Posted by karam View Post
HELLO Everybody
A lot of you must have heard about the 200 lines to speed up linux while blackhat announced 4 lines to do that
anyway neither of the available tutorials on internel are working on N900

BUT For Fortunately i was able to apply it to maemo 5 on N900!!!!!

You will notice a lot of improvements in hildon-desktop
ex: faster multitask , faster contacts scrolling , faster images scroling
and basically every thing will be improved
Now the script is not made by me
all what i did is modified it a bit to work on maemo 5
PS : it is recommended to use good transitions.ini although it is optional to use
Download the patch.tar.gz from attachment it contains the patch and the transitions
place it in MyDocs
Then enter CODE :

sudo gainroot

apt-get install bash
tar xzvf /home/user/MyDocs/patch.tar.gz
cp cgroup_patch /home/user/
chmod +rwx /home/user/cgroup_patch
/home/user/cgroup_patch
chmod +rwx /etc/rc.local
chmod +rwx /usr/local/sbin/cgroup_clean
/etc/rc.local

DONE

And For transitions file (OPTIONAL)
cp /home/user/MyDocs/transitions.ini /usr/share/hildon-desktop/ # if you are using stock themes

if not then replace /usr/share/hildon-desktop with the path of your theme in my case
cp /home/user/MyDocs/transitions.ini /usr/share/themes/Blue-sky/

DONE

NOTE: the transistions file has thp tweaks also parallax and zoom_on_press under [home] section

YOU may not feel changes until reboot
but probably you will feel before as it happened with me

Enjoy
Please give feedbacks

LAST NOTE:
IF you didn't think the patch worked or did anything don't worry it will not affect anything

EDIT!!:

JUST to make sure no problems occure open a terminal window and type
(as user)

bash

(as root)

bash

then exit
This looks cool, however can you please explain in detail what you have done to make this maemo5 compliant?
__________________
N900: One of God's own prototypes. A high-powered mutant of some kind never even considered for mass production. Too weird to live, and too rare to die.
 

The Following 2 Users Say Thank You to vi_ For This Useful Post:
Reply

Tags
autobrick, awesome-script, do no install, f***epitaph, install it now, perfect_ n900, script-a-brick, very safe

Thread Tools

 
Forum Jump


All times are GMT. The time now is 03:37.