Skip to content

showp1984/kcontrol_gpu_msm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 

Repository files navigation

kcontrol_gpu_msm
================

How to build?
1. Edit the Makefile to point to your kernel source in which you want the module to be inserted.
2. make
3. #done

How to use:
Kcontrol will insert this module with the appropriate parameters on it's own if found in /system/lib/modules.
All you need for that to work is compile your kernel with CONFIG_KALLSYMS_ALL.
If you want to test this module on your own without KControl, do this:

echo "0" > /proc/sys/kernel/kptr_restrict
cat /proc/kallsyms | grep 'device_3d0' | tail -n1
XXXXXXXX d device_3d0
cat /proc/kallsyms | grep 'gfx2d0_clk'
YYYYYYYY d gfx2d0_clk
cat /proc/kallsyms | grep 'gfx3d_clk'
ZZZZZZZZ d gfx3d_clk

insmod kcontrol_gpu_msm.ko dev_3d0=0xXXXXXXXX gfx2d0_clk=0xYYYYYYYY gfx3d_clk=0xZZZZZZZZ

(If you insert the module without these parameters, the insert will fail and the module will remove itself. No changes will have been done to your kernel.)

The sysfs exposeables are in /sys/kernel/kcontrol_gpu_msm/.

If you plan on extending this module with any functionality beware of changing the kernel memory.
As that may result in unexpected behavior, like world war III, a black hole, or some other shit.
This module only reads stuff and if it should write something in the future then I am 99.99999% sure that it is safe.
You should be too if your extension plans to modify a running kernel.
Otherwise: Don't touch things of which you have no clue.

About

KControl gpu module for msm devices

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages