mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-06-30 02:52:04 +08:00
tici: use powersave CPU governor while offroad (#23146)
* tici: use powersave CPU governor while offroad * fix path old-commit-hash: 5e20a46db6882c4f48160f7a9f98d695bcbea873
This commit is contained in:
@@ -303,6 +303,10 @@ class Tici(HardwareBase):
|
||||
val = "0" if powersave_enabled else "1"
|
||||
os.system(f"sudo su -c 'echo {val} > /sys/devices/system/cpu/cpu{i}/online'")
|
||||
|
||||
for n in ('0', '4'):
|
||||
gov = 'powersave' if powersave_enabled else 'performance'
|
||||
os.system(f"sudo su -c 'echo {gov} > /sys/devices/system/cpu/cpufreq/policy{n}/scaling_governor'")
|
||||
|
||||
def get_gpu_usage_percent(self):
|
||||
try:
|
||||
used, total = open('/sys/class/kgsl/kgsl-3d0/gpubusy').read().strip().split()
|
||||
|
||||
Reference in New Issue
Block a user