Or Continue to Thread: [KERNEL][T] DooMKernel {JB}(v1…
Find Your Device:
28th February 2013, 08:46 PM   |  #6  
DooMLoRD's Avatar
OP Recognized Developer
Flag Noida
Thanks Meter: 39,119
 
13,127 posts
Join Date:Joined: Jul 2010
How to use CPU Voltage Control interface


All credits for this interface go to gokhanmoral!

initially i was trying another implementation for the krait chips based on Faux123's implementation but it wasnt working propely... so I have ported the VDD interace to my kernel from gokhanmoral's commits!


device will always bootup at stock voltage table...



WARNING!

DO NOT USE TOO HIGH OR TOO LOW VOLTAGES

SLOWLY increase the voltage one notch at a time for a particular frequency and do stability/testing for few hours

once you have verified that you CPU chip can handle that voltage ONLY then "Set at boot"/Use init.d script

if you dont follow above instruction your device might bootloop




You can either use an APP (like Voltage Control) or use an init.d script to do the work...



the interface to control voltages is at:
Code:
/sys/devices/system/cpu/cpu0/cpufreq/vdd_levels



to see current voltage table use:
Code:
cat /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels

to set voltage for a particular frequency:
Code:
echo 1512000 1200 > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
will set 1512Mhz freq voltage at 1200mV


to reduce voltages for ALL frequencies:
Code:
echo -25 > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels

to increase voltages for ALL frequencies:
Code:
echo +25 > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels



example init.d script to reduce voltages by 75mV for ALL frequencies:
Code:
#!/system/bin/sh
echo -75 > /sys/devices/system/cpu/cpu0/cpufreq/vdd_levels
can be saved as /system/etc/init.d/99vdd
Last edited by DooMLoRD; 7th March 2013 at 03:15 PM.
The Following 7 Users Say Thank You to DooMLoRD For This Useful Post: [ View ]